| Instance | Branch |
|---|
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
| daemon off; | |
| error_log log/error.log crit; | |
| events { | |
| } | |
| http { | |
| uwsgi_temp_path tmp/; | |
| scgi_temp_path tmp/; | |
| proxy_temp_path tmp/; |
When the directory structure of your Node.js application (not library!) has some depth, you end up with a lot of annoying relative paths in your require calls like:
const Article = require('../../../../app/models/article');Those suck for maintenance and they're ugly.
THIS GIST WAS MOVED TO TERMSTANDARD/COLORS REPOSITORY.
PLEASE ASK YOUR QUESTIONS OR ADD ANY SUGGESTIONS AS A REPOSITORY ISSUES OR PULL REQUESTS INSTEAD!
(by @andrestaltz)
If you prefer to watch video tutorials with live-coding, then check out this series I recorded with the same contents as in this article: Egghead.io - Introduction to Reactive Programming.
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
| ------------------------------------------------------------------------- | |
| USEFUL ONE-LINE SCRIPTS FOR SED (Unix stream editor) Dec. 29, 2005 | |
| Compiled by Eric Pement - pemente[at]northpark[dot]edu version 5.5 | |
| Latest version of this file (in English) is usually at: | |
| http://sed.sourceforge.net/sed1line.txt | |
| http://www.pement.org/sed/sed1line.txt | |
| This file will also available in other languages: | |
| Chinese - http://sed.sourceforge.net/sed1line_zh-CN.html |
- Create an empty repo in BitBucket
git clone --bare git@github.com:user/repo.gitcd repo.gitgit push --mirror git@bitbucket.org:user/repo.git
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
| var useOldDownloadWay = false; | |
| var Nightmare = require('nightmare'); | |
| new Nightmare() | |
| .goto('http://eprint.iacr.org/2004/152') | |
| .evaluate(function ev(old){ | |
| var el = document.querySelector("[href*='.pdf']"); | |
| var xhr = new XMLHttpRequest(); | |
| xhr.open("GET", el.href, false); | |
| if (old) { |
You can run your Express app very easily inside your Electron app.
All you need to do is to:
- place all the files of your Express app inside a new app folder in
your_electron_app\resources\app - reconfigure the
app.jsfile - refactor some relative pathes in your Express app
OlderNewer