Modify the structure of README.md
Instead of having exercises in their own separate section, they are now part of the main topics sections. This should make the learning process easier to follow where users have both exercises and questions in the same place. In addition, added a couple of new questions & exercises and modified existing scripts accordingly.
This commit is contained in:
20
exercises/git/solutions/branch_01_solution.md
Normal file
20
exercises/git/solutions/branch_01_solution.md
Normal file
@ -0,0 +1,20 @@
|
||||
## Branch 01 - Solution
|
||||
|
||||
```
|
||||
cd some_repository
|
||||
echo "master branch" > file1
|
||||
git add file1
|
||||
git commit -a -m "added file1"
|
||||
git checkout -b dev
|
||||
echo "dev branch" > file2
|
||||
git add file2
|
||||
git commit -a -m "added file2"
|
||||
```
|
||||
|
||||
Verify:
|
||||
|
||||
```
|
||||
git log (you should see two commits)
|
||||
git checkout master
|
||||
git log (you should see one commit)
|
||||
```
|
10
exercises/git/solutions/commit_01_solution.md
Normal file
10
exercises/git/solutions/commit_01_solution.md
Normal file
@ -0,0 +1,10 @@
|
||||
## Git Commit 01 - Solution
|
||||
|
||||
```
|
||||
mkdir my_repo && cd my_repo
|
||||
git init
|
||||
echo "hello_commit" > file
|
||||
git add file
|
||||
git commit -a -m "It's my first commit. Exciting!"
|
||||
git log
|
||||
```
|
Reference in New Issue
Block a user