Konkreetne | Abstraktne
====================================================
roheline - värv
Clojure - programmeerimiskeel
minu iPhone, praegusel ajahetkel - lihtsalt telefon
Juku - loll
Programmeerija firmas X - töökoht
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
/** | |
* Secure programming HW4 | |
* Find all potential vulnerabilities in this C function get_user_input | |
* Compiling: $ make main | |
* Running: $ ./main | |
*/ | |
#include <stdio.h> | |
#include <stdlib.h> // For malloc | |
#include <string.h> // For strlen |
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/bash | |
echo Doing it now! |
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/bash | |
echo "This script checks if you have all dependencies installed" | |
# Check for RVM | |
#RESULT= `type rvm | head -1` | |
RESULT="rvm is a function" | |
echo $RESULT | |
if [[ $RESULT = "rvm is a function" ]]; then | |
echo "RVM is OK" |
- crtl+cmd+g - select matching text
- crtl+m - jump to matching bracket
- crtl+left/right - move cursor left / right word segment
- crtl+k+d - discard current selection and create a cursor at the next
Create ctags file for SublimeText containing current floder + used gemsets - ctags --extra=+f --exclude=.git --exclude=log -f .tags -R . `rvm gemdir`/gems/*
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
RED="\[\033[0;31m\]" | |
YELLOW="\[\033[0;33m\]" | |
GREEN="\[\033[0;32m\]" | |
BLUE="\[\033[0;34m\]" | |
LIGHT_RED="\[\033[1;31m\]" | |
LIGHT_GREEN="\[\033[1;32m\]" | |
WHITE="\[\033[1;37m\]" | |
LIGHT_GRAY="\[\033[0;37m\]" | |
DARK_GRAY="\[\033[0;90m\]" | |
COLOR_NONE="\[\e[0m\]" |
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
```bash | |
# Make a POST request with post parameter | |
# -i for showing headers | |
# -d for passing post parameters | |
curl -i -d "site_key=almost_random" -X POST http://localhost:3001/api/visits | |
# Save a cookie in a file | |
curl -c visits_cookie.txt -d "site_key=almost_random" -X POST http://localhost:3001/api/visits | |
# Make a POST request with cookie |
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 | |
### BEGIN INIT INFO | |
# Provides: redis-server | |
# Required-Start: $syslog $remote_fs | |
# Required-Stop: $syslog $remote_fs | |
# Should-Start: $local_fs | |
# Should-Stop: $local_fs | |
# Default-Start: 2 3 4 5 | |
# Default-Stop: 0 1 6 | |
# Short-Description: redis-server - Persistent key-value db |
OlderNewer