Skip to content

Instantly share code, notes, and snippets.

@bus710
bus710 / README.md
Last active March 1, 2024 13:54
Building rust native library to be used by flutter/android

Building rust native library to be used by flutter/android

This short doc shows how to build rust to be used by flutter/android app.
Inspired by hyousef's work but added some details for the workflow.



References

Docs:

@mojavelinux
mojavelinux / build.gradle
Last active March 2, 2017 18:00
A Gradle build that generates a versioned PDF for multiple AsciiDoc documents. Separate tasks are used for illustrative purposes and to allow each conversion to be individually configured.
buildscript {
dependencies {
classpath 'org.asciidoctor:asciidoctorj:1.5.4.1'
}
}
plugins {
id 'org.asciidoctor.convert' version '1.5.3'
id 'com.github.jruby-gradle.base' version '1.3.3'
}
@iamralch
iamralch / sshtunnel.go
Last active April 16, 2023 03:07
SSH tunnelling in Golang
package main
import (
"log"
"bufio"
"time"
"os"
"fmt"
"io"
"net"
@ThisIsMissEm
ThisIsMissEm / handler.js
Created November 25, 2014 18:53
The better way to execute Go on Amazon Lambda (see: http://blog.0x82.com/2014/11/24/aws-lambda-functions-in-go/)
var child_process = require('child_process');
exports.handler = function(event, context) {
var proc = spawn('./test', [ JSON.stringify(event) ], { stdio: 'inherit' });
proc.on('close', function(code){
if(code !== 0) {
return context.done(new Error("Process exited with non-zero status code"));
}
@ceteri
ceteri / clk.tsv
Last active May 14, 2020 13:13
Intro to Apache Spark: code example for (K,V), join, operator graph
2014-03-04 15dfb8e6cc4111e3a5bb600308919594 11
2014-03-06 81da510acc4111e387f3600308919594 61
@tobyhede
tobyhede / postsql.sql
Created May 17, 2012 03:08
PostgreSQL as JSON Document Store
-- PostgreSQL 9.2 beta (for the new JSON datatype)
-- You can actually use an earlier version and a TEXT type too
-- PL/V8 http://code.google.com/p/plv8js/wiki/PLV8
-- Inspired by
-- http://people.planetpostgresql.org/andrew/index.php?/archives/249-Using-PLV8-to-index-JSON.html
-- http://ssql-pgaustin.herokuapp.com/#1
-- JSON Types need to be mapped into corresponding PG types
--
@pledbrook
pledbrook / Config.groovy
Created May 16, 2012 10:17
Loading runtime config from JSON in Grails
// ... rest of Config.groovy content goes above this line to ensure that
// the JSON overrides existing settings.
ConfigLoader.addEntries(loadJson(fetchJson()), this)
def fetchJson() { return System.getenv("GRAILS_APP_CONFIG") }
def loadJson(content) { return content ? grails.converters.JSON.parse(content) : [:] }
@robfletcher
robfletcher / build.gradle
Created May 16, 2012 08:12
Template Gradle build for projects using Groovy with embedded vert.x
apply plugin: 'groovy'
repositories {
mavenCentral()
// vertxHome must be defined in gradle.properties
flatDir { dirs "${vertxHome}/lib/jars" }
}
dependencies {
groovy 'org.codehaus.groovy:groovy:1.8.6'
@premist
premist / stage0-change-mirror-to-korean.sh
Created January 12, 2012 15:50
Installing GitLab on CentOS 6.2 (Part 1)
curl https://raw.github.com/gist/1588091/8b7b7a203074231f3dc75bdee48b3017078fb621/CentOS-Base.repo -o /etc/yum.repos.d/CentOS-Base.repo
curl https://raw.github.com/gist/1588091/2e5ab750cd0603dd7210ea7a999d15f9aadae711/epel.repo -o /etc/yum.repos.d/epel.repo