This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Rsync with statistics and progress info Deleting files at destination, compressing during transfer | |
| rsync -ahivzW --dry-run --progress --delete /tmp/source user@10.2.2.1:/tmp/destination --stats | |
| # same but output to a file | |
| rsync -ahivzW --dry-run --progress --delete /tmp/source user@10.2.2.1:/tmp/destination --stats > rsync_output.txt | |
| # less verbose without showing individual files progress | |
| rsync -ahivzW --dry-run --delete /tmp/source user@10.2.2.1:/tmp/destination --stats | |
| rsync -ahivzW --dry-run --progress --delete /tmp/source user@10.2.2.1:/tmp/destination --stats --log-file=/tmp/rsync.log |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # getting a ROLE/USER to be able to execute commands over the entities we have | |
| ALTER SESSION SET CURRENT_SCHEMA = MY_SCHEMA_NAME; | |
| # looking for the configuration | |
| SELECT * FROM NLS_DATABASE_PARAMETERS; | |
| # restoring a lost entry | |
| INSERT INTO employees | |
| (SELECT * FROM employees | |
| AS OF TIMESTAMP |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| for i in *.txt; do echo mv $i ${i%%.sample.txt}.txt; done | |
| # for example my.sample.txt -> my.txt |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #MAILTO= | |
| # +--------- Minute (0-59) | Output Dumper: >/dev/null 2>&1 | |
| # | +------- Hour (0-23) | Multiple Values Use Commas: 3,12,47 | |
| # | | +----- Day Of Month (1-31) | Do every X intervals: */X -> Example: */15 * * * * Is every 15 minutes | |
| # | | | +--- Month (1 -12) | Aliases: @reboot -> Run once at startup; @hourly -> 0 * * * *; | |
| # | | | | +- Day Of Week (0-6) (Sunday = 0) | @daily -> 0 0 * * *; @weekly -> 0 0 * * 0; @monthly ->0 0 1 * *; | |
| # | | | | | | @yearly -> 0 0 1 1 *; | |
| # * * * * * COMMAND | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| [user] | |
| name = Username | |
| email = valid@email.com | |
| [core] | |
| excludesfile = ~/.gitignore | |
| fileMode = false | |
| [alias] | |
| co = checkout |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| #============================================================================= | |
| # | |
| # FILE: list_dates.sh | |
| # | |
| # USAGE: list_dates.sh start_date end_date | |
| # | |
| # DESCRIPTION: List the dates between a given range of dates. | |
| # | |
| #============================================================================= |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| if [ -z "$1" ] | |
| then | |
| echo "Usage $0 FILENAME" | |
| exit 86 | |
| fi | |
| file_from=$1; | |
| file_to="$1.utf8"; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| FILENAME='unified/MERGED_FILENAME.txt' | |
| `rm $FILENAME` | |
| `touch $FILENAME` | |
| FILES2012=`ls files/ | grep -E "FILENAME2012[0-9]{1,}\.txt"` | |
| for file in $FILES2012; do |