1234567891011121314151617181920 |
- #!/bin/sh -efu
- # Initialize git repository.
- git init
- # Add file.
- git add main.sh
- # Make commit.
- git commit --edit
- # Modify.
- cat > a << EOF
- hello!
- EOF
- # Add to staged area.
- git add a
- # Show cached area.
- git diff --cached
- # Commit.
- git commit --edit
|