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
#!/bin/sh | |
bc -l | |
scale=10000 | |
4*a(1) | |
3.141592653589793238462643383279502884197169399375105820974944592307 | |
81640628620899862803482534211706798214808651328230664709384460955058 | |
22317253594081284811174502841027019385211055596446229489549303819644 | |
28810975665933446128475648233786783165271201909145648566923460348610 |
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
# encoding: Windows-1252 | |
require "unicode_utils/downcase" | |
sentence_length = 20 # Change this to suit how short a sentence is useless. | |
saturs = File.read('te.csv').gsub(/([\t\r\n\v\f]+)/){ |m| " " } # IO read in text, removes newlines | |
saturs.gsub!(/([^ a-zA-Z\u00C0-\u017F\!\?\.]+)/){ |m| " " } | |
saturs.gsub! /(?<=[a-zA-Z\u00C0-\u017F])[ ]+[A-Z\p{Lu}]+[a-z\p{Ll}]*(?=[ ])/, '' # izņem Īpašvārdus teikuma vidū. |
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
0. set up sublime terminus: | |
$ echo "export PATH=~/bin:$PATH" >> ~/.profile | |
$ ln -s "/Applications/Sublime Text 2.app/Contents/SharedSupport/bin/subl" ~/bin/subl | |
(use with $ subl) | |
1. $ brew install fish | |
2. $ curl -L https://github.com/bpinto/oh-my-fish/raw/master/tools/install.fish | fish | |
3. add https://gist.github.com/Epigene/9bccb811c8b15524cfbc contents to ~/.config/fish/config.fish | |
4. $ sudo nano /etc/shells # and add "/usr/local/bin/fish" bin path for fish | |
5. set to default: | |
$ grep -q '^/usr/local/bin/fish$' /etc/shells; or echo '/usr/local/bin/fish' | sudo tee -a /etc/shells |
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 ruby | |
# Usage: paste in a file and call it in console with `ruby filename` | |
# inicializē datu struktūras | |
musejie = [] | |
`rm out.csv` ; `touch out.csv` | |
#ielasa no faila pasaucot shell command | |
musejie = `cat musejie.csv`.split.uniq # musejie.csv satur ierakstus katru jaunā rindiņā caur kuriem laist ciklu |
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
tell application "Google Chrome" | |
open location "https://www.stockholmhealth.com/lv/lv/p/e/landing" | |
end tell | |
tell application "Terminal" | |
do script "cd ~/Desktop" in front window | |
set position of window 1 to {1320, 22} | |
set size of first window to {600, 450} | |
activate |
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
Show hidden characters
{ | |
"auto_complete": false, | |
"bold_folder_labels": true, | |
"caret_style": "phase", | |
"color_scheme": "Packages/User/Antigua.tmTheme", | |
"default_line_ending": "unix", | |
"detect_indentation": false, | |
"detect_slow_plugins": false, | |
"fallback_encoding": "UTF-8", | |
"find_selected_text": true, |
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
git fetch | |
git merge | |
git checkout --ours . # checkout our local version of all files | |
git add -u # mark all conflicted files as merged | |
git commit -am "Successful merge" # commit the merge |
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
user www-data; | |
worker_processes 4; | |
pid /run/nginx.pid; | |
events { | |
worker_connections 10000; | |
# multi_accept on; | |
} | |
http { |
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
## | |
## Here is what image already has | |
## | |
#add repos | |
add-apt-repository ppa:nginx/stable | |
add-apt-repository ppa:chris-lea/node.js | |
sudo sh -c "echo 'deb http://apt.postgresql.org/pub/repos/apt/ precise-pgdg main' > /etc/apt/sources.list.d/pgdg.list" | |
wget --quiet -O - http://apt.postgresql.org/pub/repos/apt/ACCC4CF8.asc | sudo apt-key add - |
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
# Postgres database | |
# Check online for the newst version number | |
sudo apt-get -y install postgresql-common postgresql-9.3 | |
sudo -u postgres psql | |
# create database <app> owner creative; | |
# Configure GIT | |
git config --global user.name "<YourGitName>" |
OlderNewer