问题
When I type -> rails new test_app, it only does the following -> create create README.md create Rakefile create .ruby-version create config.ru create .gitignore create Gemfile run git init from "."
I was able to run this command successfully (where it created all the folders and files needed in a rails app) in my c:\users\ directory, however was not able to run it anymore after that. I have also deleted all rails related files in that directory and retried, but have had no success.
Please help.
回答1:
Install git from Git-Scm.
Enter git --version
in command line if it returns version info go ahead and run
rails new projectname
If git --version
throws error in command prompt as 'git' is not recognized as an internal or external command. Add environment variable for git. Refer Stackoverflow link to add environment variables for git
来源:https://stackoverflow.com/questions/59442185/in-windows-rails-new-does-not-create-all-the-files-and-folders-stops-at-r