Flèche
[github] 원격 repo 속의 폴더에 파일을 직접 push하는법 본문
git add
git remote .... repository주소
이걸로 하면 안되는구나 ㅠ
How to push a file inside a folder made in a github repository?
I am assuming that you are solely using Github Web Interface to upload file in a folder of your repository. If that's the case, you should go to your repository and then go into the folder you want to create file in and follow instructions given in their documentation:
https://help.github.com/articles/adding-a-file-to-a-repository/
- Under your repository name, click Upload files.
- Drag and drop the file or folder you'd like to upload to your repository onto the file tree.
- At the bottom of the page, type a short, meaningful commit message that describes the change you made to the file.
- Below the commit message fields, decide whether to add your commit to the current branch or to a new branch. If your current branch is master, you should choose to create a new branch for your commit and then create a pull request.
- Click Commit changes.
Edit:
Using git commands:
git clone <repository_link> #(Https/SSH) # make required changes to this cloned local repository git add --all # stage all the changes git commit -m 'your commit message' # commit into the repository git push <origin> <branch> # push to the remote repository # To list available upstreams of this repository <origin>: git remote -v # To see branch you are on: git branch
'github' 카테고리의 다른 글
[github]pull request 에 대해 배우는 시간을 가졌다 (0) | 2021.02.03 |
---|---|
깃허브에 있던 내 코드가 사라졌다 (0) | 2021.01.30 |
깃허브에 file을 push 했는데 contribution graph 에 표시가 안된다 (0) | 2021.01.30 |