I want to be able to push git with ruby on rails tutorial.

Asked 1 years ago, Updated 1 years ago, 118 views

Thank you for your help.As I am a beginner, the questioning method may be inappropriate, but could you please tell me the following?

I started ruby on rails tutorial on AWS cloud9, but I am having trouble pushing it to Git due to the following error message in Bitbucket in Chapter 1, 1.4.3.

Specifically, enter the following at the terminal

 git remote add origin [email protected]: goshima/hello_app.git

→ The following is displayed.

usage:git remote add [<options>]<name>url>

    -f, -- fetch fetch the remote branches
    --tags import all tags and associated objects when fitting
                          or do not fetch any tag at all (--no-tags)
    -t, --track<branch>branch(es) to track
    -m, --master<branch>
                          master branch
    --mirror [=<push|fetch>]
                          setup remote as a mirror to push to or fetch from"

Next, run git push-u origin --all to see the following message:

 fatal: 'origin' does not appear to be a git repository
fatal —Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.

I searched for past questions, but none of them are applicable. Is it a cloud9 environment?I deleted all of them twice and tried, but the above error message remains.I'm sorry to trouble you, but could someone please let me know?

ruby-on-rails git bitbucket

2022-09-30 19:42

1 Answers

After you run the first command, you see the how to run the command (git remote).

If you look closely at the help, add requires arguments equivalent to <name> and <url>, but the command you executed contains extra space, so the number of arguments does not match and the help is displayed.

Here's how to execute the commands in the tutorial referenced (probably you):

$git remote add origin [email protected]: username/hello_app.git
                 ~~~~~~
                        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
                 <name><url>

<name> and <url> basically do not contain spaces, so if you want to replace them with actual commands, you should do the following:
As Nekketsuuuuu pointed out in his comment, please note that colons are also half-width.

$git remote add origin [email protected]:goshima/hello_app.git


2022-09-30 19:42

If you have any answers or tips


© 2024 OneMinuteCode. All rights reserved.