git
The error: "fatal: unable to create thread: Resource temporarily unavailable" strongly suggests you've run out of memory on the server, which can happen if you have a repository with lots of large files, which can cause re-packing to take a lot of memory, or limited virtual memory - either in general, or just for that account due to the ulimit setting.
Anyways, here's the commands you can run to limit the amount of memory that packing may take by logging into the remote system (as the user that git runs as) and typing these commands:
Amending the most recent commit message
git commit --amendWill open your editor, allowing you to change the commit message of the most recent commit.
Additionally, you can set the commit message directly in the command line with:
git commit --amend -m "New commit message"The wonderful cherry-pick
git-cherry-pick - Apply the changes introduced by some existing commits
Given one or more existing commits, apply the change each one introduces, recording a new commit for each. This requires your working tree to be clean (no modifications from the HEAD commit).
git fetch origin master (or whatever branch you need)and then
git cherry-pick <hash-of-commit-you-want>git ls-files --deleted -z | xargs -0 git rmgit add -u
git commitUntrack files from git
This will tell git you want to start ignoring the changes to the file
git update-index --assume-unchanged path/to/file
git filter-branch --index-filter 'git rm --cached --ignore-unmatch file.ext' --prune-empty -- --all
Git: fatal: remote origin already exists.
As the error message indicates, there is already a remote configured with the same name. So you can either add the new remote with a different name or update the existing one if you don't need it:
To add a new remote, called for example github instead of origin (which obviously already exists in your system), do the following:
$ git remote add github git@github.com:ppreyer/first_app.git
Other Git commands
List remotes repositories - git remote -v
To remove a remote on the local - git remote remove origin
An optional prefix ! which negates the pattern; any matching file excluded by a previous pattern will become included again. If a negated pattern matches, this will override lower precedence patterns sources.
# Ignore everything
*
# But not these files...
!.gitignore
!script.pl
!template.latex
!/public_html
# etc...
# ...even if they are in subdirectories
!*/
