Skip to content

Instantly share code, notes, and snippets.

View jorbs's full-sized avatar

João Roberto jorbs

  • Maceió - Brazil
  • 23:35 (UTC -03:00)
View GitHub Profile
@jorbs
jorbs / postgres_session_store.ex
Last active September 22, 2021 20:31
Postgres Session Store Plug
defmodule MyAppWeb.Plugs.Session.Postgres do
@behaviour Plug.Session.Store
alias MyApp.Repo
alias MyApp.UserSession
@impl true
def init(opts) do
%{session_max_age: Keyword.fetch!(opts, :session_max_age)}
end
@jorbs
jorbs / Gemfile
Last active January 8, 2021 21:43
Hanami request spec
source 'https://rubygems.org'
ruby "2.6.6"
gem 'rake'
gem 'hanami', '~> 1.3'
gem 'hanami-model', '~> 1.3'
gem 'pg', '~> 1.2'
â xschem git:(master) â ./configure --prefix=/Users/joaoroberto/xschem --debug
make: Nothing to be done for `all'.
Setting prefix to '/Users/joaoroberto/xschem'
--- Detecting host
Looking for a shell... /bin/sh -c
Looking for a shell escape character... found: '\'
Detecting temp dir... validated /Users/joaoroberto/Developer/u/xschem/scconfig/
Checking for system type... OK (name: MacOSX; class: UNIX)
--- Detecting target (same as host)
Checking for cc (target)... OK ('gcc', ' -pipe', '')
joaoroberto:build/ (master) $ cmake .. -DCMAKE_INSTALL_PREFIX=~/nextcloud-desktop-client -DCMAKE_BUILD_TYPE=Debug -DNO_SHIBBOLETH=1 -DOPENSSL_INCLUDE_DIR=/usr/local/Cellar/openssl@1.1/1.1.1b/include -DQt5_DIR=/usr/local/Cellar/qt/5.12.3/lib/cmake/Qt5 -DQt5LinguistTools_DIR=/usr/local/Cellar/qt/5.12.3/lib/cmake/Qt5LinguistTools
-- Build of crashreporter disabled.
-- GIT_SHA1 e1eeaadaff27b1e98e7f0a8e7edd461c67d1b7e8
Compiling without shibboleth
-- Could NOT find Sparkle (missing: SPARKLE_INCLUDE_DIR SPARKLE_LIBRARY)
-- Could NOT find INOTIFY (missing: INOTIFY_INCLUDE_DIR INOTIFY_LIBRARY_DIR)
-- Could NOT find Sphinx (missing: SPHINX_EXECUTABLE)
-- Could NOT find PdfLatex (missing: PDFLATEX_EXECUTABLE)
================> LIBCLOUDPROVIDERS_LIBRARY-NOTFOUND
-- Could NOT find LIBCLOUDPROVIDERS (missing: LIBCLOUDPROVIDERS_INCLUDE_DIR LIBCLOUDPROVIDERS_LIBRARY)
@jorbs
jorbs / gist:415c733a5b59f5c30452815a3290fecc
Created May 29, 2017 16:35
c2go transpile -o build/_free.go build/_free.c | grep "\["
6 . Decls: []ast.Decl (len = 184) {
11 . . . Specs: []ast.Spec (len = 3) {
43 . . . Specs: []ast.Spec (len = 1) {
61 . . . Specs: []ast.Spec (len = 1) {
79 . . . Specs: []ast.Spec (len = 1) {
87 . . . . . . Name: "[]byte"
97 . . . Specs: []ast.Spec (len = 1) {
115 . . . Specs: []ast.Spec (len = 1) {
133 . . . Specs: []ast.Spec (len = 1) {
151 . . . Specs: []ast.Spec (len = 1) {