App | Description | Implementations |
---|---|---|
Dependency solver | https://github.com/erlware/relx/blob/master/src/rlx_depsolver.erl (needs to become separate app) | |
Semver parser | Strict semver 2.0.0 parser | https://github.com/nox/mouture |
Fetcher | Given URI and path, download content at URI to path (support http, git, hg, svn, ...) | |
Naive version parser | Non-semver version parser | |
Unpacker | Open tar, zip, 7z, ... | |
Index | ||
Sign/verify packages | ||
Command line parser |
This file contains 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
{ | |
packageOverrides = pkgs : with pkgs; { | |
erlangHerokuEnv = pkgs.myEnvFun { | |
name = "erlangHeroku"; | |
buildInputs = [ stdenv heroku_crashdumps ]; | |
}; | |
}; | |
} |
This file contains 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
[{application,erlastic_search, | |
"git://github.com/tsloughter/erlastic_search.git",git, | |
[{description,"An Erlang app for communicating with Elastic Search's rest interface."}, | |
{publisher,[]}, | |
{tags,["0.2.0"]}, | |
{branches,["master","helllamer_changes","gh-pages"]}]}]. |
This file contains 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
-- Function: | |
(<=>) :: (Show a) => B.ByteString -> a -> (B.ByteString, B.ByteString) | |
(<=>) x y = (x, showBS y) | |
-- Example usage: | |
infoLog ["handler" <=> "indexHandler", "handler" <=> 1] | |
-- Warnings: | |
src/Site.hs:43:22: Warning: | |
Defaulting the following constraint(s) to type `String' |
This file contains 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
(<=>) :: (Show a) => B.ByteString -> a -> (B.ByteString, B.ByteString) | |
(<=>) x y = (x, showBS y) | |
infoLog :: (MonadSnap m) => [(B.ByteString, B.ByteString)] -> m() | |
infoLog l = logError $ B.append ("[INFO] ") $ | |
B.intercalate " " $ map (\(x,y) -> B.concat [x, "=", y]) l | |
showBS :: (Show a) => a -> B.ByteString | |
showBS = B.pack . show |
This file contains 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
Python: | |
>>> urlsafe_b64encode(hmac.new("secret", "message", sha256).digest()) | |
'i19IcCmVwVmMVz2x4hhmqbgl1KeU0WnXBgoDYFeWNgs=' | |
Haskell: | |
> B64.encode . B.pack . showDigest $ hmacSha256 "secret" "message" | |
"OGI1ZjQ4NzAyOTk1YzE1OThjNTczZGIxZTIxODY2YTliODI1ZDRhNzk0ZDE2OWQ3MDYwYTAzNjA1Nzk2MzYwYg==" |
This file contains 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
encryptedSubscribeSink c i = | |
awaitForever $ (\x -> | |
case decode (L.fromStrict x) of | |
Just (EncryptedSubscribeResponse (resp, _)) -> do | |
_ <- liftIO $ mapM (onMsg subOpts . decodeEncrypted c i) resp | |
return () | |
Nothing -> | |
return ()) | |
subscribeSink = |
This file contains 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
#[no_mangle] | |
extern "C" fn foo(env: *mut ErlNifEnv, argc: i32, argv: *ERL_NIF_TERM) -> ERL_NIF_TERM { | |
print!("Hello Foo from Rust\n"); | |
unsafe { | |
let a = enif_make_atom(env, ("foo".to_c_str()).unwrap()); | |
return a; | |
} | |
} | |
#[no_mangle] |
This file contains 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
#[no_mangle] | |
extern "C" fn foo(env: *mut ErlNifEnv, argc: i32, argv: *ERL_NIF_TERM) -> ERL_NIF_TERM { | |
print!("Hello Foo from Rust\n"); | |
unsafe { | |
let a = enif_make_atom(env, ("foo".to_c_str()).unwrap()); | |
return a; | |
} | |
} | |
#[no_mangle] |
This file contains 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
#!/bin/sh | |
set -e | |
SCRIPT_DIR="$(dirname "$0")" | |
RELEASE_ROOT_DIR="$(cd "$SCRIPT_DIR/.." && pwd)" | |
REL_NAME="recon_demo" | |
REL_VSN="1.0.0" | |
ERTS_VSN="6.0" | |
REL_DIR="$RELEASE_ROOT_DIR/releases/$REL_VSN" |
OlderNewer