git push
Now that we have a repository to work with, let's make a simple change and push it to GitHub.
I changed the contents of README.md
to:
| # Welcome
To our repository. It's a bit basic, but it'll get better over time :-)
|
Then I used git commit -am
to commit that change to the staging area.
| $ git commit -am 'the README needed attention'
[main abe936c] the README needed attention
1 file changed, 4 insertions(+), 1 deletion(-)
|
And then I used git push
to literally push the changes to the remote repository:
| $ git push
Enumerating objects: 5, done.
Counting objects: 100% (5/5), done.
Compressing objects: 100% (2/2), done.
Writing objects: 100% (3/3), 340 bytes | 340.00 KiB/s, done.
Total 3 (delta 0), reused 0 (delta 0)
To github.com:opsfactoryau/uploadacademy-itopslevelone-a.git
dccfcce..abe936c main -> main
|
And we're done. We've successfully pushed a change to a remote Git repository hosted on GitHub.