Ignore local changes to repository files or directories git update-index --assume-unchanged path/to/file/or/directory
Or you can alias it in your ~/.gitconfig [alias] au = update-index --assume-unchanged
#301 Redirects for .htaccess | |
#Redirect a single page: | |
Redirect 301 /pagename.php http://www.domain.com/pagename.html | |
#Redirect an entire site: | |
Redirect 301 / http://www.domain.com/ | |
#Redirect an entire site to a sub folder | |
Redirect 301 / http://www.domain.com/subfolder/ |
Following the AngularJS PARIS meetup (25/2 à 19h à Paris with @sampaccoud @dzen @_kemar @tchack13 @vinz et @revolunet)
Here's our best AngularJS ressources : twitter, github, articles & blogs. Please comment and add your good stuff !
First of all you need to be able to run MAMP in port 80. This is a "heat check" if you don't have any process jamming http ports. You can check it like this:
sudo lsof | grep LISTEN
If you do happen to have any process with something like this *:http (LISTEN)
, you are in trouble. Before with adventure check if it isn't MAMP itself (yeah, you should close that beforehand)
ps <pid of that process>
If you don't see MAMP, you are in good hands, I have just the thing for you:
/*******************************************************/ | |
/ Shared by www.codewordpress.com / | |
/ Add following code to Function.php file in your theme / | |
/*******************************************************/ | |
<?php | |
function getPostViews($postID){ | |
$count_key = 'post_views_count'; | |
$count = get_post_meta($postID, $count_key, true); | |
if($count==''){ |
# --------------------------------------------------------------------------- | |
# | |
# Description: This file holds all my BASH configurations and aliases | |
# | |
# Sections: | |
# 1. Environment Configuration | |
# 2. Make Terminal Better (remapping defaults and adding functionality) | |
# 3. File and Folder Management | |
# 4. Searching | |
# 5. Process Management |
These instructions will guide you through the process of setting up local, trusted websites on your own computer.
These instructions are intended to be used on macOS Sierra, but they have been known to work in El Capitan, Yosemite, Mavericks, and Mountain Lion.
NOTE: You may substitute the edit
command for nano
, vim
, or whatever the editor of your choice is. Personally, I forward the edit
command to Sublime Text:
alias edit="/Applications/Sublime\ Text.app/Contents/SharedSupport/bin/subl"
var getRelationship = function(x, y) { | |
// If both arguments are numbers | |
if ( !isNaN(x) && !isNaN(y) ) { | |
if ( x == y ) { // if they are equal, return '=' | |
return '='; | |
} else { // if not, return comparison operator | |
return x < y ? '<' : '>'; |