0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 1 year has passed since last update.

windowsでuser/1000/spring-1000の一時フォルダが消えてrails g コマンド時にエラーが起きる時の対処法

Posted at

rails g コマンドを実行した時に以下のエラーが発生した。

 Permission denied @ dir_s_mkdir - /run/user/1000/spring-1000 (Errno::EACCES)
% sudo chown $USER:$USER /run/user/1000/spring-1000

上記コマンドで

・「No such file or directory」などのエラーが発生しなかった場合、今回実行したかったrails g controllerを実行

・「No such file or directory」などのエラーが発生した場合
以下のコマンドを一行ずつ実行する。

% sudo mkdir -p /run/user/1000/spring-1000
% sudo chown $USER:$USER /run/user/1000/spring-1000

これで一時ファイルを作成できたため、rails g コマンドを実行してもエラーが発生しなくなる。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?