Skip to content

Instantly share code, notes, and snippets.

View emilfolino's full-sized avatar

Emil Folino emilfolino

View GitHub Profile
<pre>Command: cd /home/efo/dbwebb/lab/config/linux/bash1_extra && rsync ./apache2/ports.conf
./apache2/md/
Status: 126
Output: -rw-r--r-- 320 2016/12/21 14:41:02 ports.conf
sh: 2: ./apache2/md/: Permission denied
12 envvars
12 ports.conf
16 apache2.conf
20 sites-enabled
24 conf-enabled
40 magic
68 sites-available
100 conf-available
128 mods-enabled
1652 mods-available
*================================================*
FAKTURA Faktura nr.: 1002
Kund: Företaget:
---------- ----------
Berit Båtklubben
Gubbiallén 14 Hamnen
45752 Fiskebyn
Kundnr.: 12
@emilfolino
emilfolino / gist:ca366f0ab7b78b0d136e92e495b11b38
Created April 4, 2017 07:23
dbwebb --dry validate example
This file has been truncated, but you can view the full file.
Uploading the directory '/home/efo/dbwebb/webapp/' to '[email protected]:dbwebb-kurser/webapp/' for validation.
sending incremental file list
./
sent 99,397 bytes received 521 bytes 39,967.20 bytes/sec
total size is 14,262,318 speedup is 142.74
Validating '/home/saxon/teachers/dipt/efostud/dbwebb-kurser/webapp/example'.
*.html using htmlhint
find "./example/" \( -not -path "*/.git/*" -not -path "*/build/*" -not -path "*/cache/*" -not -path "*/docs/*" -not -path "*/lib/*" -not -path "*.min.*" -not -path "*.png" -not -path "*.jpg" -not -path "./me/*/vendor/*" -not -path "./me/*/node_modules/*" -not -path "./me/*/platforms/*" -o -path "./me/*/platforms/browser/www/*.html" -o -path "./me/*/platforms/browser/www/css/*" -o -path "./me/*/platforms/browser/www/js/*" \) -type f -name "*.html"
htmlhint --config '/home/saxon/teachers/dipt/efostud/dbwebb-kurser/webapp/.htmlhintrc' './example/calendar/www/index.html' | grep -v "No problem." | grep -v "Config loaded." | grep -v "Scan " | grep -v "Scanned ";
Uploading the directory '/home/efo/dbwebb/webapp/' to '[email protected]:dbwebb-kurser/webapp/' for validation.
sending incremental file list
sent 5,078 bytes received 83 bytes 10,322.00 bytes/sec
total size is 1,439,375 speedup is 278.89
Validating '/home/saxon/teachers/dipt/efostud/dbwebb-kurser/webapp'.
*.html using htmlhint
find "./" \( -not -path "*/.git/*" -not -path "*/build/*" -not -path "*/cache/*" -not -path "*/docs/*" -not -path "*/lib/*" -not -path "*.min.*" -not -path "*.png" -not -path "*.jpg" -not -path "./me/*/vendor/*" -not -path "./me/*/node_modules/*" -not -path "./me/*/platforms/*" -o -path "./me/*/platforms/browser/www/*.html" -o -path "./me/*/platforms/browser/www/css/*" -o -path "./me/*/platforms/browser/www/js/*" \) -type f -name "*.html"
htmlhint --config '/home/saxon/teachers/dipt/efostud/dbwebb-kurser/webapp/.htmlhintrc' './example/calendar/www/index.html' | grep -v "No problem." | grep -v "Config loaded." | grep -v "Scan " | grep -v "Scanned "; test ${PIPESTATUS[0]}
@emilfolino
emilfolino / gist:2b6623ed795923aac74151655a211687
Created April 20, 2017 05:58
Log REM server på nodejs2.student.bth.se:8000
efostud@sweet: npm start
> [email protected] start /home/saxon/teachers/dipt/efostud/git/rem
> node index
Thu Apr 20 2017 07:50:46 GMT+0200 (CEST): GET /api/wines
Thu Apr 20 2017 07:50:55 GMT+0200 (CEST): GET /api/users
Thu Apr 20 2017 07:51:00 GMT+0200 (CEST): POST /api/wines
Thu Apr 20 2017 07:51:02 GMT+0200 (CEST): GET /api/wines
Thu Apr 20 2017 07:51:21 GMT+0200 (CEST): POST /api/wines
@emilfolino
emilfolino / tsp.rs
Created May 11, 2017 07:35
Travelling salesperson Rust implementation
use std::collections::HashMap;
fn main() {
let mut universities = HashMap::new();
universities.insert("BTH", (56.18, 15.59));
universities.insert("Uppsala", (59.85, 17.63));
universities.insert("Lund", (55.71, 13.20));
universities.insert("KTH", (59.34, 18.07));
universities.insert("Chalmers", (57.68, 11.97));
universities.insert("Luleå", (65.61, 22.14));
# 4(2R + r) = 1 Ekvation #1
# R = 1/8 - r/2
# R = 1/8 - (1/12 - R/3)/2
# 2R + 1/12 - R/3 = 1/4
# 5R = 1/2
#
R=1/10
#
#
# 4(R + 3r) = 1 Ekvation #2
@emilfolino
emilfolino / gist:8b29f5789847fa94d2c6dd4c5bb17711
Created February 19, 2018 08:24
Felmeddelanden studserver
Får massa såna här när jag kör npm install, för olika packet.
npm WARN tar ENOENT: no such file or directory, lstat '/home/saxon/teachers/dipt/efostud/git/order_api/node_modules/.staging/nyc-364d72b2/node_modules/yargs'
Sen får jag ett fel till slut:
npm ERR! path /home/saxon/teachers/dipt/efostud/git/order_api/node_modules/.staging/nyc-364d72b2/node_modules/yallist
npm ERR! code ENOENT
npm ERR! errno -2
npm ERR! syscall rename
##
# You should look at the following URL's in order to grasp a solid understanding
# of Nginx configuration files in order to fully unleash the power of Nginx.
# https://www.nginx.com/resources/wiki/start/
# https://www.nginx.com/resources/wiki/start/topics/tutorials/config_pitfalls/
# https://wiki.debian.org/Nginx/DirectoryStructure
#
# In most cases, administrators will remove this file from sites-enabled/ and
# leave it as reference inside of sites-available where it will continue to be
# updated by the nginx packaging team.