Git default configuration is good but it can be personalized to improve your workflow efficiency.
Here are some good lines to put in your ~/.gitconfig:
# The basics, who you commit as:
[user]
name = John Doe
email = [email protected]| (function(doc, script) { | |
| var js, | |
| fjs = doc.getElementsByTagName(script)[0], | |
| add = function(url, id) { | |
| if (doc.getElementById(id)) {return;} | |
| js = doc.createElement(script); | |
| js.src = url; | |
| js.async=true; | |
| id && (js.id = id); | |
| fjs.parentNode.insertBefore(js, fjs); |
| #!/bin/bash | |
| # | |
| # Watch current directory (recursively) for file changes, and execute | |
| # a command when a file or directory is created, modified or deleted. | |
| # | |
| # Written by: Senko Rasic <[email protected]> | |
| # | |
| # Requires Linux, bash and inotifywait (from inotify-tools package). | |
| # | |
| # To avoid executing the command multiple times when a sequence of |
| xmlin = prompt(); // view-source:biochemistri.es/sitemap1.xml | |
| parser = new DOMParser(); | |
| xmlDoc=parser.parseFromString(xmlin,"text/xml"); | |
| xmlDoc.querySelectorAll('loc')[0].remove(); | |
| posts = xmlDoc.querySelectorAll('loc'); | |
| postlist = []; | |
| for (i=0;i<posts.length;i++) {postlist.push(posts[i].innerHTML)}; | |
| copy(postlist.join('\t')); // Chronological list of all posts as .tsv |
| /* Tested with jquery-1.7.2.min.js */ | |
| $(window).load(function () { | |
| "use strict"; | |
| /* Cycles XML file on successful load via ajax and parses contents into HTML */ | |
| function parseXML(xml) { | |
| /* Variable declaration */ | |
| var outHTML = "", employee, sId, sFirstname, sSurname, sAddress; |
| /* | |
| Folder structure : | |
| /frontend <-- AngularJS app | |
| /dist <-- Production ready files | |
| /assets | |
| /css | |
| /js | |
| index.html | |
| /src <-- Source files |
| # Was asked how I keep my zshrc config sync'd between my computers with Dropbox | |
| # Add a new directory in your Dropbox (or use an existing one) | |
| mkdir -p ~/Dropbox/ohmyzsh | |
| # move existing file to Dropbox | |
| mv ~/.zshrc ~/Dropbox/ohmyzsh/zshrc | |
| # symlink file back to your local directory | |
| ln -s ~/Dropbox/ohmyzsh/zshrc ~/.zshrc |
| <!-- pre-DNS resolve a domain --> | |
| <link rel="dns-prefetch" href="//widget.com"> | |
| <!-- pre-connect to a domain HTTP endpoint --> | |
| <link rel="preconnect" href="//cdn.example.com"> | |
| <!-- pre-fetch a resource, here an | |
| image needed on the page --> | |
| <link rel="prefetch" href="//example.com/logo.jpg" as="image"> |
| SELECT | |
| t.cid AS mid, | |
| t.email_ AS email, | |
| t.group_id_ AS group_id, | |
| GROUP_CONCAT(t.fname_ SEPARATOR '') AS fname, | |
| GROUP_CONCAT(t.lname_ SEPARATOR '') AS lname, | |
| t.street_ AS street, | |
| GROUP_CONCAT(t.city_ SEPARATOR '') AS city, | |
| GROUP_CONCAT(t.state_code_ SEPARATOR '') AS state_code, | |
| GROUP_CONCAT(t.zip_ SEPARATOR '') AS zip, |
| <?php | |
| /** | |
| * Return the permalink of the shop page for the continue shopping redirect filter | |
| * | |
| * @param string $return_to | |
| * @return string | |
| */ | |
| function my_woocommerce_continue_shopping_redirect( $return_to ) { | |
| return get_permalink( wc_get_page_id( 'shop' ) ); | |
| } |
Git default configuration is good but it can be personalized to improve your workflow efficiency.
Here are some good lines to put in your ~/.gitconfig:
# The basics, who you commit as:
[user]
name = John Doe
email = [email protected]