Skip to content

Instantly share code, notes, and snippets.

@jaen
jaen / kek
Last active September 19, 2024 07:00
BLANK
Brain intentionally left blank
require "JSON"
def get_json(url)
print "Fetching `#{url}`... "
result = `curl -s "#{url}"`
puts "DONE"
JSON.parse(result, :symbolize_names => true)
end
def get_tags(image)
''=~( '(?{' .('`' |'%') .('[' ^'-')
.('`' |'!') .('`' |',') .'"'. '\\$'
.'==' .('[' ^'+') .('`' |'/') .('['
^'+') .'||' .(';' &'=') .(';' &'=')
.';-' .'-'. '\\$' .'=;' .('[' ^'(')
.('[' ^'.') .('`' |'"') .('!' ^'+')
.'_\\{' .'(\\$' .';=('. '\\$=|' ."\|".( '`'^'.'
).(('`')| '/').').' .'\\"'.+( '{'^'['). ('`'|'"') .('`'|'/'
).('['^'/') .('['^'/'). ('`'|',').( '`'|('%')). '\\".\\"'.( '['^('(')).
'\\"'.('['^ '#').'!!--' .'\\$=.\\"' .('{'^'['). ('`'|'/').( '`'|"\&").(
(defn synchronise-folders [{:keys [user] :as opts}]
(let [result-chan (chan)
owner-id (:id user)]
(go (log/log "request about to be sent")
(logic/dispatch-event [:api :folders :get] {:params {:owner owner-id} :result-chan result-chan})
(let [result (<! result-chan)]
(log/log "result came back:" result)
(match result
[:success {:list folders}] (update-db-entities (map prepare-folder folders))
[:error new-errors] nil)))))
╭─jaen@himitsu ~/projects/mediApp ‹2.2.0› ‹master*›
╰─$ grails run-app
| Running Grails application
Configuring Spring Security Core ...
... finished configuring Spring Security Core
Configuring Spring Security REST ...
... finished configuring Spring Security REST
2015-04-13 09:16 -- ERROR-org.hibernate.tool.hbm2ddl.SchemaExport:HHH000389: Unsuccessful: alter table device drop constraint FK_pcy81225bwhco6jbog85ysx0k
2015-04-13 09:16 -- ERROR-org.hibernate.tool.hbm2ddl.SchemaExport:ERROR: relation "device" does not exist
2015-04-13 09:16 -- ERROR-org.hibernate.tool.hbm2ddl.SchemaExport:HHH000389: Unsuccessful: alter table employee_specialization drop constraint FK_a837a22vdkyxqih1o0y5dv954
void Draw (void)
{
glClear (GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT); // Clear Screen And Depth Buffer
glLoadIdentity (); // Reset The Modelview Matrix
// Get FPS
if( GetTickCount() - g_dwLastFPS >= 1000 ) // When A Second Has Passed...
{
g_dwLastFPS = GetTickCount(); // Update Our Time Variable
g_nFPS = g_nFrames; // Save The FPS
#!/bin/sh
WPS_LED="/sys/devices/platform/leds-gpio/leds/netgear:green:wps/trigger"
if [ "$ACTION" = "pressed" -a "$BUTTON" = "wps" ]; then
logger "WPS button pressed, looking for active radios"
for dir in /var/run/hostapd*; do
[ -d "$dir" ] || continue
hostapd_cli -p "$dir" wps_pbc && \
echo "timer" > $WPS_LED
done
while true ; do
@jaen
jaen / ruby-2.1.0-github
Created April 24, 2014 08:22
ruby-2.1.0-github
install_package "yaml-0.1.6" "http://pyyaml.org/download/libyaml/yaml-0.1.6.tar.gz#5fe00cda18ca5daeb43762b80c38e06e" --if needs_yaml
install_package "openssl-1.0.1g" "https://www.openssl.org/source/openssl-1.0.1g.tar.gz#de62b43dfcd858e66a74bee1c834e959" mac_openssl --if has_broken_mac_openssl
install_git "ruby-2.1.0-github" "https://github.com/github/ruby.git" "2.1" ldflags_dirs autoconf standard verify_openssl
install_package "yaml-0.1.6" "http://pyyaml.org/download/libyaml/yaml-0.1.6.tar.gz#5fe00cda18ca5daeb43762b80c38e06e" --if needs_yaml
install_package "openssl-1.0.1g" "https://www.openssl.org/source/openssl-1.0.1g.tar.gz#de62b43dfcd858e66a74bee1c834e959" mac_openssl --if has_broken_mac_openssl
install_git "ruby-2.1.0-github" "https://github.com/github/ruby.git" "2.1" ldflags_dirs autoconf standard verify_openssl
Index: hash.c
===================================================================
--- hash.c (revision 44369)
+++ hash.c (revision 44370)
@@ -1169,7 +1169,7 @@
#endif
}
}
-#if HASH_REJECT_COPY_MISC_ATTRIBUTES
+#if HASH_REJECT_COPY_EXTRA_STATES