Search
 
SCRIPT & CODE EXAMPLE
 

SHELL

Git commit

git commit -a -m "The Commit message"
#commit all changed files with a message

git commit -m "The Commit message"
#commit selected files with a commit message
Comment

git commit

git commit -a -m "The Commit message"
Comment

git commit

git add index.html css/styles.css
git add .
git commit -m "Change titles and styling on homepage"
Comment

Git commit

# The set of commands that were used in the `Git Commit` video

# Add the file to git's staging area, so we can commit it
git add story.txt

# Check the status of the repository
git status

# Commit the changes
git commit -m "Initial commit"

# Check the status of the repository after the commit
git status

# Update the `story.txt` file
nano story.txt

# Check the status again
git status

# Add the file to the staging area
git add story.txt

# Commit
git commit -m "Expand story"

# Ensure the working tree is clean
git status
Comment

git commit

git commit -m "Write your message here"
Comment

git commit

//now commit the code
git commit -m "anyMessageYouWantToWrite"
Comment

git commit

To commit all changed files with a message


$ git commit -a -m "The Commit message"


To commit selected files with a commit message


$ git commit -m "The Commit message"


To check status


$ git status
Comment

git commit

--::-- Using SSH --::--
#### Create SSH key ####
$ ssh-keygen -t ed25519 -C "<YourEmail>@<Domain>.com"

#### Copy the SSH key ####
$ cat /path/to/private_key_file.pub

#### Add the SSH key to your GitHub account ####

$ echo "# myPracticeRepo" >> README.md
$ git init
$ git add README.md
$ git commit -m "first commit"
$ git branch -M main
$ git config core.sshCommand 'ssh -i /path/to/private_key_file'
$ git remote add origin git@github.com:<UserName>/<RepoName>.git
$ git push -u origin main


--::-- Using HTML --::--
$ echo "# myPracticeRepo" >> README.md
$ git init
$ git add README.md
$ git commit -m "first commit"
$ git branch -M main
$ git remote add origin https://github.com/<UserName>/<RepoName>.git
$ git push -u origin main
Comment

git commit

git commit 
optional arguments:
-a: commit all changes(not recomended if you're on windows and are not using vim, windows make .swp files, must be very careful)
-m: to add a message, e.g.: git commit -m "message here"
Comment

commit with git

cd /path/to/my/codebase
git init
git add .
git commit
Comment

git commit

$ git commit -m "Story 182: fix benchmarks for speed"
[master 463dc4f] Story 182: fix benchmarks for speed
 2 files changed, 2 insertions(+)
 create mode 100644 README
Comment

PREVIOUS NEXT
Code Example
Shell :: ubuntu no space left on device boot 
Shell :: setting git username 
Shell :: git show files modified since commit 
Shell :: add local repository to remote 
Shell :: how to open text editor in git bash 
Shell :: mvn versions set 
Shell :: swagger installation 
Shell :: install mariadb 10.2 ubuntu 16.04 
Shell :: install brain.js 
Shell :: delete pid port 
Shell :: combine two document together lnux 
Shell :: link folder to github repo 
Shell :: node_modules missing did you mean to install 
Shell :: microsoft excel free download for ubuntu 
Shell :: active developer path does not exist 
Shell :: tmux kill-session by name 
Shell :: Connect to Remote MySQL Database through Command Line 
Shell :: Error generated. /dvs/git/dirty/git-master_linux/multimedia/nvgstreamer/gst-nvarguscamera/gstnvarguscamerasrc.cpp, execute:783 (propagating) 
Shell :: install font on linux 
Shell :: pipenv install flask 
Shell :: mount docker volume in container 
Shell :: ssh agent remember passphrase 
Shell :: open image from terminal in ubuntu 18 
Shell :: linux video player 
Shell :: install wsl2 windows 10 pro 
Shell :: how to commit a specific file in git 
Shell :: how to add a custom zsh aliases 
Shell :: composer upgrade to 2 
Shell :: git tag to previous commit 
Shell :: linux custom command 
ADD CONTENT
Topic
Content
Source link
Name
7+7 =