Я установил scala с sbt согласно этому сообщению Getting started.scala - bash: hw.scala: Разрешение отрицается
Но когда я создал легкий старт проекта Hello world я встретил странный вывод:
[email protected]:~$ find .sbt
.sbt
.sbt/.lib
.sbt/.lib/0.12.1
.sbt/.lib/0.12.1/sbt-launch.jar
.sbt/boot
.sbt/boot/update.log
[email protected]:~$ cd hello
[email protected]:~/hello$ echo 'object Hi { def main(args: Array[String]) = println("Hi!") }' > hw.scala
bash: hw.scala: Permission denied
[email protected]:~/hello$ sbt
java.io.FileNotFoundException: /home/nazar_art/.sbt/boot/update.log (Permission denied)
at java.io.FileOutputStream.open(Native Method)
at java.io.FileOutputStream.<init>(FileOutputStream.java:212)
at java.io.FileOutputStream.<init>(FileOutputStream.java:165)
at java.io.FileWriter.<init>(FileWriter.java:90)
at xsbt.boot.Update.<init>(Checks.java:51)
at xsbt.boot.Launch.update(Launch.scala:266)
at xsbt.boot.Launch$$anonfun$jnaLoader$1.apply(Launch.scala:111)
at scala.Option.getOrElse(Option.scala:108)
at xsbt.boot.Launch.jnaLoader$2f324eef(Launch.scala:106)
at xsbt.boot.Launch.<init>(Launch.scala:85)
at xsbt.boot.Launcher$.apply(Launch.scala:281)
at xsbt.boot.Launch$.apply(Launch.scala:16)
at xsbt.boot.Boot$.runImpl(Boot.scala:31)
at xsbt.boot.Boot$.main(Boot.scala:20)
at xsbt.boot.Boot.main(Boot.scala)
Error during sbt execution: java.io.FileNotFoundException: /home/nazar_art/.sbt/boot/update.log (Permission denied)
Я не могу понять, почему это происходит сог я su
.
Любые предложения.
EDIT:
Я использовал chmod 777
для Update.log. Но теперь, когда я пытаюсь запустить SBT у меня есть:
-rwxrwxrwx 1 root root 63 Aug 13 11:17 hw.scala
[email protected]:~/hello$ sudo echo 'object Hi { def main(args: Array[String]) = println("Hi!") }' > hw.scala
[email protected]:~/hello$ sbt
Error occurred during initialization of VM
Could not reserve enough space for object heap
- Как решить эту неприятность?
Он возвращает '-rw-r-r-- 1 корень root 0 13 авг 10:42 update.log' –
Примите к сведению его: su chown -R nazar_art ~/.sbt – joescii
Я обновил вопрос. –