This file contains hidden or 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
| class I18n | |
| method_alias_chain :translate, :helper | |
| DEFAULTMEHOPTIONS= {helper: true} | |
| def translate_with_helper key, options | |
| options = DEFAULTMEHOPTIONS.merge(options) | |
| txt = translate_without_helper key, options |
This file contains hidden or 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
| #include <stdio.h> | |
| #include <unistd.h> | |
| #include <signal.h> | |
| static char keep_running; | |
| void handler(int signal) { | |
| printf("Got signal %i, closing down soon!\n", signal); | |
| keep_running = 0; | |
| } |
This file contains hidden or 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
| # service nginx configtest | |
| Testing nginx configuration: nginx: [emerg] unknown directive " " in /etc/nginx/sites-enabled/paagrank:5 | |
| nginx: configuration file /etc/nginx/nginx.conf test failed |
This file contains hidden or 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
| class Person | |
| include Webhook | |
| end | |
| module Webhook | |
| included do | |
| before_save :store_changes | |
| after_save :execute_webhook_after_save | |
| after_destroy :execute_webhook_after_destroy | |
| end |
This file contains hidden or 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
| require 'capybara/dsl' | |
| require 'capybara-webkit' | |
| include Capybara::DSL | |
| Capybara.current_driver = :webkit | |
| Capybara.app_host = "http://vunet.vu.nl" | |
| module Runner | |
| extend self |
This file contains hidden or 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 | |
| def get_env_or_fail(name) | |
| if ENV.has_key?(name) | |
| ENV[name] | |
| else | |
| $stderr.puts "Missing variable: #{name}" | |
| exit 1 | |
| end | |
| end |
This file contains hidden or 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
| h$ erl -pa ebin/ | |
| Erlang R16B01 (erts-5.10.2) [source-bdf5300] [64-bit] [smp:4:4] [async-threads:10] [hipe] [kernel-poll:false] | |
| Eshell V5.10.2 (abort with ^G) | |
| 1> c(simple_search_server). | |
| simple_search_server.erl:none: no such file or directory | |
| error | |
| 2> l(simple_search_server). | |
| {module,simple_search_server} | |
| 3> simple_search_server:start_link(). |
This file contains hidden or 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
| commit e69b947e134420e1a538220de5bf5501390a6e43 | |
| Author: Maarten Hoogendoorn <maarten@moretea.nl> | |
| Date: Thu Sep 12 10:12:56 2013 +0200 | |
| Adapt Makefile so that it runs both on my machine as the UvA machines | |
| diff --git a/Makefile b/Makefile | |
| index 49430e4..71b0200 100644 | |
| --- a/Makefile | |
| +++ b/Makefile |
This file contains hidden or 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
| #include "aca2013.h" | |
| #include <systemc.h> | |
| #include <iostream> | |
| using namespace std; | |
| SC_MODULE(Thing) { | |
| public: | |
| sc_in<bool> clk; | |
| SC_CTOR(Thing) { |
This file contains hidden or 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
| maarten@maarten-laptop:~/vu/ms/pcs/heat/omp$ make heat_test | |
| gcc -std=gnu99 -DHAVE_CONFIG_H -I. -I./../src -DTESTS_ENABLED -g3 -O0 -g -O2 -Wall -fopenmp -MT heat_test-heat_test.o -MD -MP -MF .deps/heat_test-heat_test.Tpo -c -o heat_test-heat_test.o `test -f 'heat_test.c' || echo './'`heat_test.c | |
| heat_test.c: In function ‘test_self_weight_simple’: | |
| heat_test.c:185:18: warning: assignment from incompatible pointer type [enabled by default] | |
| heat_test.c:190:3: warning: passing argument 1 of ‘free’ discards ‘volatile’ qualifier from pointer target type [enabled by default] | |
| /usr/include/stdlib.h:488:13: note: expected ‘void *’ but argument is of type ‘volatile double * volatile’ | |
| heat_test.c:191:3: warning: passing argument 1 of ‘free’ discards ‘volatile’ qualifier from pointer target type [enabled by default] | |
| /usr/include/stdlib.h:488:13: note: expected ‘void *’ but argument is of type ‘volatile double * volatile’ | |
| heat_test.c:176:16: warning: unused variable ‘expect’ [-Wunused-variable] | |
| mv -f .deps/heat_test-heat_t |