commit
stringlengths
40
40
old_file
stringlengths
4
264
new_file
stringlengths
4
264
old_contents
stringlengths
0
4.24k
new_contents
stringlengths
1
5.44k
subject
stringlengths
14
778
message
stringlengths
15
9.92k
lang
stringclasses
277 values
license
stringclasses
13 values
repos
stringlengths
5
127k
c7a09f6cb542bed08613378ff35914453921d413
src/xmerlsec_util.erl
src/xmerlsec_util.erl
-module(xmerlsec_util). -export([coerce_c_string/1]). coerce_c_string(S) when is_list(S) -> coerce_c_string(list_to_binary(S)); coerce_c_string(S) -> case binary:last(S) of 0 -> S; _ -> <<S/binary, 0>> end.
-module(xmerlsec_util). -export([coerce_c_string/1]). coerce_c_string(S) when is_atom(S) -> coerce_c_string(atom_to_list(S)); coerce_c_string(S) when is_list(S) -> coerce_c_string(list_to_binary(S)); coerce_c_string(S) -> case binary:last(S) of 0 -> S; _ -> <<S/binary, 0>> end.
Add atoms support to coerce_c_string
Add atoms support to coerce_c_string
Erlang
mit
evax/xmerlsec
76bf135aa723467a605d4be2a8366ff41c85820d
erlang-cowboy/src/eventsource_emitter.erl
erlang-cowboy/src/eventsource_emitter.erl
-module(eventsource_emitter). -behaviour(cowboy_loop_handler). -export([init/3]). -export([info/3]). -export([terminate/3]). -record(state, {}). init({_Any, http}, Req, _Opts) -> timer:send_after(0, {message, [":ok", "\n\n"]}), timer:send_after(40000, shutdown), Headers = [ {<<"content-type">>, <...
-module(eventsource_emitter). -behaviour(cowboy_loop_handler). -export([init/3]). -export([info/3]). -export([terminate/3]). -record(state, {}). init({_Any, http}, Req, _Opts) -> timer:send_after(0, {message, [":ok", "\n\n"]}), Headers = [ {<<"content-type">>, <<"text/event-stream">>}, {<<"ca...
Remove the disonnect after 40 seconds.
Remove the disonnect after 40 seconds.
Erlang
mit
rexxars/sse-broadcast-benchmark,rexxars/sse-broadcast-benchmark,rexxars/sse-broadcast-benchmark,rexxars/sse-broadcast-benchmark,rexxars/sse-broadcast-benchmark,rexxars/sse-broadcast-benchmark,rexxars/sse-broadcast-benchmark,rexxars/sse-broadcast-benchmark
e71d8871b88c26177cbb2bd98ba6a987f5d1d3e8
src/ns_bootstrap.erl
src/ns_bootstrap.erl
%% @author Northscale <info@northscale.com> %% @copyright 2009 NorthScale, Inc. %% %% Licensed under the Apache License, Version 2.0 (the "License"); %% you may not use this file except in compliance with the License. %% You may obtain a copy of the License at %% %% http://www.apache.org/licenses/LICENSE-2.0 %% %%...
%% @author Northscale <info@northscale.com> %% @copyright 2009 NorthScale, Inc. %% %% Licensed under the Apache License, Version 2.0 (the "License"); %% you may not use this file except in compliance with the License. %% You may obtain a copy of the License at %% %% http://www.apache.org/licenses/LICENSE-2.0 %% %%...
Set disksup check interval to 1 minute.
Set disksup check interval to 1 minute. This made the "line of death," not to mention free space, only update once every 30 minutes, since that's the default check interval. Change-Id: I15cd757b2cf5743bb830481ff6c8308b96769338 Reviewed-on: http://review.membase.org/4120 Tested-by: Steve Yen <ef850f73f7832052d3c6d9b5d...
Erlang
apache-2.0
vzasade/ns_server,ceejatec/ns_server,nimishzynga/ns_server,t3rm1n4l/ns_server,pavel-blagodov/ns_server,nimishzynga/ns_server,membase/ns_server,membase/ns_server,mschoch/ns_server,nimishzynga/ns_server,membase/ns_server,t3rm1n4l/ns_server,mschoch/ns_server,ceejatec/ns_server,t3rm1n4l/ns_server,t3rm1n4l/ns_server,membase...
816723e4f32f50d25e0f7fa79cd95e0a3065b03e
src/lasp_storage_backend.erl
src/lasp_storage_backend.erl
%% ------------------------------------------------------------------- %% %% Copyright (c) 2014 SyncFree Consortium. All Rights Reserved. %% %% This file is provided to you under the Apache License, %% Version 2.0 (the "License"); you may not use this file %% except in compliance with the License. You may obtain %% a...
%% ------------------------------------------------------------------- %% %% Copyright (c) 2014 SyncFree Consortium. All Rights Reserved. %% %% This file is provided to you under the Apache License, %% Version 2.0 (the "License"); you may not use this file %% except in compliance with the License. You may obtain %% a...
Add update_all/2 to callback module.
Add update_all/2 to callback module.
Erlang
apache-2.0
ergl/lasp,lasp-lang/lasp,lasp-lang/lasp,lasp-lang/lasp,ergl/lasp,lasp-lang/lasp,ergl/lasp,ergl/lasp
f2edaf378bcde0b12faf19d435411d18f7057f5c
include/saturn_leaf.hrl
include/saturn_leaf.hrl
-define(PRINT(Var), io:format("DEBUG: ~p:~p - ~p~n~n ~p~n~n", [?MODULE, ?LINE, ??Var, Var])). -define(BUCKET, <<"saturn_leaf">>). -define(PROXY_MASTER, saturn_proxy_vnode_master). -define(PROXY_SERVICE, saturn_proxy). -define(SIMPLE_MASTER, saturn_simple_backend_vnode_master). -define(SIMPLE_SERVICE, saturn_simple_ba...
-define(PRINT(Var), io:format("DEBUG: ~p:~p - ~p~n~n ~p~n~n", [?MODULE, ?LINE, ??Var, Var])). -define(BUCKET, <<"saturn_leaf">>). -define(PROXY_MASTER, saturn_proxy_vnode_master). -define(PROXY_SERVICE, saturn_proxy). -define(SIMPLE_MASTER, saturn_simple_backend_vnode_master). -define(SIMPLE_SERVICE, saturn_simple_ba...
Change conector to not be FSM
Change conector to not be FSM
Erlang
apache-2.0
angbrav/saturn_leaf
4de01ea73ec8db0767299953539e7ec0362df2ee
include/pvc.hrl
include/pvc.hrl
%% Rubis -define(GROUPING_SEP, <<"+">>). -define(ID_SEP, <<"@">>). -define(FIELD_SEP, <<"/">>). %% General indices -define(INDEX_SEP, <<"$">>). -define(UINDEX_SEP, <<"%">>). -define(INDEX_PAGE_LIMIT, 25). %% Size of active listener pool for the protocol buffer server -define(COORD_PB_POOL, (1 * erlang:system_info(sch...
%% Rubis -define(GROUPING_SEP, <<"+">>). -define(ID_SEP, <<"@">>). -define(FIELD_SEP, <<"/">>). %% General indices -define(INDEX_SEP, <<"$">>). -define(UINDEX_SEP, <<"%">>). -define(INDEX_PAGE_LIMIT, 25). %% Size of active listener pool for the protocol buffer server -define(COORD_PB_POOL, (1 * erlang:system_info(sch...
Decrease dequeue event interval to 1ms.
Decrease dequeue event interval to 1ms. Benchmarks show that the increase in load due to this is not significant, so might as well.
Erlang
apache-2.0
ergl/antidote
28f856717997a79388b55c3743be11bf1934acdf
apps/nitrogen/src/handlers/process_registry/nprocreg_registry_handler.erl
apps/nitrogen/src/handlers/process_registry/nprocreg_registry_handler.erl
% Nitrogen Web Framework for Erlang % Copyright (c) 2008-2010 Rusty Klophaus % See MIT-LICENSE for licensing information. -module (nprocreg_registry_handler). -behaviour (process_registry_handler). -include_lib ("wf.hrl"). -export ([ init/2, finish/2, get_pid/3, get_pid/4 ]). init(_Config, State) -> ...
% Nitrogen Web Framework for Erlang % Copyright (c) 2008-2010 Rusty Klophaus % See MIT-LICENSE for licensing information. -module (nprocreg_registry_handler). -behaviour (process_registry_handler). -include_lib ("wf.hrl"). -export ([ init/2, finish/2, get_pid/3, get_pid/4 ]). init(_Config, State) -> ...
Fix a typo in nprocreg process registry handler
Fix a typo in nprocreg process registry handler
Erlang
mit
stuart-thackray/nitrogen,joaohf/nitrogen,nitrogen/nitrogen,kevinmontuori/nitrogen,stuart-thackray/nitrogen,joaohf/nitrogen,choptastic/nitrogen,choptastic/nitrogen,stuart-thackray/nitrogen,kevinmontuori/nitrogen,joaohf/nitrogen,nitrogen/nitrogen,choptastic/nitrogen,kevinmontuori/nitrogen,nitrogen/nitrogen
f796d0fbf08dbfcc16b4c45777a38dd874702b26
elli/src/elli_bench_sup.erl
elli/src/elli_bench_sup.erl
-module(elli_bench_sup). -behaviour(supervisor). %% API -export([start_link/0]). %% Supervisor callbacks -export([init/1]). %% Helper macro for declaring children of supervisor -define(CHILD(I, Type), {I, {I, start_link, []}, permanent, 5000, Type, [I]}). %% =======================================================...
-module(elli_bench_sup). -behaviour(supervisor). %% API -export([start_link/0]). %% Supervisor callbacks -export([init/1]). %% Helper macro for declaring children of supervisor -define(CHILD(I, Type), {I, {I, start_link, []}, permanent, 5000, Type, [I]}). %% ========================================================...
Update client connection pool to mirror benchmark's MySQL pool limit of 5k
Update client connection pool to mirror benchmark's MySQL pool limit of 5k Erlang is highly concurrent, so under load, especially to a remote system it is quite conceivable to utilize very high numbers of connections if available.
Erlang
bsd-3-clause
sxend/FrameworkBenchmarks,denkab/FrameworkBenchmarks,jeevatkm/FrameworkBenchmarks,F3Community/FrameworkBenchmarks,jamming/FrameworkBenchmarks,greenlaw110/FrameworkBenchmarks,yunspace/FrameworkBenchmarks,sanjoydesk/FrameworkBenchmarks,stefanocasazza/FrameworkBenchmarks,seem-sky/FrameworkBenchmarks,victorbriz/FrameworkBe...
36924cd5fc958ccf266ccfe1388cb5f0fa877bcf
src/beamjs_mod_repl.erl
src/beamjs_mod_repl.erl
-module(beamjs_mod_repl). -export([exports/1,init/1]). -behaviour(erlv8_module). -include_lib("erlv8/include/erlv8.hrl"). init(_VM) -> ok. exports(_VM) -> erlv8_object:new([{"start", fun start/2}]). start(#erlv8_fun_invocation{} = Invocation, []) -> start(Invocation,["beam.js> "]); start(#erlv8_fun_invocation{ vm...
-module(beamjs_mod_repl). -export([exports/1,init/1]). -behaviour(erlv8_module). -include_lib("erlv8/include/erlv8.hrl"). init(_VM) -> ok. exports(_VM) -> erlv8_object:new([{"start", fun start/2}]). start(#erlv8_fun_invocation{} = Invocation, []) -> case node() of nonode@nohost -> start(Invocation,["beam.js>...
Make REPL show node name in the prompt if it is a distributed node.
Make REPL show node name in the prompt if it is a distributed node.
Erlang
bsd-2-clause
beamjs/beamjs,beamjs/beamjs
894a7b203485f06cdd85a8977097dc2ed4fe7e56
src/er_crawler.erl
src/er_crawler.erl
-module(er_crawler). -behaviour(gen_server). -export([start_link/1]). -export([init/1, handle_call/3, handle_cast/2, handle_info/2, code_change/3, terminate/2]). -record(state, {feed}). start_link(Feed) -> gen_server:start_link(?MODULE, [Feed], []). init([Feed]) -> io:format("~p starting~n", [?MODULE]), ...
-module(er_crawler). -behaviour(gen_server). -export([start_link/1]). -export([init/1, handle_call/3, handle_cast/2, handle_info/2, code_change/3, terminate/2]). -include("erl_reader.hrl"). -record(state, {feed}). start_link(Feed) -> gen_server:start_link(?MODULE, [Feed], []). init([Feed]) -> io:format("~...
Check for updates in crawler
Check for updates in crawler
Erlang
unlicense
grahamrhay/erl_reader
e92385038957dcda1429ee4fd93e921f3eb30f81
examples/eventsource/src/eventsource_handler.erl
examples/eventsource/src/eventsource_handler.erl
%% Feel free to use, reuse and abuse the code in this file. %% @doc EventSource emitter. -module(eventsource_handler). -export([init/2]). -export([info/3]). init(Req, Opts) -> Headers = [{<<"content-type">>, <<"text/event-stream">>}], Req2 = cowboy_req:chunked_reply(200, Headers, Req), erlang:send_after(1000, sel...
%% Feel free to use, reuse and abuse the code in this file. %% @doc EventSource emitter. -module(eventsource_handler). -export([init/2]). -export([info/3]). init(Req, Opts) -> Headers = [{<<"content-type">>, <<"text/event-stream">>}], Req2 = cowboy_req:chunked_reply(200, Headers, Req), erlang:send_after(1000, sel...
Use the new unique_integer function to generate IDs
Use the new unique_integer function to generate IDs In the eventsource example.
Erlang
isc
hairyhum/cowboy,noname007/cowboy,acrispin/cowboy,dangjun625/cowboy,276361270/cowboy,Reimerei/cowboy,bsmr-erlang/cowboy,odo/cowboy,imdeps/cowboy,yangchengjian/cowboy,yangchengjian/cowboy,ninenines/cowboy,nviennot/cowboy,binarin/cowboy,rabbitmq/cowboy,omusico/cowboy,bobos/ecweb,K2InformaticsGmbH/cowboy,binarin/cowboy,pap...
2c850eed152848babfcf10796b70edcb73527b2b
test/spec/wsecli_handshake_spec.erl
test/spec/wsecli_handshake_spec.erl
-module(wsecli_handshake). -include_lib("espec/include/espec.hrl"). -include_lib("hamcrest/include/hamcrest.hrl"). -include("wsecli.hrl"). spec() -> describe("wsecli_handshake", fun() -> it("should return a valid handshake request", fun() -> Resource = "/", Host = "localhost...
-module(wsecli_handshake_spec). -include_lib("espec/include/espec.hrl"). -include_lib("hamcrest/include/hamcrest.hrl"). -include("wsecli.hrl"). spec() -> describe("wsecli_handshake", fun() -> it("should return a valid handshake request", fun() -> Resource = "/", Host = "loca...
Rename spec module or shit happens
Rename spec module or shit happens
Erlang
apache-2.0
madtrick/wsecli
6fc424ad4691739113240fee6c72ecf1d25dbf60
src/utils/mas_agent_env.erl
src/utils/mas_agent_env.erl
%% @doc The module contains the definition of agent environment operator callbacks to be implemented. -module (mas_agent_env). -include ("mas.hrl"). -type agent() :: mas:agent(). -type sim_params() :: mas:sim_params(). -type agent_behaviour() :: mas:agent_behaviour(). -callback start(model(), pos_integer()) -> ok. ...
%% @doc The module contains the definition of agent environment operator callbacks to be implemented. -module (mas_agent_env). -include ("mas.hrl"). -type agent() :: mas:agent(). -type sim_params() :: mas:sim_params(). -type agent_behaviour() :: mas:agent_behaviour(). -callback start(model(), pos_integer()) -> agen...
Fix dialyzer errors coming from emas usecase
Fix dialyzer errors coming from emas usecase
Erlang
mit
ParaPhraseAGH/erlang-mas
f7c8076812384b48624c9197a34f4600bfd5cb09
src/workorder_root_handler.erl
src/workorder_root_handler.erl
-module(workorder_root_handler).
-module(workorder_root_handler). -export([init/3]). -export([content_types_provided/2]). -export([work_order_collection_to_json/2]). init(_Transport, _Req, []) -> {upgrade, protocol, cowboy_rest}. content_types_provided(Req, State) -> {[ {<<"application/json">>, work_order_collection_to_json} ], Req, State...
Implement empty work order collection
Implement empty work order collection
Erlang
mit
camshaft/work-order-server
e7ab0b6a8b61aa5a09fdcd78ce0a39ac7abab494
src/pgsql_listen_sup.erl
src/pgsql_listen_sup.erl
-module(pgsql_listen_sup). -behaviour(mirrored_supervisor). -define(WORKER, pgsql_listen_worker). -rabbit_boot_step({pgsql_listen_supervisor, [{description, "PgSQL Listen Supervisor"}, {mfa, {rabbit_sup, start_child, [?MODULE]}}, {requires, kernel...
%%============================================================================== %% @author Gavin M. Roy <gavinr@aweber.com> %% @copyright 2014 AWeber Communications %% @end %%============================================================================== %% @doc Supervisor for the PgSQL LISTEN Exchange worker %% @end ...
Add comments, reorder functions, consolidate exports
Add comments, reorder functions, consolidate exports
Erlang
bsd-3-clause
3manuek/pgsql-listen-exchange
1f56850c2b29d10a9749f7b178c798d451137ee2
include/machi_merkle_tree.hrl
include/machi_merkle_tree.hrl
%% machi merkle tree records -record(naive, { chunk_size = 1048576 :: pos_integer(), %% default 1 MB recalc = true :: boolean(), root :: 'undefined' | binary(), lvl1 = [] :: [ binary() ], lvl2 = [] :: [ binary() ],...
%% machi merkle tree records -record(naive, { chunk_size = 1048576 :: pos_integer(), %% default 1 MB recalc = true :: boolean(), root :: 'undefined' | binary(), lvl1 = [] :: [ binary() ], lvl2 = [] :: [ binary() ],...
Remove merklet from header file too.
Remove merklet from header file too.
Erlang
apache-2.0
basho/machi,basho/machi,basho/machi
63dbb4ab469f77c84c280496f4db69267080a944
src/crypto2.erl
src/crypto2.erl
%%% Add erlang apache license here as a lot of this code %%% is copy pasta -module('crypto2'). -on_load(on_load/0). %% API exports -export([ sha256_init/0, hash_update/2, hash_final/1 ]). %%==================================================================== %% API functions %%====...
%%% Add erlang apache license here as a lot of this code %%% is copy pasta -module('crypto2'). -on_load(on_load/0). %% API exports -export([ hash_init/1, hash_update/2, hash_final/1 ]). %%==================================================================== %% API functions %%======...
Add hash_init. Only sha256 implementation
Add hash_init. Only sha256 implementation
Erlang
bsd-3-clause
jaym/erlang-crypto2
b6d203d17e9cf708f5de5005a98afdbe1f35dcd4
src/handlers/config/default_config_handler.erl
src/handlers/config/default_config_handler.erl
% vim: sw=4 ts=4 et ft=erlang % Nitrogen Web Framework for Erlang % Copyright (c) 2008-2010 Rusty Klophaus % See MIT-LICENSE for licensing information. -module (default_config_handler). -include("wf.hrl"). -behaviour (config_handler). -export ([ init/2, finish/2, get_value/4, get_values/4 ]). init(_...
% vim: sw=4 ts=4 et ft=erlang % Nitrogen Web Framework for Erlang % Copyright (c) 2008-2010 Rusty Klophaus % See MIT-LICENSE for licensing information. -module (default_config_handler). -include("wf.hrl"). -behaviour (config_handler). -export ([ init/2, finish/2, get_value/4, get_values/4 ]). init(_...
Update config handler to also use nitrogen_core
Update config handler to also use nitrogen_core Fixes https://github.com/nitrogen/nitrogen/issues/98
Erlang
mit
nitrogen/nitrogen_core,choptastic/nitrogen_core,nitrogen/nitrogen_core,choptastic/nitrogen_core,nitrogen/nitrogen_core,nitrogen/nitrogen_core,choptastic/nitrogen_core
ce6a1d0061f226d67b436859bf05a32bd8f3e837
src/beamup_project.erl
src/beamup_project.erl
-module(beamup_project). -export([new/1]). new(Path) -> #{path => Path, name => path_to_name(Path), commit => beamup_git:commit_hash(Path), tool => beamup_build_tool:detect(Path), branch => beamup_git:branch(Path)}. path_to_name(Path) -> lists:last(string:tokens(Path,"/")).
-module(beamup_project). -export([new/1]). new(Path) -> #{path => Path, name => name_from_path(Path), architecture => architecture(), branch => beamup_git:branch(Path), version => beamup_git:commit_hash(Path), tool => beamup_build_tool:detect(Path)}. name_from_path(Path) -> lists:last(string:...
Add notion of architecture to project metadata
Add notion of architecture to project metadata
Erlang
mit
beamup-io/cli
720139f2d285a5746ba712efa236ad4938436e0f
lib/hipe/test/bs_SUITE_data/bs_add.erl
lib/hipe/test/bs_SUITE_data/bs_add.erl
%% -*- erlang-indent-level: 2 -*- %%------------------------------------------------------------------------- %% The guard in f/3 revealed a problem in the translation of the 'bs_add' %% BEAM instruction to Icode. The fail label was not properly translated. %% Fixed 3/2/2011. %%-----------------------------------------...
%% -*- erlang-indent-level: 2 -*- %%------------------------------------------------------------------------- %% The guard in f/3 revealed a problem in the translation of the 'bs_add' %% BEAM instruction to Icode. The fail label was not properly translated. %% Fixed 3/2/2011. Then in 2015 we found another issue: g/2. ...
Add a case testing the handling of guards involving binaries
Add a case testing the handling of guards involving binaries The HiPE compiler was leaking exceptions out of guards involving binaries with `strange' arithmetic in them. Fixed by the set of changes in this pull request.
Erlang
apache-2.0
mikpe/otp,cobusc/otp,rlipscombe/otp,massemanet/otp,mikpe/otp,fenollp/otp,getong/otp,dumbbell/otp,basho/otp,matwey/otp,basho/otp,bugs-erlang-org/otp,isvilen/otp,vinoski/otp,aboroska/otp,aboroska/otp,jj1bdx/otp,vinoski/otp,uabboli/otp,erlang/otp,rlipscombe/otp,tuncer/otp,kvakvs/otp,potatosalad/otp,psyeugenic/otp,saleyn/o...
0b811dfd4e6f7468f745e9bad1f44afbeb2ebb90
src/sys/fsevents.erl
src/sys/fsevents.erl
-module(fsevents). -include("api.hrl"). -export(?API). find_executable() -> fs:find_executable("mac_listener", "deps/fs/priv/mac_listener"). known_events() -> [mustscansubdirs,userdropped,kerneldropped,eventidswrapped,historydone,rootchanged, mount,unmount,created,removed,inodemetamod,renamed,modified...
-module(fsevents). -include("api.hrl"). -export(?API). find_executable() -> case application:get_env(fs, project_dir) of {ok, P} -> fs:find_executable("mac_listener", lists:append([P, "deps/fs/priv/mac_listener"])); undefined -> fs:find_executable("mac_listener", "deps/fs/priv/mac_listener") end. ...
Use :fs, :project_dir to set absolute path to mac_listener (useful when launching app from escript)
Use :fs, :project_dir to set absolute path to mac_listener (useful when launching app from escript)
Erlang
isc
VerKnowSys/fs,VerKnowSys/fs,VerKnowSys/fs
197ffa296bf14bb3c148c35cc23ede43c73e24ae
lib/kernel/include/inet.hrl
lib/kernel/include/inet.hrl
%% %% %CopyrightBegin% %% %% Copyright Ericsson AB 1997-2017. All Rights Reserved. %% %% Licensed under the Apache License, Version 2.0 (the "License"); %% you may not use this file except in compliance with the License. %% You may obtain a copy of the License at %% %% http://www.apache.org/licenses/LICENSE-2.0 %...
%% %% %CopyrightBegin% %% %% Copyright Ericsson AB 1997-2017. All Rights Reserved. %% %% Licensed under the Apache License, Version 2.0 (the "License"); %% you may not use this file except in compliance with the License. %% You may obtain a copy of the License at %% %% http://www.apache.org/licenses/LICENSE-2.0 %...
Revert "Correct hostent_addr h_addrtype typespec"
Revert "Correct hostent_addr h_addrtype typespec" This reverts commit dd3a6644de8189ccedfa5ac55ad9cd2b26fc1951.
Erlang
apache-2.0
potatosalad/otp,mikpe/otp,jj1bdx/otp,jj1bdx/otp,rlipscombe/otp,dgud/otp,mikpe/otp,rlipscombe/otp,potatosalad/otp,mikpe/otp,rlipscombe/otp,emacsmirror/erlang,isvilen/otp,vinoski/otp,emacsmirror/erlang,mikpe/otp,vinoski/otp,potatosalad/otp,rlipscombe/otp,erlang/otp,dgud/otp,dgud/otp,dgud/otp,bjorng/otp,vinoski/otp,bjorng...
431794269187681a52a744eceeb75ff2f3e8b792
itests/test/test_utils.erl
itests/test/test_utils.erl
-module(test_utils). -export([test_cleanup/1, nuke_nodes_from_solr/0]). -include_lib("emysql/include/emysql.hrl"). %% @doc graceful shutdown of apps started by tests %% %% This seems to get rid of the following error reports otherwise seen at the end of a test run: %% %% =ERROR REPORT==== 21-Sep-2011::09:...
-module(test_utils). -export([test_cleanup/1, nuke_nodes_from_solr/0]). -include_lib("emysql/include/emysql.hrl"). %% @doc graceful shutdown of apps started by tests %% %% This seems to get rid of the following error reports otherwise seen at the end of a test run: %% %% =ERROR REPORT==== 21-Sep-2011::09:...
Add ibrowse clean shutdown for integration test
Add ibrowse clean shutdown for integration test
Erlang
apache-2.0
rmoorman/chef-server,vladuemilian/chef-server,Minerapp/chef-server,charlesjohnson/chef-server,poliva83/chef-server,chef/chef-server,rmoorman/chef-server,stephenbm/chef-server,juliandunn/chef-server-1,stephenbm/chef-server,marcparadise/chef-server,chef/chef-server,juliandunn/chef-server-1,chef/chef-server,poliva83/chef-...
94babcb98d77d3730c5c8569c791296e3e6c6106
mod_beeldenzoeker.erl
mod_beeldenzoeker.erl
-module(mod_beeldenzoeker). -author("Driebit <tech@driebit.nl>"). -mod_title("Beeldenzoeker"). -mod_description("Media collections powered by Elasticsearch"). -mod_prio(200). -mod_depends([mod_ginger_base]). -mod_schema(4). -include_lib("zotonic.hrl"). -include_lib("mod_elasticsearch/include/elasticsearch.hrl"). -ex...
-module(mod_beeldenzoeker). -author("Driebit <tech@driebit.nl>"). -mod_title("Beeldenzoeker"). -mod_description("Media collections powered by Elasticsearch"). -mod_prio(200). -mod_depends([mod_ginger_base]). -mod_schema(4). -include_lib("zotonic.hrl"). -include_lib("mod_elasticsearch/include/elasticsearch.hrl"). -ex...
Make sure beeldenzoeker_query is findable
[collection] Make sure beeldenzoeker_query is findable
Erlang
apache-2.0
driebit/ginger,driebit/ginger,driebit/ginger
73f1bae08eb10fb3f4653d55f8eccdfbd92b8f9c
modules/mod_ginger_base/support/ginger_geo_search.erl
modules/mod_ginger_base/support/ginger_geo_search.erl
-module(ginger_geo_search). -export([search_query/2]). -include_lib("zotonic.hrl"). %% @doc Supports all the usual query model arguments %% Selects and filters locations data. search_query(#search_query{search={ginger_geo, Args}}, Context) -> GingerArgs = ginger_search:merge_ginger_args(Args, Context), ...
-module(ginger_geo_search). -export([search_query/2]). -include_lib("zotonic.hrl"). %% @doc Supports all the usual query model arguments %% Selects and filters locations data. search_query(#search_query{search={ginger_geo, Args}}, Context) -> BaseSearch = ginger_search:search_query(#search_query{search={ginger_...
Make ginger_geo work with filters option
[base] Make ginger_geo work with filters option
Erlang
apache-2.0
driebit/ginger,driebit/ginger,driebit/ginger
21dd1938ea3365dbce81f363678e27fa2ae35828
src/config_app.erl
src/config_app.erl
% Licensed under the Apache License, Version 2.0 (the "License"); you may not % use this file except in compliance with the License. You may obtain a copy of % the License at % % http://www.apache.org/licenses/LICENSE-2.0 % % Unless required by applicable law or agreed to in writing, software % distributed under the ...
% Licensed under the Apache License, Version 2.0 (the "License"); you may not % use this file except in compliance with the License. You may obtain a copy of % the License at % % http://www.apache.org/licenses/LICENSE-2.0 % % Unless required by applicable law or agreed to in writing, software % distributed under the ...
Check that default config files exist
Check that default config files exist Avoid trying to load the default config files if they don't exist.
Erlang
apache-2.0
fkaempfer/couchdb,fkaempfer/couchdb,fkaempfer/couchdb,fkaempfer/couchdb,fkaempfer/couchdb,fkaempfer/couchdb
f655447c3d35c9cc3e4eaf9863a5a11accf21913
include/jsonld.hrl
include/jsonld.hrl
%% %% %% -record(triple, { type, subject, object, property }).
%% %% %% -record(triple, { type :: resource | literal, subject :: binary(), object :: binary(), property :: binary() }).
Add some documentation on the fields.
Add some documentation on the fields.
Erlang
mit
nrdufour/erlang-json-ld
933d6e20318f53367ff8da7a0f15302796307a2f
include/oauth1_parameter_names.hrl
include/oauth1_parameter_names.hrl
-define(PARAM_CALLBACK , <<"oauth_callback">>). -define(PARAM_CONSUMER_KEY , <<"oauth_consumer_key">>). -define(PARAM_NONCE , <<"oauth_nonce">>). -define(PARAM_REALM , <<"realm">>). -define(PARAM_SIGNATURE , <<"oauth_signature">>). -define(PARAM_SIGNATURE_METHOD , <<"oauth_signa...
-define(PARAM_CALLBACK , <<"oauth_callback">>). -define(PARAM_CONSUMER_KEY , <<"oauth_consumer_key">>). -define(PARAM_NONCE , <<"oauth_nonce">>). -define(PARAM_REALM , <<"realm">>). -define(PARAM_SIGNATURE , <<"oauth_signature">>). -define(PARAM_SIGNATURE_METHOD , <<"oauth_signa...
Define name macro for parameter: "oauth_token_secret".
Define name macro for parameter: "oauth_token_secret".
Erlang
mit
ibnfirnas/oauth1_core
922cfd4f8ceaf1087faa3d7d0d0408a5775505f9
include/pvc.hrl
include/pvc.hrl
%% Rubis -define(GROUPING_SEP, <<"+">>). -define(ID_SEP, <<"@">>). -define(FIELD_SEP, <<"/">>). %% General indices -define(INDEX_SEP, <<"$">>). -define(UINDEX_SEP, <<"%">>). -define(INDEX_PAGE_LIMIT, 25). %% Amount of Transaction metadata kept for the Version and Commit log %% %% VERSION_THRESHOLD specifies the point...
%% Rubis -define(GROUPING_SEP, <<"+">>). -define(ID_SEP, <<"@">>). -define(FIELD_SEP, <<"/">>). %% General indices -define(INDEX_SEP, <<"$">>). -define(UINDEX_SEP, <<"%">>). -define(INDEX_PAGE_LIMIT, 25). %% Amount of Transaction metadata kept for the Version and Commit log %% %% VERSION_THRESHOLD specifies the point...
Purge version/commit logs more often
Purge version/commit logs more often
Erlang
apache-2.0
ergl/antidote
db52193b5589d05d3c15c047c5b6fe39220dfdf0
deps/emoxi/src/mc_info.erl
deps/emoxi/src/mc_info.erl
% Copyright (c) 2010, NorthScale, Inc. % All rights reserved. -module(mc_info). -include_lib("eunit/include/eunit.hrl"). -include("mc_constants.hrl"). -include("mc_entry.hrl"). %% API -export([version/0]). version() -> VA = case catch(ns_info:version()) of X when is_list(X) -> X; _ ...
% Copyright (c) 2010, NorthScale, Inc. % All rights reserved. -module(mc_info). -include_lib("eunit/include/eunit.hrl"). -include("mc_constants.hrl"). -include("mc_entry.hrl"). %% API -export([version/0]). version() -> VA = case catch(ns_info:version()) of X when is_list(X) -> X; _ ...
Make emoxi report the product version proper.
Make emoxi report the product version proper.
Erlang
apache-2.0
ingenthr/ns_server,ceejatec/ns_server,pavel-blagodov/ns_server,daverigby/ns_server,ceejatec/ns_server,mschoch/ns_server,membase/ns_server,membase/ns_server,daverigby/ns_server,nimishzynga/ns_server,ceejatec/ns_server,t3rm1n4l/ns_server,vzasade/ns_server,membase/ns_server,mschoch/ns_server,nimishzynga/ns_server,mschoch/...
bdd6a17ead82a39edd405c31bc5a94a7d87f9754
include/rebar.hrl
include/rebar.hrl
-record(config, { dir, opts }). -record(global_state, { working_dir }). -define(FAIL, throw({error, failed})). -define(ABORT(Str, Args), ?ERROR(Str, Args), halt(1)). -define(CONSOLE(Str, Args), io:format(Str, Args)). -define(DEBUG(Str, Args), rebar_log:log(debug, Str, Args)). -define(INFO(Str, Ar...
-record(config, { dir, opts }). -record(global_state, { working_dir }). -define(FAIL, throw({error, failed})). -define(ABORT(Str, Args), ?ERROR(Str, Args), init:stop(1)). -define(CONSOLE(Str, Args), io:format(Str, Args)). -define(DEBUG(Str, Args), rebar_log:log(debug, Str, Args)). -define(INFO(St...
Use init:stop/1 over halt/1 to ensure all I/O gets a chance to flush
Use init:stop/1 over halt/1 to ensure all I/O gets a chance to flush
Erlang
apache-2.0
mbbx6spp/rebar
24159cc65766b58e76f374f6a05555c0f3a7eb85
src/teles_data_manager_sup.erl
src/teles_data_manager_sup.erl
-module(teles_data_manager_sup). -behaviour(supervisor). -export([start_link/1, init/1, start_agents/2]). start_link(NumAgents) -> supervisor:start_link({local, ?MODULE}, ?MODULE, [NumAgents]). init([NumAgents]) -> Manager = {data_manager, {teles_data_manager, start_link, [NumAgents]}, permanent, ...
-module(teles_data_manager_sup). -behaviour(supervisor). -export([start_link/1, init/1, start_agents/2]). start_link(NumAgents) -> supervisor:start_link({local, ?MODULE}, ?MODULE, [NumAgents]). init([NumAgents]) -> Manager = {data_manager, {teles_data_manager, start_link, [NumAgents]}, permanent, ...
Change how data agents are started
Change how data agents are started
Erlang
bsd-3-clause
armon/teles,armon/teles
e9492713016dba6edc2bc3f36ca5a9d03ae600d5
src/auth/dbus_auth_external.erl
src/auth/dbus_auth_external.erl
%%% @author Jean Parpaillon <jean.parpaillon@free.fr> %%% @copyright (C) 2014, Jean Parpaillon %%% @doc %%% %%% @end %%% Created : 5 Jul 2014 by Jean Parpaillon <jean.parpaillon@free.fr> -module(dbus_auth_external). -compile([{parse_transform, lager_transform}]). -behaviour(dbus_auth). % dbus_auth callbacks -export(...
%%% @author Jean Parpaillon <jean.parpaillon@free.fr> %%% @copyright (C) 2014, Jean Parpaillon %%% @doc %%% %%% @end %%% Created : 5 Jul 2014 by Jean Parpaillon <jean.parpaillon@free.fr> -module(dbus_auth_external). -compile([{parse_transform, lager_transform}]). -behaviour(dbus_auth). % dbus_auth callbacks -export(...
Allow to set external authentication cookie from application env
Allow to set external authentication cookie from application env
Erlang
apache-2.0
lizenn/erlang-dbus,lizenn/erlang-dbus
042a4cca6bb7c9b1afdc13ff1f966620f9039ff9
src/mumq_tcpd.erl
src/mumq_tcpd.erl
-module(mumq_tcpd). -behaviour(gen_tcpd). -export([start_link/0, init/1, handle_connection/2, handle_info/2, terminate/2]). start_link() -> % TODO: Add tcp options nodelay and keepalive gen_tcpd:start_link({local, ?MODULE}, ?MODULE, [], tcp, 61613, ...
-module(mumq_tcpd). -behaviour(gen_tcpd). -export([start_link/0, init/1, handle_connection/2, handle_info/2, terminate/2]). start_link() -> gen_tcpd:start_link({local, ?MODULE}, ?MODULE, [], tcp, 61613, [{socket_options, [{reuseaddr, true}, ...
Set the TCP socket options
Set the TCP socket options
Erlang
mit
jimenezrick/mumq
196dd0c2c152eb4ec25b0a2329b2a660c49c5e74
src/utils/mas.erl
src/utils/mas.erl
%% @doc This module starts the mas framework with given environment, %% time and parameters -module (mas). -export ([start/4]). -export_type([agent/0, agent/1, sim_params/0, sim_params/1, agent_behaviour/0, agent_behaviour/1]). -include ("mas.hrl")...
%% @doc This module starts the mas framework with given environment, %% time and parameters -module (mas). -export ([start/3]). -export_type([agent/0, agent/1, sim_params/0, sim_params/1, agent_behaviour/0, agent_behaviour/1]). -include ("mas.hrl")...
Move `agent_env` from argument to options.
Move `agent_env` from argument to options.
Erlang
mit
ParaPhraseAGH/erlang-mas
e8a175ae45ac77107e931aae2f4080cc0eddcd5a
src/re2.erl
src/re2.erl
%% Copyright 2010-2011 Tuncer Ayaz. All Rights Reserved. %% Use of this source code is governed by a BSD-style %% license that can be found in the LICENSE file. -module(re2). -author(tuncerayaz). -export([compile/1, compile/2, match/2, match/3, replace/3, replace/4]). -on...
%% Copyright 2010-2011 Tuncer Ayaz. All Rights Reserved. %% Use of this source code is governed by a BSD-style %% license that can be found in the LICENSE file. -module(re2). -author(tuncerayaz). -export([compile/1, compile/2, match/2, match/3, replace/3, replace/4]). -on...
Use correct code:priv_dir/1 error code
Use correct code:priv_dir/1 error code
Erlang
bsd-3-clause
tuncer/re2,tuncer/re2
14bc5f93462bc6e3d82f77e232657ee652d9f0c5
src/mover_phase_2_migration_callback.erl
src/mover_phase_2_migration_callback.erl
-module(mover_phase_2_migration_callback). -export([ migration_start_worker_args/2, migration_action/2, migration_type/0, supervisor/0, error_halts_migration/0, reconfigure_object/2 ]). -include("mover.hrl"). -include_lib("moser/include/moser.hrl"). migr...
-module(mover_phase_2_migration_callback). -export([ migration_start_worker_args/2, migration_action/2, migration_type/0, supervisor/0, error_halts_migration/0, reconfigure_object/2 ]). -include("mover.hrl"). -include_lib("moser/include/moser.hrl"). migr...
Remove [{ok, done}] so we catch crash on moser_utils:load_process_org.
Remove [{ok, done}] so we catch crash on moser_utils:load_process_org.
Erlang
apache-2.0
poliva83/chef-server,rmoorman/chef-server,itmustbejj/chef-server,marcparadise/chef-server,chef/chef-server,poliva83/chef-server,stephenbm/chef-server,juliandunn/chef-server-1,marcparadise/chef-server,Minerapp/chef-server,marcparadise/chef-server,chef/chef-server,chef/chef-server,poliva83/chef-server,marcparadise/chef-s...
42d97e992dc48e376949bc46087b5afee896889e
src/riak_bench_driver_null.erl
src/riak_bench_driver_null.erl
%% ------------------------------------------------------------------- %% %% riak_bench: Benchmarking Suite for Riak %% %% Copyright (c) 2009 Basho Techonologies %% %% This file is provided to you under the Apache License, %% Version 2.0 (the "License"); you may not use this file %% except in compliance with the Licens...
%% ------------------------------------------------------------------- %% %% riak_bench: Benchmarking Suite for Riak %% %% Copyright (c) 2009 Basho Techonologies %% %% This file is provided to you under the Apache License, %% Version 2.0 (the "License"); you may not use this file %% except in compliance with the Licens...
Make sure to evaluate value gen on put op to get a realistic perspective of overhead
Make sure to evaluate value gen on put op to get a realistic perspective of overhead
Erlang
apache-2.0
marksteele/basho_bench,marksteele/basho_bench,linearregression/basho_bench,fogfish/basho_bench,GabrielNicolasAvellaneda/basho_bench,basho/basho_bench,leo-project/basho_bench,linearregression/basho_bench,fogfish/basho_bench,ricardobcl/basho_bench,windkit/basho_bench,Chyaboiii/basho_bench,leo-project/basho_bench,mrallen1...
f402159f544bdf9a012b34ff95f3a0acb229e386
src/sm_data.hrl
src/sm_data.hrl
%%%------------------------------------------------------------------- %%% File : sm_data.hrl %%% Author : Nicolas R Dufour <nrdufour@gmail.com> %%% Created : 2009/05/19 %%% Description : %%% Basic record containing the simulation data. %%% %%% Copyright 2009 Nicolas R Dufour <nrdufour@gmail.com> %%% %%% This softw...
%%%------------------------------------------------------------------- %%% File : sm_data.hrl %%% Author : Nicolas R Dufour <nrdufour@gmail.com> %%% Created : 2009/05/19 %%% Description : %%% Basic record containing the simulation data. %%% %%% Copyright 2009 Nicolas R Dufour <nrdufour@gmail.com> %%% %%% This softw...
Set the time to 0.
Set the time to 0.
Erlang
mit
nrdufour/similar
afd8d877748faa8c2fcc0e22a66c7532a6793624
apps/dk_ifi/src/dk_ifi_sup.erl
apps/dk_ifi/src/dk_ifi_sup.erl
-module(dk_ifi_sup). -behaviour(supervisor). %% API -export([start_link/0]). %% Supervisor callbacks -export([init/1]). %% Helper macro for declaring children of supervisor -define(CHILD(I, Type), {I, {I, start_link, []}, permanent, 5000, Type, [I]}). %%% API start_link() -> supervisor:start_link({local, ?MOD...
-module(dk_ifi_sup). -behaviour(supervisor). %% API -export([start_link/0]). %% Supervisor callbacks -export([init/1]). %% Helper macro for declaring children of supervisor -define(CHILD(I, Type), {I, {I, start_link, []}, permanent, 5000, Type, [I]}). %%% API start_link() -> supervisor:start_link({local, ?MOD...
Add child (dk_ifi gen_server) to supervisor
Add child (dk_ifi gen_server) to supervisor
Erlang
bsd-3-clause
moretea/doko,moretea/doko
a9b2152ecedbdf987e8592c73acd9fb2605aea90
master/src/worker_throttle.erl
master/src/worker_throttle.erl
-module(worker_throttle). -export([init/0, handle/1]). -define(MAX_EVENTS_PER_SECOND, 5). -opaque state() :: queue(). -type throttle() :: {ok, non_neg_integer(), state()} | {error, term()}. -export_type([state/0]). -spec init() -> state(). init() -> queue:new(). -spec handle(state()) -> throttle(). handle(Q) -...
-module(worker_throttle). -export([init/0, handle/1]). -define(MAX_EVENTS_PER_SECOND, 5). -define(MICROSECONDS_IN_SECOND, 1000000). -opaque state() :: queue(). -type throttle() :: {ok, non_neg_integer(), state()} | {error, term()}. -export_type([state/0]). -spec init() -> state(). init() -> queue:new(). -spec ...
Use a macro instead of the magic numbers.
Use a macro instead of the magic numbers. This commit has no functional effects.
Erlang
bsd-3-clause
simudream/disco,mwilliams3/disco,mozilla/disco,pombredanne/disco,pombredanne/disco,mozilla/disco,seabirdzh/disco,ErikDubbelboer/disco,oldmantaiter/disco,mwilliams3/disco,ktkt2009/disco,oldmantaiter/disco,ktkt2009/disco,discoproject/disco,pombredanne/disco,oldmantaiter/disco,seabirdzh/disco,ErikDubbelboer/disco,beni55/d...
a9bc645d3a8e0b7c5b32fed04eca734ede73f9e3
riak_test/tests/list_objects_v2_test.erl
riak_test/tests/list_objects_v2_test.erl
%% --------------------------------------------------------------------- %% %% Copyright (c) 2007-2013 Basho Technologies, Inc. All Rights Reserved. %% %% This file is provided to you under the Apache License, %% Version 2.0 (the "License"); you may not use this file %% except in compliance with the License. You may ...
%% --------------------------------------------------------------------- %% %% Copyright (c) 2007-2013 Basho Technologies, Inc. All Rights Reserved. %% %% This file is provided to you under the Apache License, %% Version 2.0 (the "License"); you may not use this file %% except in compliance with the License. You may ...
Use new riak_test helper API
Use new riak_test helper API
Erlang
apache-2.0
GabrielNicolasAvellaneda/riak_cs,sdebnath/riak_cs,GabrielNicolasAvellaneda/riak_cs,basho/riak_cs,dragonfax/riak_cs,laurenrother/riak_cs,GabrielNicolasAvellaneda/riak_cs,basho/riak_cs,dragonfax/riak_cs,GabrielNicolasAvellaneda/riak_cs,basho/riak_cs,yangchengjian/riak_cs,basho/riak_cs,dragonfax/riak_cs,dragonfax/riak_cs,...
daf8b0c418fe6bab176d1a358d88fa92f95baae7
src/similar_data.hrl
src/similar_data.hrl
%%%------------------------------------------------------------------- %%% File : similar_data.hrl %%% Author : Nicolas R Dufour <nrdufour@gmail.com> %%% Created : 2009/05/19 %%% Description : %%% Basic record containing the simulation data. %%% %%% Copyright 2009 Nicolas R Dufour <nrdufour@gmail.com> %%% %%% This ...
%%%------------------------------------------------------------------- %%% File : similar_data.hrl %%% Author : Nicolas R Dufour <nrdufour@gmail.com> %%% Created : 2009/05/19 %%% Description : %%% Basic record containing the simulation data. %%% %%% Copyright 2009 Nicolas R Dufour <nrdufour@gmail.com> %%% %%% This ...
Add a few comments in the data structure.
Add a few comments in the data structure.
Erlang
mit
nrdufour/similar
b61832139013f96e89c614fe864d45b0fec5c9b0
main.erl
main.erl
-module(main). -export([start/1]). -import(conversions, [bitstr_to_list/1, list_to_bitstr/1]). start([Name]) -> random:seed(now()), Geno = (one_max:random_genotype_fn([20]))(), io:format("~w~nHello ~s!~n", [Geno, Name]). fetch_fns(Module, Opts) -> Rand_gtype = Module:random_genotype_fn(Opts), PtoG...
-module(main). -export([start/1]). -import(conversions, [bitstr_to_list/1, list_to_bitstr/1]). start([Name]) -> random:seed(now()), Geno = (one_max:random_genotype_fn([20]))(), io:format("~w~nHello ~s!~n", [Geno, Name]). genetica_loop(0, Pop, Develop_and_select) -> done; genetica_loop(Iters, Pop, Devel...
Implement highly abstracted genetic loop.
Implement highly abstracted genetic loop.
Erlang
epl-1.0
hyPiRion/genetica,hyPiRion/genetica
6b1db885d1b07f675e00daa641eeae2e36dbb1ba
examples/eventsource/src/eventsource_handler.erl
examples/eventsource/src/eventsource_handler.erl
%% Feel free to use, reuse and abuse the code in this file. %% @doc EventSource emitter. -module(eventsource_handler). -export([init/2]). -export([info/3]). init(Req0, Opts) -> Req = cowboy_req:stream_reply(200, #{ <<"content-type">> => <<"text/event-stream">> }, Req0), erlang:send_after(1000, self(), {message,...
%% Feel free to use, reuse and abuse the code in this file. %% @doc EventSource emitter. -module(eventsource_handler). -export([init/2]). -export([info/3]). init(Req0, Opts) -> Req = cowboy_req:stream_reply(200, #{ <<"content-type">> => <<"text/event-stream">> }, Req0), erlang:send_after(1000, self(), {message,...
Use cowboy_req:stream_events in the eventsource example
Use cowboy_req:stream_events in the eventsource example
Erlang
isc
turtleDeng/cowboy,CrankWheel/cowboy,ninenines/cowboy,hairyhum/cowboy,K2InformaticsGmbH/cowboy,kivra/cowboy
dca6a42dacd3740facfddf888b1b5e6097ce4682
src/erlcdt_parser.erl
src/erlcdt_parser.erl
%%% @author Andreas Pauley %%% @copyright © 2013 Andreas Pauley https://github.com/apauley/erlcdt/blob/master/LICENSE.md %%% @doc %%% The definition of the behaviour that erlcdt library implementations should conform to. %%% %%% This code is part of the "Erlang Concrete Data Types" library: %%% https://github.com/apaul...
%%% @author Andreas Pauley %%% @copyright © 2013 Andreas Pauley https://github.com/apauley/erlcdt/blob/master/LICENSE.md %%% @doc %%% The definition of the behaviour that erlcdt library implementations should conform to. %%% %%% This code is part of the "Erlang Concrete Data Types" library: %%% https://github.com/apaul...
Change behaviour to -callback attributes
Change behaviour to -callback attributes
Erlang
mit
apauley/erlcdt
8d31d8c3870ca3d1579762b72f34178718b89724
test/src/elements/html/element_image_test.erl
test/src/elements/html/element_image_test.erl
-module(element_image_test). -compile([export_all]). -author("michael@mullistechnologies.com"). -include_lib("eunit/include/eunit.hrl"). -include("wf.inc"). new_image_1() -> Rec_image = #image{}, lists:flatten(element_image:render("1",Rec_image)). new_image_2() -> Rec_image = #image{class="t_image"}, lists...
-module(element_image_test). -compile([export_all]). -author("michael@mullistechnologies.com"). -include_lib("eunit/include/eunit.hrl"). -include("wf.inc"). new_image_1() -> Rec_image = #image{}, lists:flatten(element_image:render("1",Rec_image)). new_image_2() -> Rec_image = #image{class="t_image"}, lists...
Update image unit test to account for new 'alt' attribute.
Update image unit test to account for new 'alt' attribute.
Erlang
mit
choptastic/nitrogen,kaos/nitrogen,joaohf/nitrogen,choptastic/nitrogen,joaohf/nitrogen,kevinmontuori/nitrogen,robsc/nitrogen,kevinmontuori/nitrogen,choptastic/nitrogen,kaos/nitrogen,nitrogen/nitrogen,robsc/nitrogen,stuart-thackray/nitrogen,nitrogen/nitrogen,joaohf/nitrogen,kevinmontuori/nitrogen,nitrogen/nitrogen,stuart...
6201ebf6e31265079d360d2378379038f90c02c3
test/docsh_SUITE.erl
test/docsh_SUITE.erl
-module(docsh_SUITE). -compile(export_all). -include_lib("common_test/include/ct.hrl"). -include_lib("eunit/include/eunit.hrl"). -define(TESTED, example). -define(eq(Expected, Actual), ?assertEqual(Expected, Actual)). all() -> [edoc_example, recon]. %% %% Tests %% edoc_example(C) -> h0(C, edoc_exampl...
-module(docsh_SUITE). -compile(export_all). -include_lib("common_test/include/ct.hrl"). -include_lib("eunit/include/eunit.hrl"). -define(TESTED, example). -define(eq(Expected, Actual), ?assertEqual(Expected, Actual)). all() -> [edoc_example_has_helpers, recon_has_helpers]. %% %% Tests %% edoc_example_has...
Use more descriptive test names
Use more descriptive test names
Erlang
bsd-3-clause
lavrin/docsh
800a446b67ad01cafe52b8256574aa60c4df3ddf
src/compiler/reia_ssa.erl
src/compiler/reia_ssa.erl
-module(reia_ssa). -export([transform/2]). -include("reia_nodes.hrl"). -include("reia_compile_options.hrl"). -include("reia_bindings.hrl"). % Lists of expressions transform(Exprs, Options) -> {ok, BAExprs} = reia_bindings:transform(Exprs, Options#compile_options.scope), reia_bindings:revert(BAExprs).
-module(reia_ssa). -export([transform/2]). -include("reia_nodes.hrl"). -include("reia_compile_options.hrl"). -include("reia_bindings.hrl"). % Lists of expressions transform(Exprs, Options) -> {ok, BAExprs} = reia_bindings:transform(Exprs, Options#compile_options.scope), reia_syntax:map_subtrees(fun transform_node/...
Handle reverting from binding annotated form in the SSA transform itself
Handle reverting from binding annotated form in the SSA transform itself
Erlang
mit
tarcieri/reia,beni55/reia,beni55/reia,tarcieri/reia
1b1eef196f4bf12b184263bc35df00f0186de9cc
src/oauth1_storage.erl
src/oauth1_storage.erl
-module(oauth1_storage). -include_lib("oauth1_module_abbreviations.hrl"). -export_type( [ error/0 ]). -export( [ put/3 , get/2 ]). -type error() :: not_found | {io_error, any()} . -callback put(binary(), binary(), binary()) -> hope_result:t(ok, error()). -callback get(binary...
-module(oauth1_storage). -include_lib("oauth1_module_abbreviations.hrl"). -export_type( [ error/0 ]). -export( [ put/3 , get/2 ]). -type error() :: not_found | {io_error, any()} . -callback put(binary(), binary(), binary()) -> hope_result:t(ok, error()). -callback get(binary...
Fix incorrect function reference in the storage module.
Fix incorrect function reference in the storage module.
Erlang
mit
ibnfirnas/oauth1_core
bffa40e4f879107cdf560dcac0955766ab29b860
apps/doko_node/src/doko_node_tbl_man.erl
apps/doko_node/src/doko_node_tbl_man.erl
-module(doko_node_tbl_man). -export([init/0,start_link/0]). -define(PAUSE, 10). -record(state, {table}). %%---------------------------------------------------------------------------- %% API %%---------------------------------------------------------------------------- init() -> Table = ets:new(index_conf, [se...
-module(doko_node_tbl_man). -export([init/0,start_link/0]). -define(PAUSE, 10). -define(USER, doko_node). -record(state, {table}). %%---------------------------------------------------------------------------- %% API %%---------------------------------------------------------------------------- init() -> Table...
Make table manager shutdown cleanly
Make table manager shutdown cleanly
Erlang
bsd-3-clause
moretea/doko,moretea/doko
dabf8bc48b57e56528812a2051e180c19cf79e7c
include/bookshelf.hrl
include/bookshelf.hrl
%% @copyright 2012 Opscode, Inc. All Rights Reserved %% @author Tim Dysinger <timd@opscode.com> %% %% Licensed to the Apache Software Foundation (ASF) under one or more %% contributor license agreements. See the NOTICE file distributed %% with this work for additional information regarding copyright %% ownership. The...
%% @copyright 2012 Opscode, Inc. All Rights Reserved %% @author Tim Dysinger <timd@opscode.com> %% %% Licensed to the Apache Software Foundation (ASF) under one or more %% contributor license agreements. See the NOTICE file distributed %% with this work for additional information regarding copyright %% ownership. The...
Fix headers so they work with flymake also
Fix headers so they work with flymake also
Erlang
apache-2.0
itmustbejj/chef-server,stephenbm/chef-server,chef/chef-server,Minerapp/chef-server,charlesjohnson/chef-server,chef/bookshelf,vladuemilian/chef-server,marcparadise/chef-server,vladuemilian/chef-server,Minerapp/chef-server,charlesjohnson/chef-server,charlesjohnson/chef-server,stephenbm/chef-server,chef/chef-server,itmust...
ddd3f6ef5ce25b1fa12b71fd23505d31bb20bc2a
src/erldns.erl
src/erldns.erl
%% Copyright (c) 2012-2013, Aetrion LLC %% %% Permission to use, copy, modify, and/or distribute this software for any %% purpose with or without fee is hereby granted, provided that the above %% copyright notice and this permission notice appear in all copies. %% %% THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISC...
%% Copyright (c) 2012-2013, Aetrion LLC %% %% Permission to use, copy, modify, and/or distribute this software for any %% purpose with or without fee is hereby granted, provided that the above %% copyright notice and this permission notice appear in all copies. %% %% THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISC...
Switch how folsom is started.
Switch how folsom is started.
Erlang
mit
SiftLogic/erl-dns,redbeardster/erl-dns,aetrion/erl-dns,fromeroj/erl-dns,T0ha/erl-dns
eeaa4007c8e57d873ac96a7f75ba0ef50303fa18
include/fabric.hrl
include/fabric.hrl
% Licensed under the Apache License, Version 2.0 (the "License"); you may not % use this file except in compliance with the License. You may obtain a copy of % the License at % % http://www.apache.org/licenses/LICENSE-2.0 % % Unless required by applicable law or agreed to in writing, software % distributed under the ...
% Licensed under the Apache License, Version 2.0 (the "License"); you may not % use this file except in compliance with the License. You may obtain a copy of % the License at % % http://www.apache.org/licenses/LICENSE-2.0 % % Unless required by applicable law or agreed to in writing, software % distributed under the ...
Add collation to view result collector record
Add collation to view result collector record There's no reference to the #mrview when results are being streamed to the user, so we need a place to store the collation specification while results are collected. COUCHDB-2900
Erlang
apache-2.0
fkaempfer/couchdb,fkaempfer/couchdb,fkaempfer/couchdb,fkaempfer/couchdb,fkaempfer/couchdb,fkaempfer/couchdb
44953c988fe6de6d096f03765917bd4cfb80c7d5
include/elli.hrl
include/elli.hrl
-type callback_mod() :: atom. -type callback_args() :: any(). -type callback() :: {callback_mod(), callback_args()}. -type path() :: binary(). -type args() :: binary(). -type version() :: {0,9} | {1,0} | {1,1}. -type header() :: {Key::binary(), Value::binary() | string()}. -type headers() :: [header()]. -type body() ...
-type callback_mod() :: atom. -type callback_args() :: any(). -type callback() :: {callback_mod(), callback_args()}. -type path() :: binary(). -type args() :: binary(). -type version() :: {0,9} | {1,0} | {1,1}. -type header() :: {Key::binary(), Value::binary() | string()}. -type headers() :: [header()]. -type body() ...
Use same http methods as erlang:decode_packet(http_bin, ..., ...).
Use same http methods as erlang:decode_packet(http_bin, ..., ...).
Erlang
mit
tsloughter/elli,elli-lib/elli,odo/elli,tsloughter/elli,knutin/elli,K2InformaticsGmbH/elli,odo/elli,knutin/elli,elli-lib/elli,K2InformaticsGmbH/elli
dc8f4373cbea1b21e925072dfc7400526282058e
include/saturn_leaf.hrl
include/saturn_leaf.hrl
-define(PRINT(Var), io:format("DEBUG: ~p:~p - ~p~n~n ~p~n~n", [?MODULE, ?LINE, ??Var, Var])). -define(BUCKET, <<"saturn_leaf">>). -define(PROXY_MASTER, saturn_proxy_vnode_master). -define(PROXY_SERVICE, saturn_proxy). -define(SIMPLE_MASTER, saturn_simple_backend_vnode_master). -define(SIMPLE_SERVICE, saturn_simple_ba...
-define(PRINT(Var), io:format("DEBUG: ~p:~p - ~p~n~n ~p~n~n", [?MODULE, ?LINE, ??Var, Var])). -define(BUCKET, <<"saturn_leaf">>). -define(PROXY_MASTER, saturn_proxy_vnode_master). -define(PROXY_SERVICE, saturn_proxy). -define(SIMPLE_MASTER, saturn_simple_backend_vnode_master). -define(SIMPLE_SERVICE, saturn_simple_ba...
Add label record and payloads
Add label record and payloads
Erlang
apache-2.0
angbrav/saturn_leaf
a0af1e12f70573368183f19187252c29c55bc78a
selection_mechanisms.erl
selection_mechanisms.erl
-module(selection_mechanisms). -export([roulette_wheel_fn/1]). %% Assigns slots to the different phenotypes based on their fitness values assign_slots(Plist) -> assign_slots(Plist, 0, []). assign_slots([{indiv, I, fitness, F} | T], N, Acc) -> With_slots = {indiv, I, fitness, F, slots, [N, N+F]}, assign_sl...
-module(selection_mechanisms). -export([roulette_wheel_fn/1]). %% Assigns slots to the different phenotypes based on their fitness values assign_slots(Plist) -> assign_slots(Plist, 0, []). assign_slots([{indiv, I, fitness, F} | T], N, Acc) -> With_slots = {indiv, I, fitness, F, slots, [N, N+F]}, assign_sl...
Fix off-by-one error in roulette wheel.
Fix off-by-one error in roulette wheel.
Erlang
epl-1.0
hyPiRion/genetica,hyPiRion/genetica
6edc7b7eb5b534b456a93a1ca4f005cb3bd47d03
src/pre_client_hooks.erl
src/pre_client_hooks.erl
-module(pre_client_hooks). -include("log.hrl"). -include("pre_client.hrl"). -export([register_hooks/0, client_login_hook/2]). %% ------------------------------------------------------------------ %% API Function Definitions %% ------------------------------------------------------------------ register_hooks() -> ?...
-module(pre_client_hooks). -include("log.hrl"). -include("pre_client.hrl"). -export([register_hooks/0, client_login_hook/2]). %% ------------------------------------------------------------------ %% API Function Definitions %% ------------------------------------------------------------------ register_hooks() -> ?...
Send the setZone message over TCP instead of SSL.
Send the setZone message over TCP instead of SSL.
Erlang
mit
SkewedAspect/precursors-server,SkewedAspect/precursors-server,SkewedAspect/precursors-server,SkewedAspect/precursors-server
369f33838423cbcbed6bc9a34199cbe98adfc5ed
include/erldns.hrl
include/erldns.hrl
-record(zone, { name :: dns:dname(), version :: binary(), authority = [] :: [dns:rr()], record_count = 0 :: non_neg_integer(), records = [] :: [dns:rr()], records_by_name :: [dns:rr()], records_by_type :: [dns:rr()] }). -record(authorities, { owner_name, ttl, class, name_s...
-record(zone, { name :: dns:dname(), version :: binary(), authority = [] :: [dns:rr()], record_count = 0 :: non_neg_integer(), records = [] :: [dns:rr()], records_by_name :: [dns:rr()], records_by_type :: [dns:rr()], key_signing_key :: crypto:rsa_private(), zone_signing_key :: crypto...
Add slot for key signing key and zone signing key.
Add slot for key signing key and zone signing key.
Erlang
mit
aetrion/erl-dns
9c4fe9fab737d90f99da34da61301b8d87d18e5b
testsuite/scenarios.erl
testsuite/scenarios.erl
%%%---------------------------------------------------------------------- %%% Copyright (c) 2012, Alkis Gotovos <el3ctrologos@hotmail.com>, %%% Maria Christakis <mchrista@softlab.ntua.gr> %%% and Kostis Sagonas <kostis@cs.ntua.gr>. %%% All rights reserved. %%% %%% This file is distri...
%%%---------------------------------------------------------------------- %%% Copyright (c) 2012, Alkis Gotovos <el3ctrologos@hotmail.com>, %%% Maria Christakis <mchrista@softlab.ntua.gr> %%% and Kostis Sagonas <kostis@cs.ntua.gr>. %%% All rights reserved. %%% %%% This file is distri...
Fix a bug with extract_scenario output
Fix a bug with extract_scenario output
Erlang
bsd-2-clause
aronisstav/Concuerror,aronisstav/Concuerror,parapluu/Concuerror,parapluu/Concuerror,mariachris/Concuerror,mariachris/Concuerror,iliastsi/Concuerror
30a3b8ab3cd24328fbf0576d4143f6349fa27b5b
src/boss_cache.erl
src/boss_cache.erl
-module(boss_cache). -export([start/0, start/1]). -export([stop/0]). -export([get/2, set/4, delete/2]). -define(POOLNAME, boss_cache_pool). start() -> Adapter = boss_cache_adapter_memcached_bin, start([{adapter, Adapter}, {cache_servers, [{"127.0.0.1", 11211, 1}]}]). start(Options) -> Adapter = proplists...
-module(boss_cache). -export([start/0, start/1]). -export([stop/0]). -export([get/2, set/4, delete/2]). -define(POOLNAME, boss_cache_pool). start() -> Adapter = boss_cache_adapter_memcached_bin, start([{adapter, Adapter}, {cache_servers, [{"127.0.0.1", 11211, 1}]}]). start(Options) -> AdapterName = propl...
Fix cache adapter name bug
Fix cache adapter name bug
Erlang
mit
badubizzle/boss_db,QBkira/boss_db,mihawk/boss_db
79eb5d08e2942f2e3645ac314c54a2f84f2dd9c2
erlang-cowboy/src/eventsource_emitter.erl
erlang-cowboy/src/eventsource_emitter.erl
-module(eventsource_emitter). -behaviour(cowboy_loop_handler). -export([init/3]). -export([info/3]). -export([terminate/3]). -record(state, {}). init({_Any, http}, Req, _Opts) -> timer:send_after(0, {message, [":ok", "\n\n"]}), Headers = [ {<<"content-type">>, <<"text/event-stream">>}, {<<"ca...
-module(eventsource_emitter). -behaviour(cowboy_loop_handler). -export([init/3]). -export([info/3]). -export([terminate/3]). -record(state, {}). init({_Any, http}, Req, _Opts) -> timer:send_after(0, {message, [":ok", "\n\n"]}), Headers = [ {<<"content-type">>, <<"text/event-stream">>}, {<<"ca...
Create a non-rounded timestamp in microseconds.
Create a non-rounded timestamp in microseconds.
Erlang
mit
rexxars/sse-broadcast-benchmark,rexxars/sse-broadcast-benchmark,rexxars/sse-broadcast-benchmark,rexxars/sse-broadcast-benchmark,rexxars/sse-broadcast-benchmark,rexxars/sse-broadcast-benchmark,rexxars/sse-broadcast-benchmark,rexxars/sse-broadcast-benchmark
a665205ba96b0166bda98265e6c9278eb62add8b
src/mad.hrl
src/mad.hrl
-define(DEPS_PATH, filename:join([mad_utils:home(), ".otp", "deps"])). -define(COMPILE_OPTS(Inc, Ebin), [{i, Inc}, {outdir, Ebin}]).
-define(DEPS_PATH, filename:join([mad_utils:home(), ".otp", "deps"])). -define(COMPILE_OPTS(Inc, Ebin), [report, {i, Inc}, {outdir, Ebin}]).
Add 'report' option to compile options
Add 'report' option to compile options
Erlang
mit
rgrinberg/mad
480d7637704b363c4de8f4a8b502024d23a2a62a
nitroaction.erl
nitroaction.erl
%%%' HEADER %%% @author {{author_name}} <{{author_email}}> %%% @copyright {{copyright_year}} {{author_name}} %%% @doc Nitrogen action: {{description}} %%% @end -module({{app_name}}_{{name}}_action). -author('{{author_name}} <{{author_email}}>'). -include_lib("nitrogen_core/include/wf.hrl"). -export([render_action/1]...
%%%' HEADER %%% @author {{author_name}} <{{author_email}}> %%% @copyright {{copyright_year}} {{author_name}} %%% @doc Nitrogen action: {{description}} %%% @end -module({{app_name}}_{{name}}_action). -author('{{author_name}} <{{author_email}}>'). -include_lib("nitrogen_core/include/wf.hrl"). -export([render_action/1]...
Fix typo in Nitrogen action template
Fix typo in Nitrogen action template
Erlang
apache-2.0
jacktang/rebar-templates,jacktang/rebar-templates
e99e5e040d5cae88c086d7df2e8a7e79fa4fdfae
src/mtws_app.erl
src/mtws_app.erl
-module(mtws_app). -behaviour(application). %% Application callbacks -export([start/2, stop/1]). %% =================================================================== %% Application callbacks %% =================================================================== start(_StartType, _StartArgs) -> nitrogen_sup:star...
-module(mtws_app). -behaviour(application). %% Application callbacks -export([ start/0, start/2, stop/1 ]). %% =================================================================== %% Application callbacks %% =================================================================== start(_StartType, _StartArgs) -> ...
Add stub for fast startup
Add stub for fast startup
Erlang
mit
metachord/metalkia_web_site,metachord/metalkia_web_site
04f769fffa7ffe53cc9d9df0b9b79981a6359d22
riak_test/floppystore.erl
riak_test/floppystore.erl
-module(floppystore). -export([confirm/0]). -include_lib("eunit/include/eunit.hrl"). -define(HARNESS, (rt_config:get(rt_harness))). confirm() -> Nodes = rt:build_clusters([3]), lager:info("Nodes: ~p", [Nodes]), ok.
-module(floppystore). -export([confirm/0]). -include_lib("eunit/include/eunit.hrl"). -define(HARNESS, (rt_config:get(rt_harness))). confirm() -> Nodes = rt:build_clusters([3]), lager:info("Nodes: ~p", [Nodes]), pass.
Return pass from the test.
Return pass from the test.
Erlang
apache-2.0
ergl/antidote,SyncFree/antidote
a3dde5b9fb7c848d0e59b25e14119c2cbb13c923
src/exometer_function.erl
src/exometer_function.erl
-module(exometer_function). -behaviour(exometer_entry). -export([new/3, update/4, reset/3, setopts/4, get_value/3, sample/3, delete/3, reset/3, setopts/4]). -export([empty/0]). new(_Name, function, Opts) -> case lists:keyfind(type_arg, 1, Opts) of {_, {function, M, F}} -> {ok, {M, F}}; fa...
-module(exometer_function). -behaviour(exometer_entry). -export([new/3, update/4, reset/3, get_value/3, sample/3, delete/3, setopts/4]). -export([empty/0]). new(_Name, function, Opts) -> case lists:keyfind(type_arg, 1, Opts) of {_, {function, M, F}} -> {ok, {M, F}}; false -> {ok, {?MODUL...
Duplicate code from merge fixed
Duplicate code from merge fixed
Erlang
mpl-2.0
systra/exometer
e478c38af7a2882bf3c666cd12cdbacbe43cef02
tests/erlrc_boot_test.erl
tests/erlrc_boot_test.erl
-module (erlrc_boot_test). -export ([ start_link/0, notify/1, dump/0 ]). -behaviour (gen_server). -export ([ init/1, handle_call/3, handle_cast/2, handle_info/2, terminate/2, code_change/3]). % % public % start_link () -> gen_server:start_link ({ local, ?MODUL...
-module (erlrc_boot_test). -export ([ start_link/0, notify/1, dump/0 ]). -behaviour (gen_server). -export ([ init/1, handle_call/3, handle_cast/2, handle_info/2, terminate/2, code_change/3]). % % public % start_link () -> gen_server:start_link ({ local, ?MODUL...
Replace now() with os:timestamp() to silence deprecation warning.
Replace now() with os:timestamp() to silence deprecation warning.
Erlang
bsd-3-clause
dukesoferl/erlrc,dukesoferl/erlrc
a96d6b9d693617770bf53eb435879a4b3b660a7d
test/http_server/http_simple_handler.erl
test/http_server/http_simple_handler.erl
-module(http_simple_handler). -include_lib("mixer/include/mixer.hrl"). -mixin([ {http_base_handler, [ init/2, content_types_accepted/2, content_types_provided/2, resource_exists/2 ]} ]). -export([ allowed_methods/2 , handle_head/2 ...
-module(http_simple_handler). -include_lib("mixer/include/mixer.hrl"). -mixin([ {http_base_handler, [ init/2, content_types_accepted/2, content_types_provided/2, resource_exists/2 ]} ]). -export([ allowed_methods/2 , handle_head/2 ...
Fix few more tests but correctly reading cowboy_req body
Fix few more tests but correctly reading cowboy_req body
Erlang
apache-2.0
inaka/shotgun
30a3816c8649bbafb3695780c78c4eabbaa92eda
include/rebar.hrl
include/rebar.hrl
-record(config, { dir, opts }). -record(global_state, { working_dir }). -define(FAIL, throw({error, failed})). -define(ABORT(Str, Args), ?ERROR(Str, Args), halt(1)). -define(CONSOLE(Str, Args), io:format(Str, Args)). -define(DEBUG(Str, Args), rebar_log:log(debug, Str, Args)). -define(INFO(Str, Ar...
-record(config, { dir, opts }). -record(global_state, { working_dir }). -define(FAIL, throw({error, failed})). -define(ABORT(Str, Args), ?ERROR(Str, Args), init:stop(1)). -define(CONSOLE(Str, Args), io:format(Str, Args)). -define(DEBUG(Str, Args), rebar_log:log(debug, Str, Args)). -define(INFO(St...
Use init:stop/1 over halt/1 to ensure all I/O gets a chance to flush
Use init:stop/1 over halt/1 to ensure all I/O gets a chance to flush
Erlang
apache-2.0
syl20bnr/rebar,thomasbhatia/rebar,beni55/rebar,lrascao/rebar,scatterbrain/rebar,K2InformaticsGmbH/rebar,blt/rebar3,wcy123/rebar,paulo-ferraz-oliveira/rebar,dcarastan/rebar,lrascao/rebar,CMoH/rebar,csyangchen/rebar,norton/rebar,ferd/rebar3,GabrielNicolasAvellaneda/rebar,rebar/rebar,matwey/rebar,paulo-ferraz-oliveira/reb...
99e46c865418be6b4d8a9e657e7ed571f5e64a1c
src/mumq_app.erl
src/mumq_app.erl
-module(mumq_app). -behaviour(application). -export([start/2, stop/1]). start(_StartType, _StartArgs) -> error_logger:info_report([{"muMQ", "application started"}]), mumq_subs:init(), mumq_sup:start_link(). stop(_State) -> mumq_subs:terminate(), error_logger:info_report([{"muMQ", "appli...
-module(mumq_app). -behaviour(application). -export([start/2, stop/1]). start(_StartType, _StartArgs) -> mumq_subs:init(), mumq_sup:start_link(). stop(_State) -> mumq_subs:terminate().
Remove calls to the OTP logger
Remove calls to the OTP logger
Erlang
mit
jimenezrick/mumq
925f689629855f0318a499c32f92eaecb15924aa
test/sr_tests.erl
test/sr_tests.erl
%%%---------------------------------------------------------------------------- %%% @author Martin Wiso <martin@wiso.cz> %%% @doc %%% @end %%%---------------------------------------------------------------------------- -module(sr_tests). -compile(export_all). -include("sr.hrl"). -include_lib("eunit/include/eunit.hrl"...
%%%---------------------------------------------------------------------------- %%% @author Martin Wiso <martin@wiso.cz> %%% @doc %%% @end %%%---------------------------------------------------------------------------- -module(sr_tests). -compile(export_all). -include("sr.hrl"). -include_lib("eunit/include/eunit.hrl"...
Fix syntax error in test definition
Fix syntax error in test definition
Erlang
mit
tgrk/slacker-rtm
9c3ed6a4b157bdccf1a83f4fc7fa2eccaf2539c5
src/etcdc_sup.erl
src/etcdc_sup.erl
%% Top supervisor for etcdc %% %% ---------------------------------------------------------------------------- -module(etcdc_sup). -copyright("Christoffer Vikström <chvi77@gmail.com>"). -export([start_link/0]). -export([init/1]). -behaviour(supervisor). %% --------------------------------------------------------...
%% Top supervisor for etcdc %% %% ---------------------------------------------------------------------------- -module(etcdc_sup). -copyright("Christoffer Vikström <chvi77@gmail.com>"). -export([start_link/0]). -export([init/1]). -behaviour(supervisor). %% --------------------------------------------------------...
Fix startup bug (trying to start etcdc_stream_sup)
Fix startup bug (trying to start etcdc_stream_sup)
Erlang
apache-2.0
redink/etcdc
30bd189e6fad0c735bf96225797921ab55c72ac2
main.erl
main.erl
-module(main). -export([start/1]). -import(conversions, [bitstr_to_list/1, list_to_bitstr/1]). start([Name]) -> random:seed(now()), Geno = (one_max:random_genotype_fn([20]))(), io:format("~w~nHello ~s!~n", [Geno, Name]). %% (1) choose a genetic representation %% (2) build a population %% (3) design a fit...
-module(main). -export([start/1]). -import(conversions, [bitstr_to_list/1, list_to_bitstr/1]). start([Name]) -> random:seed(now()), Geno = (one_max:random_genotype_fn([20]))(), io:format("~w~nHello ~s!~n", [Geno, Name]). fetch_fns(Module, Opts) -> Rand_gtype = Module:random_genotype_fn(Opts), PtoG...
Add function which fetches module fns.
Add function which fetches module fns.
Erlang
epl-1.0
hyPiRion/genetica,hyPiRion/genetica
4177e0efbf90a45794786f8830e70068d2b55e82
src/riak_control_app.erl
src/riak_control_app.erl
%% ------------------------------------------------------------------- %% %% Copyright (c) 2011 Basho Technologies, Inc. %% %% This file is provided to you under the Apache License, %% Version 2.0 (the "License"); you may not use this file %% except in compliance with the License. You may obtain %% a copy of the Licen...
%% ------------------------------------------------------------------- %% %% Copyright (c) 2011 Basho Technologies, Inc. %% %% This file is provided to you under the Apache License, %% Version 2.0 (the "License"); you may not use this file %% except in compliance with the License. You may obtain %% a copy of the Licen...
Resolve incorrect capability negotation order.
Resolve incorrect capability negotation order.
Erlang
apache-2.0
basho/riak_control,riak-synrc/riak_control,basho/riak_control
80adff8656177726ba83f256a1063192133a1c60
src/erl_reader.erl
src/erl_reader.erl
-module(erl_reader). -behaviour(gen_server). -export([start/0, start_link/0, add_feed/1]). -export([init/1, handle_call/3, handle_cast/2, handle_info/2, terminate/2, code_change/3]). -record(state, {feeds=[]}). start() -> application:start(?MODULE). start_link() -> gen_server:start_link({local, ?MODULE}, ?...
-module(erl_reader). -behaviour(gen_server). -export([start/0, start_link/0, add_feed/1]). -export([init/1, handle_call/3, handle_cast/2, handle_info/2, terminate/2, code_change/3]). -record(state, {feeds=[]}). start() -> application:start(?MODULE). start_link() -> gen_server:start_link({local, ?MODULE}, ?...
Handle errors when parsing feed
Handle errors when parsing feed
Erlang
unlicense
grahamrhay/erl_reader
bc7ec5eb13efa102e09d77ef6244cd88dffd8ec1
src/print_num.erl
src/print_num.erl
-module(print_num). -export([print_all/1, print_odd/1]). print_range(I, Bound) when I =< Bound -> io:format('~B~n', [I]), print_range(I + 1, Bound); print_range(_, _) -> true. print_all(N) -> print_range(1, N). print_odd_range(I, Bound) when I =< Bound -> case (I rem 2) =/= 0 of true -> io:format('~B~n', [I]...
-module(print_num). -export([print_all/1, print_odd/1]). print_range(I, Bound) when I =< Bound -> io:format('~B~n', [I]), print_range(I + 1, Bound); print_range(_, _) -> ok. print_all(N) -> print_range(1, N). print_odd_range(I, Bound) when I =< Bound -> case (I rem 2) =/= 0 of true -> io:format('~B~n', [I]);...
Print functions return ok instead true
Print functions return ok instead true
Erlang
mit
AntonZaec/erlang_exrecises
b24f10edaa8db081553e4c3ea6801eebe532ec0d
src/logplex_drain_sup.erl
src/logplex_drain_sup.erl
%%%------------------------------------------------------------------- %% @copyright You, 2036 %% @author You <erlanghacker@example.com> %% @version {@vsn}, {@date} {@time} %% @doc drain supervisor %% @end %%%------------------------------------------------------------------- -module(logplex_drain_sup). -behaviour(sup...
%%%------------------------------------------------------------------- %% @copyright You, 2036 %% @author You <erlanghacker@example.com> %% @version {@vsn}, {@date} {@time} %% @doc drain supervisor %% @end %%%------------------------------------------------------------------- -module(logplex_drain_sup). -behaviour(sup...
Change drain supervisor parameters: now max 20 crashes in 10 seconds kills the lot.
Change drain supervisor parameters: now max 20 crashes in 10 seconds kills the lot.
Erlang
mit
voidlock/logplex,srid/logplex,mkrysiak/logplex
181b9ed1ae609c5173f1c517843fc5b2709c305f
src/floppy.erl
src/floppy.erl
-module(floppy). -include("floppy.hrl"). -export([append/2, read/2]). %% Public API %% @doc The append/2 function adds an operation to the log of the CRDT %% object stored at some key. append(Key, {OpParam, Actor}) -> Payload = #payload{key=Key, op_param=OpParam, actor=Actor}, case floppy_rep_vnode:app...
-module(floppy). -include("floppy.hrl"). -export([append/2, read/2]). %% Public API %% @doc The append/2 function adds an operation to the log of the CRDT %% object stored at some key. append(Key, {OpParam, Actor}) -> Payload = #payload{key=Key, op_param=OpParam, actor=Actor}, case floppy_rep_vnode:app...
Update return value of read operation.
Update return value of read operation. Use an ‘ok’ tuple on success to match the error tuple return value in the failure case.
Erlang
apache-2.0
ergl/antidote,SyncFree/antidote
54486492000e79d64b93faa6e09e05e89a51b339
rna-transcription/example.erl
rna-transcription/example.erl
-module(dna). -export([to_rna/1]). to_rna(Strand) -> lists:map(fun transcribe_to_rna/1, Strand). transcribe_to_rna($G) -> $C; transcribe_to_rna($C) -> $G; transcribe_to_rna($T) -> $A; transcribe_to_rna($A) -> $U.
-module(rna_transcription). -export([to_rna/1]). to_rna(Strand) -> lists:map(fun transcribe_to_rna/1, Strand). transcribe_to_rna($G) -> $C; transcribe_to_rna($C) -> $G; transcribe_to_rna($T) -> $A; transcribe_to_rna($A) -> $U.
Use the same module name in sample and tests
Use the same module name in sample and tests The example declares the `dna` module name, but the test uses `rna_transcript`. This made the `check_exercises.sh` script fail.
Erlang
mit
tmcgilchrist/xerlang,exercism/xlfe,barberj/xerlang,NobbZ/xerlang,lfex/xlfe,exercism/xerlang,macintux/xerlang
dd975bbd0a2e94c0e63727a9355a36f7dc4ebd4d
lib/edoc/test/eep48_SUITE_data/eep48_redundant.erl
lib/edoc/test/eep48_SUITE_data/eep48_redundant.erl
-module(eep48_redundant). -export_type([t_only_attr/0, t_only_tag/0, t_redundant/0]). -type t_only_attr() :: any(). %% Type `t_only_attr' defined with an attribute. %% @type t_only_tag() = any(). %% Type `t_only_tag' defined with a tag. -type t_redundant() :: any(). %% Type `t_redundant' defined with ...
-module(eep48_redundant). -export_type([t_only_attr/0, t_only_tag/0, t_redundant/0]). -type t_only_attr() :: any(). %% Type `t_only_attr' defined with an attribute. %% @type t_only_tag() = any(). %% Type `t_only_tag' defined with a tag. -type t_redundant() :: any(). %% Type `t_redundant' defined with ...
Add a fixture of a spec prefix with a module name
Add a fixture of a spec prefix with a module name Apparently, these are not handled properly by EDoc, therefore types mentioned in them aren't properly exported to docs.
Erlang
apache-2.0
ferd/otp,mikpe/otp,getong/otp,jj1bdx/otp,getong/otp,vinoski/otp,potatosalad/otp,uabboli/otp,dgud/otp,erlang/otp,mikpe/otp,emacsmirror/erlang,emacsmirror/erlang,isvilen/otp,ferd/otp,ferd/otp,rlipscombe/otp,jj1bdx/otp,dumbbell/otp,dumbbell/otp,vinoski/otp,ferd/otp,vinoski/otp,mikpe/otp,rlipscombe/otp,erlang/otp,potatosal...
d697ade987d65a05dc867d5ccc99d56ce715143a
server/src/mzb_api_metrics.erl
server/src/mzb_api_metrics.erl
-module(mzb_api_metrics). -export([get_metrics/5, extract_metric_names/1]). get_metrics(UserName, DirNode, Host, RemoteScriptPath, RemoteEnvPath) -> [Res] = mzb_subprocess:remote_cmd( UserName, [Host], io_lib:format("~s/mzbench/bin/metric_names.escript", [mzb_api...
-module(mzb_api_metrics). -export([get_metrics/5, extract_metric_names/1]). get_metrics(UserName, DirNode, Host, RemoteScriptPath, RemoteEnvPath) -> [Res] = mzb_subprocess:remote_cmd( UserName, [Host], io_lib:format("~s/mzbench/bin/metric_names.escript", [mzb_api...
Fix function_clause on handling of empty list of metrics
Fix function_clause on handling of empty list of metrics
Erlang
bsd-3-clause
moigagoo/mzbench,moigagoo/mzbench,moigagoo/mzbench,moigagoo/mzbench
c68a4807d5497cfadc21388969f191154a800494
src/rsa_id_number_tests.erl
src/rsa_id_number_tests.erl
%%% @author Andreas Pauley %%% Created : 20 Sep 2013 by Andreas Pauley -module(rsa_id_number_tests). -include_lib("proper/include/proper.hrl"). -include_lib("eunit/include/eunit.hrl"). -export([test/0]). all() -> [proper_spec_test]. -define(DEFAULT_OPTS, [{numtests,250},{to_file, user}]). -spec test() -> ok. te...
%%% @author Andreas Pauley %%% Created : 20 Sep 2013 by Andreas Pauley -module(rsa_id_number_tests). -include_lib("proper/include/proper.hrl"). -include_lib("eunit/include/eunit.hrl"). -export([test/0]). all() -> [proper_spec_test, id_length_test]. -define(DEFAULT_OPTS, [{numtests,250},{to_file, user}]). -sp...
Add failing test to see how travis picks it up
Add failing test to see how travis picks it up
Erlang
mit
apauley/erlcdt
1360ff851c096711df061319ff0094c11e5adb0a
src/bolingbroke_updates_handler.erl
src/bolingbroke_updates_handler.erl
-module(bolingbroke_updates_handler). -export([init/3, info/3, terminate/3]). -define(DEFAULT_INTERVAL_MS, 10000). init(_Type, Req, _Opts) -> Headers = [{<<"content-type">>, <<"text/event-stream">>}], {ok, Req2} = cowboy_req:chunked_reply(200, Headers, Req), self() ! update, State = undefined, {...
-module(bolingbroke_updates_handler). -export([init/2, info/3, terminate/3]). -define(DEFAULT_INTERVAL_MS, 10000). init(Req0, _Opts) -> Headers = #{<<"content-type">> => <<"text/event-stream">>}, Req = cowboy_req:stream_reply(200, Headers, Req0), self() ! update, State = undefined, {cowboy_loop,...
Fix everything that broke with cowboy 2.x
Fix everything that broke with cowboy 2.x
Erlang
apache-2.0
rlipscombe/bolingbroke,rlipscombe/bolingbroke,rlipscombe/bolingbroke
f2fd1e7b7b99f70bca45d5b83649c10cf5c5a05c
src/nitrogen/actions/action_api.erl
src/nitrogen/actions/action_api.erl
-module(action_api). -author('Maxim Sokhatsky'). -include_lib("n2o/include/wf.hrl"). -compile(export_all). render_action(Record) -> Name = Record#api.name, Data = "utf8_toByteArray(JSON.stringify(data))", PostbackScript = wf_event:new(Name, "document", Record#api.delegate, api_event, Data, []), wf:f("~...
-module(action_api). -author('Maxim Sokhatsky'). -include_lib("n2o/include/wf.hrl"). -compile(export_all). render_action(Record) -> Name = Record#api.name, Data = "utf8_toByteArray(JSON.stringify(data))", PostbackScript = wf_event:new(Name, "document", Record#api.delegate, api_event, Data, []), wf:f("~...
Convert PostbackScript to list from binary before concatination.
Convert PostbackScript to list from binary before concatination.
Erlang
mit
leikind/n2o,beni55/n2o,alttagil/n2o,beni55/n2o,kongx73/n2o,alttagil/n2o,fxmy/n2o,pap/n2o,pap/n2o,aseidlitz/n2o,alttagil/n2o,aseidlitz/n2o,aseidlitz/n2o,beni55/n2o,leikind/n2o,fxmy/n2o,kongx73/n2o,pap/n2o,fxmy/n2o
42cf37ad775b65a47f27f9e2b9b008c9718a1c75
include/ns_common.hrl
include/ns_common.hrl
%% @author Northscale <info@northscale.com> %% @copyright 2010 NorthScale, Inc. %% %% Licensed under the Apache License, Version 2.0 (the "License"); %% you may not use this file except in compliance with the License. %% You may obtain a copy of the License at %% %% http://www.apache.org/licenses/LICENSE-2.0 %% %%...
%% @author Northscale <info@northscale.com> %% @copyright 2010 NorthScale, Inc. %% %% Licensed under the Apache License, Version 2.0 (the "License"); %% you may not use this file except in compliance with the License. %% You may obtain a copy of the License at %% %% http://www.apache.org/licenses/LICENSE-2.0 %% %%...
Make it so we can use non-literal strings for log macros
Make it so we can use non-literal strings for log macros We had been relying on the compiler's concatenating adjacent strings. Change to using ++. Change-Id: I0c72eba8ed82986c750ebed106e0a4bb3c87d0d1 Reviewed-on: http://review.northscale.com/2540 Reviewed-by: Aliaksey Kandratsenka <340b8e09ca65cd3fc686427fcfed17e87ea...
Erlang
apache-2.0
nimishzynga/ns_server,daverigby/ns_server,mschoch/ns_server,membase/ns_server,vzasade/ns_server,membase/ns_server,mschoch/ns_server,daverigby/ns_server,mschoch/ns_server,daverigby/ns_server,membase/ns_server,mschoch/ns_server,ceejatec/ns_server,ceejatec/ns_server,membase/ns_server,membase/ns_server,nimishzynga/ns_serve...
97d201d6620b5bf25185595a61739c1d294dae67
src/elements/table/element_table.erl
src/elements/table/element_table.erl
% vim: sw=4 ts=4 et ft=erlang % Nitrogen Web Framework for Erlang % Copyright (c) 2008-2010 Rusty Klophaus % See MIT-LICENSE for licensing information. -module (element_table). -include_lib ("wf.hrl"). -compile(export_all). reflect() -> record_info(fields, table). render_element(Record) -> Header = case Record...
% vim: sw=4 ts=4 et ft=erlang % Nitrogen Web Framework for Erlang % Copyright (c) 2008-2010 Rusty Klophaus % See MIT-LICENSE for licensing information. -module (element_table). -include_lib ("wf.hrl"). -compile(export_all). reflect() -> record_info(fields, table). render_element(Record) -> Header = case Record...
Remove cellspacing=0 and cellpadding=0 from table
Remove cellspacing=0 and cellpadding=0 from table
Erlang
mit
choptastic/nitrogen_core,choptastic/nitrogen_core,nitrogen/nitrogen_core,nitrogen/nitrogen_core,stuart-thackray/nitrogen_core,nitrogen/nitrogen_core,choptastic/nitrogen_core,nitrogen/nitrogen_core,SovereignPrime/nitrogen_core,stuart-thackray/nitrogen_core,stuart-thackray/nitrogen_core,SovereignPrime/nitrogen_core,Sover...
92fefcf52cfe944dd282d97e5385986c32db6248
apps/ddb_proxy/src/ddb_proxy_sup.erl
apps/ddb_proxy/src/ddb_proxy_sup.erl
%%%------------------------------------------------------------------- %% @doc ddb_proxy top level supervisor. %% @end %%%------------------------------------------------------------------- -module(ddb_proxy_sup). -behaviour(supervisor). %% API -export([start_link/0]). %% Supervisor callbacks -export([init/1]). -d...
%%%------------------------------------------------------------------- %% @doc ddb_proxy top level supervisor. %% @end %%%------------------------------------------------------------------- -module(ddb_proxy_sup). -behaviour(supervisor). %% API -export([start_link/0]). %% Supervisor callbacks -export([init/1]). -d...
Read listener config from app state
Read listener config from app state
Erlang
mit
davecromberge/ddb_proxy,dalmatinerdb/ddb_proxy
f3662acb44008dda66cfccb6eddc4330fe9bfd6e
src/chttpd_test_util.erl
src/chttpd_test_util.erl
% Licensed under the Apache License, Version 2.0 (the "License"); you may not % use this file except in compliance with the License. You may obtain a copy of % the License at % % http://www.apache.org/licenses/LICENSE-2.0 % % Unless required by applicable law or agreed to in writing, software % distributed under the ...
% Licensed under the Apache License, Version 2.0 (the "License"); you may not % use this file except in compliance with the License. You may obtain a copy of % the License at % % http://www.apache.org/licenses/LICENSE-2.0 % % Unless required by applicable law or agreed to in writing, software % distributed under the ...
Fix chttpd tests using new test_util:start_applications protocol
Fix chttpd tests using new test_util:start_applications protocol
Erlang
apache-2.0
fkaempfer/couchdb,fkaempfer/couchdb,fkaempfer/couchdb,fkaempfer/couchdb,fkaempfer/couchdb,fkaempfer/couchdb
760cd8249a4b760575cd64b97b84d808cac17a11
test/docsh_SUITE.erl
test/docsh_SUITE.erl
-module(docsh_SUITE). -compile(export_all). -include_lib("common_test/include/ct.hrl"). -include_lib("eunit/include/eunit.hrl"). -define(TESTED, example). -define(eq(Expected, Actual), ?assertEqual(Expected, Actual)). all() -> [edoc_example_has_helpers, recon_has_helpers]. %% %% Tests %% edoc_example_has...
-module(docsh_SUITE). -compile(export_all). -include_lib("common_test/include/ct.hrl"). -include_lib("eunit/include/eunit.hrl"). -define(TESTED, example). -define(eq(Expected, Actual), ?assertEqual(Expected, Actual)). all() -> [edoc_example_has_helpers, recon_has_helpers]. %% %% Tests %% edoc_example_has...
Fix hardcoded module name in test
Fix hardcoded module name in test
Erlang
bsd-3-clause
lavrin/docsh
afbe5391041ab7193aac112c5c0b716a3e3ed27f
bench/basho_bench_driver_moss.erl
bench/basho_bench_driver_moss.erl
%% ------------------------------------------------------------------- %% %% Copyright (c) 2007-2011 Basho Technologies, Inc. All Rights Reserved. %% %% -------------------------------------------------------------------
%% ------------------------------------------------------------------- %% %% Copyright (c) 2007-2011 Basho Technologies, Inc. All Rights Reserved. %% %% ------------------------------------------------------------------- -module(basho_bench_driver_moss). -export([new/1, run/4]). -include("basho_bench.hrl")...
Add skeleton new and run funcs
Add skeleton new and run funcs AZ918
Erlang
apache-2.0
sdebnath/riak_cs,dragonfax/riak_cs,dragonfax/riak_cs,dragonfax/riak_cs,yangchengjian/riak_cs,sdebnath/riak_cs,GabrielNicolasAvellaneda/riak_cs,basho/riak_cs,GabrielNicolasAvellaneda/riak_cs,yangchengjian/riak_cs,laurenrother/riak_cs,basho/riak_cs,GabrielNicolasAvellaneda/riak_cs,laurenrother/riak_cs,yangchengjian/riak_...
ea7a6faafb215845603236d03d611a3d5781cb5c
test/memebot_tests.erl
test/memebot_tests.erl
-module(memebot_tests). -include_lib("proper/include/proper.hrl"). -include_lib("eunit/include/eunit.hrl"). memebot_test_() -> {timeout, 60, ?_assert(run_props())}. run_props() -> case proper:module(?MODULE, [long_result, {to_file, user}]) of [] -> true; Result -> ?debugFmt("~p~n", [Result]), ...
-module(memebot_tests). -include_lib("proper/include/proper.hrl"). -include_lib("eunit/include/eunit.hrl"). memebot_test_() -> {timeout, 60, ?_assert(run_props())}. run_props() -> case proper:module(?MODULE, [long_result, {to_file, user}]) of [] -> true; Result -> ?debugFmt("~p~n", [Result]), ...
Return error, rather than false
Return error, rather than false
Erlang
bsd-3-clause
barbct5/memegen,barbct5/memegen
bfe3ef0fb3f1eee51186eb959b2812bd8dfea982
upgrades/v33_v34/live_upgrade.erl
upgrades/v33_v34/live_upgrade.erl
f(ChildPids). ChildPids = fun (Sup) -> [ element(2, R) || R <- supervisor:which_children(Sup) ] end. f(UpgradeNode). UpgradeNode = fun () -> io:format(whereis(user), "at=upgrade_start~n", []), Proxies = ChildPids(tcp_proxy_sup), lists:map(fun sys:suspend/1, Proxies), l(tcp_proxy), ...
f(ChildPids). ChildPids = fun (Sup) -> [ element(2, R) || R <- supervisor:which_children(Sup) ] end. f(UpgradeNode). UpgradeNode = fun () -> io:format(whereis(user), "at=upgrade_start cur_vsn=33~n", []), Proxies = ChildPids(tcp_proxy_sup), lists:map(fun sys:suspend/1, Proxies), l(tcp...
Add version tags to upgrade messages.
Add version tags to upgrade messages.
Erlang
mit
srid/logplex,mkrysiak/logplex,voidlock/logplex
60a88fdfbc5a5aa1f075d531a73da44993ee8e81
include/oz/oz_users.hrl
include/oz/oz_users.hrl
%%%------------------------------------------------------------------- %%% @author Krzysztof Trzepla %%% @copyright (C) 2014 ACK CYFRONET AGH %%% This software is released under the MIT license %%% cited in 'LICENSE.txt'. %%% @end %%%------------------------------------------------------------------- %%% @doc OZ defini...
%%%------------------------------------------------------------------- %%% @author Krzysztof Trzepla %%% @copyright (C) 2014 ACK CYFRONET AGH %%% This software is released under the MIT license %%% cited in 'LICENSE.txt'. %%% @end %%%------------------------------------------------------------------- %%% @doc OZ defini...
Update type of connected_accounts info
Update type of connected_accounts info
Erlang
mit
onedata/ctool,onedata/ctool,onedata/ctool
02649ab57b0d20786a2457269f66bd112235cba1
server/apps/pushy/src/pushy_command_switch.erl
server/apps/pushy/src/pushy_command_switch.erl
%% -*- erlang-indent-level: 4;indent-tabs-mode: nil; fill-column: 92 -*- %% ex: ts=4 sw=4 et %%% @author Mark Anderson <mark@opscode.com> %%% @copyright Copyright 2012-2012 Opscode Inc. %%% @doc %%% Mux-demux for commands to clients and responses from clients %%% @end
%% -*- erlang-indent-level: 4;indent-tabs-mode: nil; fill-column: 92 -*- %% ex: ts=4 sw=4 et %%% @author Mark Anderson <mark@opscode.com> %%% @copyright Copyright 2012-2012 Opscode Inc. %%% @doc %%% Mux-demux for commands to clients and responses from clients %%% @end -module(pushy_command_switch). -behaviour(gen_serv...
Add basic structure of command switch code
Add basic structure of command switch code
Erlang
apache-2.0
MSch/opscode-pushy-server,chef/opscode-pushy-server,chef/opscode-pushy-client,chef/opscode-pushy-server,MSch/opscode-pushy-server,chef/opscode-pushy-client,chef/opscode-pushy-client,chef/opscode-pushy-server
28b6f4cc668440032646e9bfba6b3487fe5f6321
src/ebloomd_app.erl
src/ebloomd_app.erl
%% @license The FreeBSD License %% @copyright 2012 Wooga GmbH -module (ebloomd_app). -compile ([export_all]). -behaviour (application). -export ([start/2, stop/1]). % Callback starting the backend. start(_StartType, _StartArgs) -> % Start ranch as well. application:start(ranch), ebloomd_sup:start_link()...
%% @license The FreeBSD License %% @copyright 2012 Wooga GmbH -module (ebloomd_app). -compile ([export_all]). -behaviour (application). -export ([start/2, stop/1]). % Callback starting the backend. start(_StartType, _StartArgs) -> % Start ranch as well. application:start(ranch), ebloomd_sup:start_link()...
Stop ranch when stopping ebloomd
Stop ranch when stopping ebloomd
Erlang
bsd-2-clause
wooga/ebloomd,wooga/ebloomd,wooga/ebloomd
74e3ba56e47afd2ba16e13bb22ba08821ac60497
tests/test_erlcfg_interp.erl
tests/test_erlcfg_interp.erl
-module(test_erlcfg_interp). -include_lib("eunit/include/eunit.hrl"). new_test() -> ?assertEqual([], erlcfg_interp:new()). eval_val_with_empty_interp_test() -> Interp = erlcfg_interp:new(), Expected = {Interp, foo}, ?assertEqual(Expected, erlcfg_interp:eval(Interp, {val, foo, nil})). eval_val_with_n...
-module(test_erlcfg_interp). -include_lib("eunit/include/eunit.hrl"). new_test() -> ?assertEqual({c, '', []}, erlcfg_interp:new()). eval_val_with_empty_interp_test() -> Interp = erlcfg_interp:new(), Expected = {Interp, foo}, ?assertEqual(Expected, erlcfg_interp:eval(Interp, {val, foo, nil})). eval_v...
Update erlcfg_interp unittests, to work properly again
Update erlcfg_interp unittests, to work properly again
Erlang
bsd-3-clause
saleyn/erlcfg
7ab12d1b66910d3651f7b2311a2fb6d17b9e4f31
examples/echo_post/src/toppage_handler.erl
examples/echo_post/src/toppage_handler.erl
%% Feel free to use, reuse and abuse the code in this file. %% @doc POST echo handler. -module(toppage_handler). -export([init/3]). -export([handle/2]). -export([terminate/3]). init(_Transport, Req, []) -> {ok, Req, undefined}. handle(Req, State) -> {Method, Req2} = cowboy_req:method(Req), HasBody = cowboy_req:h...
%% Feel free to use, reuse and abuse the code in this file. %% @doc POST echo handler. -module(toppage_handler). -export([init/3]). -export([handle/2]). -export([terminate/3]). init(_Transport, Req, []) -> {ok, Req, undefined}. handle(Req, State) -> {Method, Req2} = cowboy_req:method(Req), HasBody = cowboy_req:h...
Fix wrong header sent in echo_post example
Fix wrong header sent in echo_post example
Erlang
isc
pap/cowboy,nviennot/cowboy,ninenines/cowboy,bsmr-erlang/cowboy,omusico/cowboy,grahamrhay/cowboy,noname007/cowboy,heroku/cowboyku,cad627/cowboy,hairyhum/cowboy,dangjun625/cowboy,K2InformaticsGmbH/cowboy,binarin/cowboy,ferd/cowboyku,cad627/cowboy,paulperegud/cowboy,rabbitmq/cowboy,essen/cowboy,binarin/cowboy,bobos/ecweb,...
d2f48d06a1303079545122acf3db973f345bb33d
modules/mod_ginger_base/mod_ginger_base.erl
modules/mod_ginger_base/mod_ginger_base.erl
%% @author Driebit <info@driebit.nl> %% @copyright 2015 -module(mod_ginger_base). -author("Driebit <info@driebit.nl>"). -mod_title("Ginger Base"). -mod_description("Ginger Base"). -mod_prio(250).
%% @author Driebit <info@driebit.nl> %% @copyright 2015 -module(mod_ginger_base). -author("Driebit <info@driebit.nl>"). -mod_title("Ginger Base"). -mod_description("Ginger Base"). -mod_prio(250). -export([event/2]). -include("zotonic.hrl"). %% @doc Handle the submit event of a new comment event(#submit{message...
Add custom actions to newcomment postback
[base] Add custom actions to newcomment postback
Erlang
apache-2.0
driebit/ginger,driebit/ginger,driebit/ginger
15986d806c5263cdd49c1c5b59fc217ad0f241ee
src/utils/mas.erl
src/utils/mas.erl
%% @doc This module starts the mas framework with given environment, %% time and parameters -module (mas). -export ([start/3]). -export_type([agent/0, agent/1, sim_params/0, sim_params/1, agent_behaviour/0, agent_behaviour/1]). -include ("mas.hrl")...
%% @doc This module starts the mas framework with given environment, %% time and parameters -module (mas). -export ([start/3]). -export_type([agent/0, agent/1, sim_params/0, sim_params/1, agent_behaviour/0, agent_behaviour/1]). -include ("mas.hrl")...
Print config in one line.
Print config in one line.
Erlang
mit
ParaPhraseAGH/erlang-mas