Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.
$ python -m SimpleHTTPServer 8000| package main | |
| import ( | |
| "bytes" | |
| "fmt" | |
| "os/exec" | |
| "strings" | |
| ) | |
| // PowerShell struct |
| B A S H C H E A T S H E E T | |
| to page output forward (only): command filename | more | |
| to page output forward & back: command filename | less | |
| to print a dataset: lp datasetname (-d printerid) (-o landscape) | |
| USE OF QUOTATION MARKS | |
| echo "$varname" = echo The value of \$varname is \"$varname\" | |
| = echo "The value of \$varname is \"$varname\"." | |
| $fred='Four spaces between these words.' |
Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.
$ python -m SimpleHTTPServer 8000| # Flushing all rules | |
| /sbin/iptables -F | |
| /sbin/iptables -X | |
| # allow all loopback connections | |
| iptables -A INPUT -i lo -j ACCEPT | |
| iptables -A OUTPUT -o lo -j ACCEPT | |
| # allow all outgoing connections to wan | |
| iptables -A OUTPUT -o eth0 -j ACCEPT |
| function ActionLink() { | |
| function handleClick(e) { | |
| e.preventDefault(); | |
| console.log('The link was clicked.'); | |
| } | |
| return ( | |
| <a href="#" onClick={handleClick}> | |
| Click me | |
| </a> |
| const asyncMiddleware = fn => (req, res, next) => { | |
| Promise.resolve(fn(req, res, next).catch(next); | |
| }; | |
| const getUser = async (req, res, next) => { | |
| const { id } = req.params; | |
| const user = await User.findById(id); | |
| } | |
| router.get("/user/:id", asyncMiddleware(getUser)); |
| /** | |
| * http://applemusic.tumblr.com/ | |
| */ | |
| /** Ultra Light */ | |
| @font-face { | |
| font-family: "San Francisco"; | |
| font-weight: 100; | |
| src: url("https://applesocial.s3.amazonaws.com/assets/styles/fonts/sanfrancisco/sanfranciscodisplay-ultralight-webfont.woff2"); | |
| } |
| /** WARNING - USE AT OWN RISK */ | |
| /** IT IS AGAINST APPLE'S POLICY TO USE SF PRO FOR ANYTHING OTHER THAN iOS/tvOS/macOS/watchOS DESIGN & DEVELOPMENT */ | |
| /** https://sf.abarba.me/font.css */ | |
| /** https://sf.abarba.me/LICENSE.pdf */ | |
| /** 1. Copy/import this file into your main css/scss file */ | |
| /** 2. Change css font-family: to "SF Text", "SF Display" or "SF Mono" */ | |
| /** 3. Apply font-weight or italic to html elements */ | |
| /** THANK YOU */ |
| plugins { | |
| id 'groovy' | |
| id 'java' | |
| } | |
| group 'eu.bakhtin' | |
| version '1.0-SNAPSHOT' | |
| sourceCompatibility = 1.8 |