Project | Long Running Ruby and Rails Benchmarks | |
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
def timeleft(age): | |
return 2014+(100-int(age)) | |
name=input("Tell me your name: ") | |
age=input("And age: ") | |
print(timeleft(age)) | |
if int(age)<31: | |
print("Well, hello " + name + "\nYou are still pretty young. You will turn 100 years old in ",timeleft(age)," years. Enjoy your life. :) ") | |
elif int(age)>=100: |
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
# Coding folder | |
mkdir ~/dev | |
# vim | |
sudo apt-get install vim | |
# git | |
sudo apt-get install git |
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
# Stolen from here https://www.tylernichols.com/apple/speed-up-mouse-tracking-on-mac-os-x | |
defaults write -g com.apple.mouse.scaling 6.0 | |
# Boost keyboard speed | |
defaults write NSGlobalDomain KeyRepeat -int 1 |
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
# Dock to the bottom | |
gsettings set com.canonical.Unity.Launcher launcher-position Bottom | |
# Dock to the left | |
gsettings set com.canonical.Unity.Launcher launcher-position Left | |
# Source | |
https://www.howtogeek.com/251616/how-to-move-the-unity-desktops-launcher-to-the-bottom-of-your-screen-on-ubuntu-16.04/ |
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 running queries (9.2) | |
SELECT pid, age(clock_timestamp(), query_start), usename, query | |
FROM pg_stat_activity | |
WHERE query != '<IDLE>' AND query NOT ILIKE '%pg_stat_activity%' | |
ORDER BY query_start desc; | |
-- kill running query | |
SELECT pg_cancel_backend(procpid); | |
-- kill idle query |
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
Opis ideje za sajt za prikaz zemalja u koje mogu putovati srpski državljani za vreme covid-19 pandemije. | |
- Skrejpuj http://www.mfa.gov.rs/sr/index.php/konzularni-poslovi/putovanja-u-inostranstvo/vesti-za-putovanja-u-inostranstvo/22669-----------covid-19?lang=lat | |
- Stavi u tabelu po zemljama sa kolonama MOZE / NE MOZE | |
- Odredi da li se moze na osnovu prve recenice (ako prva recenica sadrzi 'moze' onda se moze, ako sadrzi 'ne moze' onda se ne moze) | |
- Omoguci opciju za prikaz celokupnog teksta za odredjenu drzavu | |
- Omoguci subscribe na odredjenu zemlju |
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 node lts version | |
curl -sL install-node.now.sh/lts | sudo bash |
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
{ | |
"push": { | |
"changes": [ | |
{ | |
"forced": false, | |
"old": { | |
"name": "master", | |
"links": { | |
"commits": { | |
"href": "https://api.bitbucket.org/2.0/repositories/bmarko021/test/commits/master" |
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
# disable sleep | |
sudo pmset -b sleep 0; sudo pmset -b disablesleep 1 | |
# re-enable sleep | |
sudo pmset -b sleep 5; sudo pmset -b disablesleep 0 |
OlderNewer