This repository contains the source code of the git-exercises platform for practising git.
fracz / git-exercises Goto Github PK
View Code? Open in Web Editor NEWHome Page: https://gitexercises.fracz.com
License: MIT License
Home Page: https://gitexercises.fracz.com
License: MIT License
This repository contains the source code of the git-exercises platform for practising git.
I've come over from Springboard which recommends your exercises.
First: There needs to be a very large explanation on your home page and FAQ to say "Copy this code into your own terminal windows on your computer". It claims to be "interactive" but it's not. I've just finished a set of Git Hub exercises at Data Camp -- they are interactive. Yours are copy/paste.
Second: Even after I copied and pasted into my own computer, there is no config.sh file.
$ git clone https://gitexercises.fracz.com/git/exercises.git
Cloning into 'exercises'...
remote: Counting objects: 142, done.
remote: Compressing objects: 100% (108/108), done.
remote: Total 142 (delta 28), reused 136 (delta 28)
Receiving objects: 100% (142/142), 32.49 KiB | 0 bytes/s, done.
Resolving deltas: 100% (28/28), done.
Checking connectivity... done.
Note: checking out '8da95646b389740e590fc17e9c9547c094efd8a8'.
You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by performing another checkout.
If you want to create a new branch to retain commits you create, you may
do so (now or later) by using -b with the checkout command again. Example:
git checkout -b new_branch_name
(base) [14:01 Thu Jun 27] ~/Learn/Git
vlb@grimoire 122 $ cd exercises
(base) [14:01 Thu Jun 27] ~/Learn/Git/exercises
vlb@grimoire 123 $ git config user.name "Vicki"
(base) [14:01 Thu Jun 27] ~/Learn/Git/exercises
vlb@grimoire 124 $ git config user.email "[email protected]"
(base) [14:01 Thu Jun 27] ~/Learn/Git/exercises
vlb@grimoire 125 $ ./configure.sh
-bash: ./configure.sh: No such file or directory
(base) [14:01 Thu Jun 27] ~/Learn/Git/exercises
vlb@grimoire 126 $ git start
git: 'start' is not a git command. See 'git --help'.
Did you mean one of these?
stage
stash
(base) [14:01 Thu Jun 27] ~/Learn/Git/exercises
vlb@grimoire 127 $ l
./ .git/ README.md start.sh*
../ .gitignore file.txt
Hi, just to let you know that I'm a teacher, and I'm in an OSS module with my students.
I found your super website, and exercises, and give them to increase their git skills, and it works like a charm, so a real thank you for your amazing work!
Btw it could be cool (especially for you) to let users delete their "account" when they're done with the exercices. It'll avoid to store useless data for years. 😉
👋
The web page shows me the following text:
How to start?
You will need a PC first :-)
I had the page open in Firefox web browser on Ubuntu 18.04 Beta 2 Linux distribution.
Hey. Cloned the repo and got the following output:
Cloning into 'exercises'...
remote: Counting objects: 158, done.
remote: Compressing objects: 100% (116/116), done.
remote: Total 158 (delta 33), reused 155 (delta 33)
Receiving objects: 100% (158/158), 35.50 KiB | 616.00 KiB/s, done.
Resolving deltas: 100% (33/33), done.
Note: switching to '1aab3e78574dc22abeb7ddf948060bcba0677f4d'.
You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by switching back to a branch.
If you want to create a new branch to retain commits you create, you may
do so (now or later) by using -c with the switch command. Example:
git switch -c <new-branch-name>
Or undo this operation with:
git switch -
Turn off this advice by setting config variable advice.detachedHead to false
After checking if there are any branches, none were found.
Hi,
first of all thank you for taking the time to build this exercises. 😃
I was testing them so I might recommend them to some fellow colleagues that are new to git, but currently git verify
does not seem to work, eg.
$ git verify
You haven't made any progress on exercise commit-one-file-staged.
Did you forget to commit your changes?
I think the issue is that push is rejected with an error, eg.
$ git push
Objekte aufzählen: 4, Fertig.
Zähle Objekte: 100% (4/4), Fertig.
Delta-Kompression verwendet bis zu 6 Threads.
Komprimiere Objekte: 100% (2/2), Fertig.
Schreibe Objekte: 100% (3/3), 300 bytes | 300.00 KiB/s, Fertig.
Gesamt 3 (Delta 0), Wiederverwendet 0 (Delta 0)
remote: (
remote: ************************************************************************
remote: Exercise: commit-one-file
remote: Status: PASSED
remote: You can see the easiest known solution and further info at:
remote: https://gitexercises.fracz.com/e/commit-one-file/4xq
remote:
remote: Next task: commit-one-file-staged
remote: In order to start, execute: git start next
remote:
remote: See your progress and instructions at:
remote: https://gitexercises.fracz.com/c/4xq
remote: ************************************************************************
remote: )
remote: Remember that you can use git verify to strip disturbing output.
remote: error: hook declined to update refs/heads/commit-one-file
remote: error: The last gc run reported the following. Please correct the root cause
remote: and remove gc.log.
remote: Automatic cleanup will not be performed until the file is removed.
remote:
remote: warning: There are too many unreachable loose objects; run 'git prune' to remove them.
remote:
To https://gitexercises.fracz.com/git/exercises.git
! [remote rejected] commit-one-file -> commit-one-file (hook declined)
error: Fehler beim Versenden einiger Referenzen nach 'https://gitexercises.fracz.com/git/exercises.git'
My guess is that you need to add automatic garbage collection to your backend git-server, eg. as post-push hook.
The generated link (eg. https://gitexercises.fracz.com/c/4xq) does work however, pushing a solution does increase your progress.
So it seems its only an issue with git push failing unexpectedly (due to to many unreachable loose objects)
In 16 and 17 Nov 2021 I am migrating the service to a new server. If you exepct any downtime or problems, it might be due to this process.
Hi, I was using your site to practice and learn git and got as far as the merge-conflict exercise. I couldn't figure this one out, so I tried to Google the solution. I found one and copy-pasted it into my PowerShell terminal and still didn't pass with git verify.
Here is the code I used:
git merge another-piece-of-work
echo 2+3=5 > equation.txt
git add equation.txt
git commit --no-edit
I also tried it this way:
git merge another-piece-of-work
echo "2 + 3 = 5" > equation.txt
git add equation.txt
git commit --no-edit
If I do git clone https://gitexercises.fracz.com/git/exercises.git
, it puts me at commit 030123e4ed762768e8d4a7f0371b1dea583c89e5
, which does not have a ./configure.sh
.
Specifically, this is my output:
git clone https://gitexercises.fracz.com/git/exercises.git
Cloning into 'exercises'...
remote: Counting objects: 145, done.
remote: Compressing objects: 100% (111/111), done.
remote: Total 145 (delta 29), reused 144 (delta 29)
Receiving objects: 100% (145/145), 33.82 KiB | 4.83 MiB/s, done.
Resolving deltas: 100% (29/29), done.
Note: switching to '030123e4ed762768e8d4a7f0371b1dea583c89e5'.
I am about half-way through the exercises. When I run git verify
on my latest solution, the following is returned.
~/exercises $ git verify
Verifying the fix-typo exercise. Hold on...
error: hook declined to update refs/heads/fix-typo
error: The last gc run reported the following. Please correct the root cause
and remove gc.log.
Automatic cleanup will not be performed until the file is removed.
warning: There are too many unreachable loose objects; run 'git prune' to remove them.
To https://gitexercises.fracz.com/git/exercises.git
! [remote rejected] HEAD -> fix-typo (hook declined)
error: failed to push some refs to 'https://gitexercises.fracz.com/git/exercises.git'
My progress has been reset from 11/23 to 0/23. The home page of the website https://gitexercises.fracz.com/ is no longer showing the "Latest solutions" feed.
This is common problem in Windows, where the file system is case insensitive.
We have file.txt
. We want to have File.txt
.
When we do mv file.txt File.txt
in Windows, git does not see any difference. We need to use git mv.
Suggested exercise name: sensitive-rename
.
I just wanted to drop a note that I adore this set of exercises, simple enough with nice web interaction, but with a proper git repository to use in your development environment, brilliant!
A little more startup help would be useful though - it's not immediately obvious how start and verify aliases work, and since I hadn't figured out autocrlf configuration, the scripts wouldn't execute. Maybe add some hints about such things?
Best regards
CJ
Do I look at solution if I can't find one myself ?
Awesome project!
I wanted to share this with my fellow DevOps developers, but they are strictly Windows.
I couldn't find clear, step-by-step instructions (I might have not searched correctly) and so I came up with a short blurb explaining how to access bash-git, and optionally set it up to be part of Windows Terminal.
I hope this helps out others, and maybe even becomes an instruction file in the repo.
** The instructions assume you have a directory at the root of your profile named source
in which your source code goes. If that is not the case, you will want to change the %USERPROFILE%\source
and ~/source
values in the commands below.
To run the exercises on Windows, you need to run in git-bash
, by either:
git-bash --cd="%USERPROFILE%\source"
* This opens a new mintty
terminal window, running bash. See Windows Terminal Profile section below for an alternative.
From within git-bash
, you will be able to run the commands from the web site and initialize the exercises.
If you prefer to use Windows Terminal instead of mintty
, follow the steps below to add a git-bash
profile:
bash --noprofile --norc -c 'echo Starting bash...; cd ~/source; exec bash --login -i'
git-bash
inside Windows Terminal.Hello! Currently, after cloning the repository, HEAD is set to a non-master commit which is missing configure.sh
.
git clone
output:
$ git clone https://gitexercises.fracz.com/git/exercises.git
Cloning into 'exercises'...
remote: Counting objects: 154, done.
remote: Compressing objects: 100% (116/116), done.
remote: Total 154 (delta 33), reused 152 (delta 33)
Receiving objects: 100% (154/154), 35.21 KiB | 2.71 MiB/s, done.
Resolving deltas: 100% (33/33), done.
Note: switching to 'ff178daab3c2db78e19214c346c031af38df1178'.
In Exercise fix-old-typo
, I try to use these commands to solve the exercise, after I find it doesn't work, I want to restart but doesn't work.
Environment: I run this repository in Gipod and use the environment to exercise
vim file.txt
# then edit the file
git commit -a --fixup=amend:<commit>
# then edit the commit
git rebase -i
git start fix-old-typo
# see the start info but not cancel the rebase and the branch is `fix-old-typo|REBASE 1/2`
# try to start other exercise to test
git start commit-lost
# see the start info but not cancel the rebase and the branch still `fix-old-typo|REBASE 1/2`
# then use git rebase --abort get reset status
git rebase --abort
Currently there is no LICENSE
file in the repository, one website, or anything. Consequently, it's unclear whether it's permissible to:
It'd be nice if author's intentions are clearly stated in a license file. I'd personally suggest MIT License or Apache 2 License, they're not copyleft and permit pretty much any usage and modifications without extra liability.
I did the following:
What am I missing?
(base) balter@spectre:~/exercises$ git start save-your-work
Preparing the exercise environment, hold on...
Exercise save-your-work started!
Read the README.md for instructions or view them in browser:
http://gitexercises.fracz.com/e/save-your-work
(base) balter@spectre:~/exercises$ cat README.md
## Saving your work
You are working hard on a regular issue while your boss comes in and wants you to fix a bug. State of your current
working area is a total mess so you don't feel comfortable with making a commit now. However, you need to fix the found
bug ASAP.
Git lets you to save your work *on a side* and continue it later. Find appropriate Git tool and use it to handle
the situation appropriately.
Look for a bug to remove in `bug.txt`.
After you commit the bugfix, get back to your work. Finish it by adding a new line to `bug.txt` with
Finally, finished it!
Then, commit your work after bugfix.
(base) balter@spectre:~/exercises$ git stash
Saved working directory and index state WIP on save-your-work: 98e0c28 Excellent version with a bug
(base) balter@spectre:~/exercises$ git pull
Already up to date.
(base) balter@spectre:~/exercises$ cat bug.txt
This file contains bug
It has to be somewhere.
I feel like I can smell it.
THIS IS A BUG - remove the whole line to fix it.
How this program could work with such bug?
(base) balter@spectre:~/exercises$ vi bug.txt
(base) balter@spectre:~/exercises$ cat bug.txt
This file contains bug
It has to be somewhere.
I feel like I can smell it.
How this program could work with such bug?
(base) balter@spectre:~/exercises$ git add .
(base) balter@spectre:~/exercises$ git commit -m "fixed the bug"
[save-your-work d158101] fixed the bug
1 file changed, 1 deletion(-)
(base) balter@spectre:~/exercises$ git status
On branch save-your-work
Your branch is ahead of 'origin/save-your-work' by 2 commits.
(use "git push" to publish your local commits)
nothing to commit, working tree clean
(base) balter@spectre:~/exercises$ git push
Enumerating objects: 8, done.
Counting objects: 100% (8/8), done.
Delta compression using up to 8 threads
Compressing objects: 100% (7/7), done.
Writing objects: 100% (7/7), 826 bytes | 826.00 KiB/s, done.
Total 7 (delta 2), reused 0 (delta 0), pack-reused 0
remote: (
remote: ************************************************************************
remote: Exercise: save-your-work
remote: Status: FAILED
remote: Expected number of commits: 3. Received 2.
remote:
remote: See your progress and instructions at:
remote: https://gitexercises.fracz.com/c/v3j
remote: ************************************************************************
remote: )
remote: Remember that you can use git verify to strip disturbing output.
remote: error: hook declined to update refs/heads/save-your-work
remote: error: The last gc run reported the following. Please correct the root cause
remote: and remove gc.log.
remote: Automatic cleanup will not be performed until the file is removed.
remote:
remote: warning: There are too many unreachable loose objects; run 'git prune' to remove them.
remote:
To https://gitexercises.fracz.com/git/exercises.git
! [remote rejected] save-your-work -> save-your-work (hook declined)
error: failed to push some refs to 'https://gitexercises.fracz.com/git/exercises.git'
(base) balter@spectre:~/exercises$
Exercise for changing the commit author.
I see you got a docker folder. I assume that is a way to use the server locally. So would you please make/write a tutorial/instruction on how to set it up locally.
I really need a local server to verify my works because I'm mostly offline.
Thanks
Hi,
git-exercises is awesome. But I don't get what I should do in ex 10. Could you please describe it more specific? Should I change the typo in the commit message or only in the file?
Hello, I'm getting the following error with git verify:
xxx@xxx MINGW64 ~/git/git-exercises (commit-one-file)
$ git verify
Verifying the commit-one-file exercise. Hold on...
Solution could not be verified - push failed.
Do you have an internet connection?
I'm using git bash on Windows 10 Pro.
getting the below error !!
$ git verify
Verifying the ignore-them exercise. Hold on...
Exercise: ignore-them
Status: FAILED
JNcrFbGD.exe file is not ignored
See your progress and instructions at:
https://gitexercises.fracz.com/c/dza
My .gitignore file ->
*.exe
*.o
*.jar
/libraries/
Not succeeding to validate the exercice with terminal, I used VS Code IDE to help (trick) the committing part of work. However, I verified my commits and everything seems fine.
So... is it a bug, or am I missing something?
Hi there,
I can't solve the exercises after cloning the repo. This problem began a few days ago.
This is the message that I receive after trying git verify:
Verifying the master exercise. Hold on...
Solution could not be verified - push failed.
Do you have an internet connection?
Clicking "Git Bash Here" in Windows Explorer used to work, opening to the appropriate directory.
It currently just keeps opening to the exercises directory.
Not sure if this is only a problem in MinGW
$ git push origin be720ab5881856fedb67e1d2ce0d0bd1cb32447d:find-bug
Enumerating objects: 904, done.
Counting objects: 100% (904/904), done.
Delta compression using up to 4 threads
Compressing objects: 100% (895/895), done.
Writing objects: 100% (903/903), 135.82 KiB | 1.97 MiB/s, done.
Total 903 (delta 0), reused 0 (delta 0)
error: RPC failed; curl 92 HTTP/2 stream 0 was not closed cleanly: PROTOCOL_ERROR (err 1)
fatal: the remote end hung up unexpectedly
fatal: the remote end hung up unexpectedly
Everything up-to-date
This means you can't verify your solution.
There is "Git clibboard" instead of "Git clipboard".
SaveYourWork-summary.md
To reduce interference with other repositories, please consider adding --local
argument to the git config
command in the
configure.sh
diff --git a/configure.sh b/configure.sh
index 6f6ab9f..f9604d5 100755
--- a/configure.sh
+++ b/configure.sh
@@ -1,13 +1,13 @@
#!/usr/bin/env bash
# Configure "git start" local alias for starting the exercise of user's choice and restarting the current one.
-git config alias.start "! f() { currentBranch=\$(git rev-parse --abbrev-ref HEAD); exercise=\${1-\$currentBranch}; if [ \$exercise != HEAD ]; then if [ \$exercise != next ]; then if git show origin/\$exercise:start.sh >/dev/null 2>&1 ; then if git checkout -f \$exercise >/dev/null 2>&1 && git reset --hard origin/\$exercise >/dev/null 2>&1 && git clean -fdx >/dev/null ; then if echo \"Preparing the exercise environment, hold on...\" && ./start.sh >/dev/null 2>&1; then echo \"Exercise \$exercise started!\" && echo 'Read the README.md for instructions or view them in browser:' && echo \"http://gitexercises.fracz.com/e/\$exercise\" ; else echo 'Could not execute the start script.' && echo 'Try running the ./start.sh script yourself.' ; fi else echo 'Could not clean the working directory.' && echo 'Make sure that none of the files inside the working directory' && echo 'is used by another process and run git start again.'; fi else echo \"Invalid exercise: \$exercise\" && false; fi else git push origin master:next-exercise 2>&1 | sed -n '/\\*\\*\\*/,/\\*\\*\\*/p' | grep -v '\\*\\*' | sed 's/remote: //g' | xargs git start | grep -v Invalid || echo 'You have passed all exercises!'; fi else echo 'You need to use git start <exercise-name> in detached HEAD'; fi }; f"
+git config --local alias.start "! f() { currentBranch=\$(git rev-parse --abbrev-ref HEAD); exercise=\${1-\$currentBranch}; if [ \$exercise != HEAD ]; then if [ \$exercise != next ]; then if git show origin/\$exercise:start.sh >/dev/null 2>&1 ; then if git checkout -f \$exercise >/dev/null 2>&1 && git reset --hard origin/\$exercise >/dev/null 2>&1 && git clean -fdx >/dev/null ; then if echo \"Preparing the exercise environment, hold on...\" && ./start.sh >/dev/null 2>&1; then echo \"Exercise \$exercise started!\" && echo 'Read the README.md for instructions or view them in browser:' && echo \"http://gitexercises.fracz.com/e/\$exercise\" ; else echo 'Could not execute the start script.' && echo 'Try running the ./start.sh script yourself.' ; fi else echo 'Could not clean the working directory.' && echo 'Make sure that none of the files inside the working directory' && echo 'is used by another process and run git start again.'; fi else echo \"Invalid exercise: \$exercise\" && false; fi else git push origin master:next-exercise 2>&1 | sed -n '/\\*\\*\\*/,/\\*\\*\\*/p' | grep -v '\\*\\*' | sed 's/remote: //g' | xargs git start | grep -v Invalid || echo 'You have passed all exercises!'; fi else echo 'You need to use git start <exercise-name> in detached HEAD'; fi }; f"
# Add "git verify" local alias for submitting exercises solutions.
-git config alias.verify "! f() { currentBranch=\$(git rev-parse --abbrev-ref HEAD); exercise=\${1-\$currentBranch}; if [ \$exercise != HEAD ]; then if git show origin/\$exercise:start.sh >/dev/null 2>&1 ; then if ! git status | grep 'up-to-date' >/dev/null 2>&1 ; then if echo \"Verifying the \$exercise exercise. Hold on...\" && git push -f origin HEAD:\$exercise 2>&1 | sed -n '/\\*\\*\\*/,/\\*\\*\\*/p' | sed 's/remote: //g' | grep -v \"\\*\\*\" ; then : ; else echo 'Solution could not be verified - push failed.' && echo 'Do you have an internet connection?'; fi else echo \"You haven't made any progress on exercise \$exercise.\" && echo 'Did you forget to commit your changes?'; fi else echo \"Invalid exercise: \$exercise\"; fi else echo 'You need to use git verify <exercise-name> in detached HEAD'; fi }; f"
+git config --local alias.verify "! f() { currentBranch=\$(git rev-parse --abbrev-ref HEAD); exercise=\${1-\$currentBranch}; if [ \$exercise != HEAD ]; then if git show origin/\$exercise:start.sh >/dev/null 2>&1 ; then if ! git status | grep 'up-to-date' >/dev/null 2>&1 ; then if echo \"Verifying the \$exercise exercise. Hold on...\" && git push -f origin HEAD:\$exercise 2>&1 | sed -n '/\\*\\*\\*/,/\\*\\*\\*/p' | sed 's/remote: //g' | grep -v \"\\*\\*\" ; then : ; else echo 'Solution could not be verified - push failed.' && echo 'Do you have an internet connection?'; fi else echo \"You haven't made any progress on exercise \$exercise.\" && echo 'Did you forget to commit your changes?'; fi else echo \"Invalid exercise: \$exercise\"; fi else echo 'You need to use git verify <exercise-name> in detached HEAD'; fi }; f"
# Add "git exercises" alias that shows list of available exercises.
-git config alias.exercises "! git push origin master:exercises 2>&1 | sed -n '/\\*\\*\\*/,/\\*\\*\\*/p' | grep -v '\\*\\*' | sed 's/remote: //g'"
+git config --local alias.exercises "! git push origin master:exercises 2>&1 | sed -n '/\\*\\*\\*/,/\\*\\*\\*/p' | grep -v '\\*\\*' | sed 's/remote: //g'"
# Make sure you have a "current" push strategy set; this will allow you to push only current exercise with simple git
# push command instead of pushing all matching branches (default in Git < 2.0)
this suppose to restrict scope of changes to the local exercise repository only.
Verifying the ignore-them exercise. Hold on...
Exercise: ignore-them
Status: error: The following untracked working tree files would be removed by checkout:
.gitignore
Please move or remove them before you switch branches.
Aborting
error: The following untracked working tree files would be removed by checkout:
.gitignore
Please move or remove them before you switch branches.
Aborting
error: The following untracked working tree files would be removed by checkout:
.gitignore
Please move or remove them before you switch branches.
Aborting
error: The following untracked working tree files would be removed by checkout:
.gitignore
Please move or remove them before you switch branches.
Aborting
error: The following untracked working tree files would be removed by checkout:
.gitignore
Please move or remove them before you switch branches.
Aborting
error: The following untracked working tree files would be removed by checkout:
.gitignore
Please move or remove them before you switch branches.
Aborting
error: The following untracked working tree files would be removed by checkout:
.gitignore
Please move or remove them before you switch branches.
Aborting
error: The following untracked working tree files would be removed by checkout:
.gitignore
Please move or remove them before you switch branches.
Aborting
error: The following untracked working tree files would be removed by checkout:
.gitignore
Please move or remove them before you switch branches.
Aborting
error: The following untracked working tree files would be removed by checkout:
.gitignore
Please move or remove them before you switch branches.
Aborting
error: The following untracked working tree files would be removed by checkout:
.gitignore
Please move or remove them before you switch branches.
Aborting
error: The following untracked working tree files would be removed by checkout:
.gitignore
Please move or remove them before you switch branches.
Aborting
FAILED
File with name 'libraries' would be ignored but it should not.
See your progress and instructions at:
https://gitexercises.fracz.com/c/qb8
it also happens when I don't make a .gitignore file, and don't put anything there.
Also, my content of my .gitignore is:
*.exe
*.o
*.jar
libraries/*
for libraries, I've tried: /libraries/*, **/libraries/, and many others.
This exercise does not ignore .exe files even if I put *.exe in a file named basic.gitignore
Originally posted by @martenhernebring in https://github.com/fracz/git-exercises/issue_comments/707965557
I tried to merge escaped to chase-branch but it says "Already up to date."
and then when I try to verify using "git verify", it says
"You haven't made any progress on exercise chase-branch.
Did you forget to commit your changes?"
Hi,
great job with this project!
I've walked through the exercises today, and I'd like to give my € 0.02 about the tips and solutions:
git merge --squash
rather than git cherry-pick
- Introducing cherry-pick to the newly-initiated might be a bad idea.git log -G '\bshit\b' --all-match
# jot down the revisions
git rebase -
# Search for the revisions, mark them as 'edit'
# Repeat for all revisions:
# Replace the bad word with good word (e.g. sed -i -e 's/^bad$/good/g words.txt)
git add *.txt
git commit --amend
git rebase --continue
Thanks again for the fun challenge :-)
touch .gitignore
echo >> .gitignore "*"
git add -f .gitignore
git commit -m "Still doesn't work"
git verify
Result: FAILED. Blah.exe is not ignored
Also fails with this .gitignore:
*.exe
*.jar
*.o
libraries/*
Existing example files are ignored by this .gitignore, but the generated blah.txt files always fail.
The repository is cloned in 'detached HEAD' state and there is no configure.sh
until I manually switch to master
- is that expected?
$ git clone https://gitexercises.fracz.com/git/exercises.git
Cloning into 'exercises'...
remote: Counting objects: 145, done.
remote: Compressing objects: 100% (111/111), done.
remote: Total 145 (delta 29), reused 144 (delta 29)
Receiving objects: 100% (145/145), 33.81 KiB | 2.11 MiB/s, done.
Resolving deltas: 100% (29/29), done.
Note: checking out '872524d604359dd8e235bc7f444e601ac88c228d'.
You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by performing another checkout.
If you want to create a new branch to retain commits you create, you may
do so (now or later) by using -b with the checkout command again. Example:
git checkout -b <new-branch-name>
$ cd exercises
$ ls
file.txt README.md start.sh
Hello, my college has assigned the first 7 exercises as work.
Been trying to do the "ignore-them" and keep failing at excluding the libraries folder.
Example of what I've tried:
/libraries
libraries/
libraries/*
None seem to work...
Git is able to remember the +x
flag for file. One exercise should demonstrate it.
Exercise: Commit one file
git start commit-one-file
Instructions
There are two files created in the root project directory - A.txt and B.txt.
The goal is to commit only one of them.
I don't see these files.
$ ls
./ .git/ configure.sh* test.txt
../ README.md start.sh*
Hi! I've tried to access the website to continue my progress on the challenge but I've got the invalid SSL screen.
Then I've checked the expiry date of the certificate and notice that it expired yesterday (2020-06-13).
Can you fix it? Thanks!! :)
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.