This is a Git Style Guide inspired by How to Get Your Change Into the LinuxKernel, the git man pages and various practices popular among the community.
This file contains 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
{ | |
"result": { | |
"states": [ | |
"آذربایجان شرقی", | |
"آذربایجان غربی", | |
"اردبیل", | |
"اصفهان", | |
"البرز", | |
"ایلام", | |
"بوشهر", |
This file contains 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
# install ffmpeg on windows machines: http://www.wikihow.com/Install-FFmpeg-on-Windows | |
ffmpeg -i inputfile.mp4 -r 24 -crf 18 -vcodec h264 -acodec aac outputfile.mp4 | |
This file contains 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
<div class="row"> | |
<div class="large-4 column"> | |
<h2 class="sec-title">ویژگیهای اصلی هتل</h2> | |
</div> | |
<div class="large-20 column"> | |
<dl class="row large-up-4"> | |
<dd class="column"><i class="fa fa-wifi"></i>اینترنت وایفای</dd> | |
<dd class="column"><i class="fa fa-plane"></i>انتقال از فرودگاه</dd> | |
<dd class="column"><i class="fa fa-bell"></i>روم سرویس</dd> |
This file contains 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
# Generate a new pgp key: (better to use gpg2 instead of gpg in all below commands) | |
gpg --gen-key | |
# maybe you need some random work in your OS to generate a key. so run this command: `find ./* /home/username -type d | xargs grep some_random_string > /dev/null` | |
# check current keys: | |
gpg --list-secret-keys --keyid-format LONG | |
# See your gpg public key: | |
gpg --armor --export YOUR_KEY_ID | |
# YOUR_KEY_ID is the hash in front of `sec` in previous command. (for example sec 4096R/234FAA343232333 => key id is: 234FAA343232333) |
node inspect app.js
type in console: c
(continue to end), n
(next expression), repl
(go into repl mode and do modifications or log), list(10)
to see 10 lines of code.
type debugger;
inside code (similar to breakpoint)
nodemon inspect-brk app.js
go to chrome://inspect
click to open dedicated devtools for Nodejs
This file contains 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
# sudo apt-get install obfs4proxy obfsproxy tor | |
# sudo vi /etc/tor/torrc | |
UseBridges 1 | |
ClientTransportPlugin obfs3 exec /usr/bin/obfsproxy managed | |
ClientTransportPlugin obfs4 exec /usr/bin/obfs4proxy managed | |
# send email to bridges@torproject.org with body `get transport obfs4` you can get new bridges. | |
bridge obfs4 195.154.49.15:44705 BACD07DACE996093DC7635F33A98C49... cert=xc/wtKNWADfJQf232xSXT0WpzsaINw6fgPvZBy5Rkw4.../ypaZPDug9L... iat-mode=0 |
/<div>.+</div>/
This will not match <div>text</div>
because .+
consumes </div>
characters. .+
uses greedy evaluation.
/<div>.+?</div>
This will match text
because .+?
uses lazy evaluation and returns control to next expression as it finds first match.
This file contains 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
#!/usr/bin/env bash | |
DOCKER_PATH=$(which docker) | |
# PORT Number Definition | |
# ---------------------------------------------- | |
# system ports | |
PORT_JENKINS="9110" | |
PORT_PORTAINER="9120" |
This file contains 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
sudo apt-get install software-properties-common | |
sudo add-apt-repository ppa:ondrej/php | |
sudo apt-get update | |
sudo apt-get install php5.6 | |
php --version | |
sudo apt-get install php5.6-curl php5.6-xml | |
sudo apt-get install composer |