Skip to content

Instantly share code, notes, and snippets.

View A-D-E-A's full-sized avatar
🗿

Adam Dimitry Enzo Ambrosino A-D-E-A

🗿
  • Aberia
  • France
  • 18:25 (UTC +02:00)
View GitHub Profile
@pirate
pirate / docker-compose-backup.sh
Last active July 14, 2024 22:04
Backup a docker-compose project, including all images, named and unnamed volumes, container filesystems, config, logs, and databases.
#!/usr/bin/env bash
### Bash Environment Setup
# http://redsymbol.net/articles/unofficial-bash-strict-mode/
# https://www.gnu.org/software/bash/manual/html_node/The-Set-Builtin.html
# set -o xtrace
set -o errexit
set -o errtrace
set -o nounset
set -o pipefail
@tomykaira
tomykaira / subpatch.sh
Created July 10, 2015 06:55
save and apply patches for git submodules
#!/bin/sh -e
separator="----8<----8<----8<----8<----"
function make_chunk {
cd $1
if ! git diff --exit-code --ignore-submodules --quiet; then
echo "${PWD#$root}/"
git --no-pager diff --no-color --ignore-submodules
echo "$separator"
@danielestevez
danielestevez / gist:2044589
Last active June 30, 2024 09:04
GIT Commit to an existing Tag
1) Create a branch with the tag
git branch {tagname}-branch {tagname}
git checkout {tagname}-branch
2) Include the fix manually if it's just a change ....
git add .
git ci -m "Fix included"
or cherry-pick the commit, whatever is easier
git cherry-pick {num_commit}