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 | |
| REPO=NAME_HERE | |
| # Dir paths on remote server | |
| # These are associated with branches within a git project | |
| LIVE_BRANCH="master" | |
| LIVE="git@host:/var/www/live/" | |
| STAGE_BRANCH="develop" | |
| STAGE="git@host:/var/www/stage/" |
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
| add_action( 'woocommerce_thankyou', 'my_custom_tracking' ); | |
| function my_custom_tracking( $order_id ) { | |
| // Lets grab the order | |
| $order = wc_get_order( $order_id ); | |
| /** | |
| * Put your tracking code here | |
| * You can get the order total etc e.g. $order->get_total(); |
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
| #include <stdio.h> | |
| /* count digits, white space, others */ | |
| int main() | |
| { | |
| int c, i, nwhite, nother; | |
| int ndigit[10]; | |
| nwhite = nother = 0; | |
| for (i = 0; i < 10; ++i) | |
| ndigit[i] = 0; | |
| while ((c = getchar()) != EOF) |
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
| camera = {} | |
| camera._x = 0 | |
| camera._y = 0 | |
| camera.scaleX = 1 | |
| camera.scaleY = 1 | |
| camera.rotation = 0 | |
| function camera:set() | |
| love.graphics.push() | |
| love.graphics.rotate(-self.rotation) |
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/sh | |
| # Converts a mysqldump file into a Sqlite 3 compatible file. It also extracts the MySQL `KEY xxxxx` from the | |
| # CREATE block and create them in separate commands _after_ all the INSERTs. | |
| # Awk is choosen because it's fast and portable. You can use gawk, original awk or even the lightning fast mawk. | |
| # The mysqldump file is traversed only once. | |
| # Usage: $ ./mysql2sqlite mysqldump-opts db-name | sqlite3 database.sqlite | |
| # Example: $ ./mysql2sqlite --no-data -u root -pMySecretPassWord myDbase | sqlite3 database.sqlite |
NewerOlder