Short excursion into git --track, --set-upstream and --set-upstream-to.
All examples use the aliases co for checkout and br for branch.
Setup:
$ git clone [email protected]:AKSW/OntoWiki.git
| // Brightness math based on: | |
| // http://www.nbdtech.com/Blog/archive/2008/04/27/Calculating-the-Perceived-Brightness-of-a-Color.aspx | |
| $red-magic-number: 241; | |
| $green-magic-number: 691; | |
| $blue-magic-number: 68; | |
| $brightness-divisor: $red-magic-number + $green-magic-number + $blue-magic-number; | |
| @function brightness($color) { | |
| // Extract color components |
| /** | |
| * Changes value to past tense. | |
| * Simple filter does not support irregular verbs such as eat-ate, fly-flew, etc. | |
| * http://jsfiddle.net/bryan_k/0xczme2r/ | |
| * | |
| * @param {String} value The value string. | |
| */ | |
| Vue.filter('past-tense', function(value) { | |
| // Slightly follows http://www.oxforddictionaries.com/us/words/verb-tenses-adding-ed-and-ing | |
| var vowels = ['a', 'e', 'i', 'o', 'u']; |
Short excursion into git --track, --set-upstream and --set-upstream-to.
All examples use the aliases co for checkout and br for branch.
Setup:
$ git clone [email protected]:AKSW/OntoWiki.git
| @function mapReverse ($map) { | |
| $result: null; | |
| @if type-of($map) == "map" { | |
| $keys: map-keys($map); | |
| $map-reversed: (); | |
| @for $i from length($keys) through 1 { | |
| $map-reversed: map-merge( | |
| $map-reversed, |
This is way more complicated than it should be. The following conditions need to be met :
In this particular case, I'm interested in bringing in the 'default' template of jsdoc as a sub-directory in my project so I could potentially make changes to the markup it genereates while also being able to update from upstream if there are changes. Ideally their template should be a separate repo added to jsdoc via a submodule -- this way I could fork it and things would be much easier.... but, it is what it is.
After much struggling with git, subtree and git-subtree, I ended up finding this http://archive.h2ik.co/2011/03/having-fun-with-git-subtree/ -- it basically sets up separate branches from tracking remote, the particular sub-directory, and uses git subtree contrib module to pull it all togther. Following are
| set sftp:auto-confirm "yes" | |
| set sftp:connect-program "ssh -v -a -x -i D:\path\to\key" | |
| open sftp://user:password@site:port | |
| mirror -R --verbose --use-pget-n=8 -c /cygdrive/driveletter/folder /remote/path; |
| /* | |
| |-------------------------------------------------------------------------- | |
| | Vue BEM Directive | |
| |-------------------------------------------------------------------------- | |
| | | |
| | If you find yourself writing a lot of long, tedious CSS class names in | |
| | order to be consistent with the BEM naming convention, then try this | |
| | directive. It automagically does all the heavy lifting based on | |
| | the component's name found in $options.name. | |
| | |
| $columns: 12 !default; | |
| $gutter: 30px !default; | |
| $max-width: 1170px; | |
| .grid { | |
| margin: 0px auto; | |
| max-width: $max-width; | |
| width: 100%; | |
| } |
| # Get Sudo. | |
| if [ $EUID != 0 ]; then | |
| sudo "$0" "$@" | |
| exit $? | |
| fi | |
| # Install Xcode first - https://itunes.apple.com/us/app/xcode/id497799835?ls=1&mt=12 | |
| # Install Xcode command line tools. | |
| xcode-select --install |
Here are the simple steps needed to create a deployment from your local GIT repository to a server based on this in-depth tutorial.
You are developing in a working-copy on your local machine, lets say on the master branch. Most of the time, people would push code to a remote server like github.com or gitlab.com and pull or export it to a production server. Or you use a service like deepl.io to act upon a Web-Hook that's triggered that service.