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 | |
| # Author: Joshua Moon <josh@jaw.sh> | |
| # Date: 14-May-2016 | |
| # Purpose: Creates an up-to-date Cloudflare nginx config file. | |
| # License: MIT | |
| ################################################################################ | |
| # INSTRUCTIONS |
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
| # Redirect http:// to https:// | |
| server { | |
| listen 80 default_server; | |
| listen [::]:80 default_server; | |
| server_name _; | |
| return 301 https://$host$request_uri; | |
| } | |
| # Redirect https://www to https:// |
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
| function isOnScreen(elem) { | |
| // if the element doesn't exist, abort | |
| if( elem.length == 0 ) { | |
| return; | |
| } | |
| var $window = jQuery(window) | |
| var viewport_top = $window.scrollTop() | |
| var viewport_height = $window.height() | |
| var viewport_bottom = viewport_top + viewport_height | |
| var $elem = jQuery(elem) |
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 | |
| ##################################################### | |
| # Name: Bash CheatSheet for Mac OSX | |
| # | |
| # A little overlook of the Bash basics | |
| # | |
| # Usage: | |
| # | |
| # Author: J. Le Coupanec | |
| # Date: 2014/11/04 |
NewerOlder