hexsha stringlengths 40 40 | size int64 2 991k | ext stringclasses 2
values | lang stringclasses 1
value | max_stars_repo_path stringlengths 4 208 | max_stars_repo_name stringlengths 6 106 | max_stars_repo_head_hexsha stringlengths 40 40 | max_stars_repo_licenses list | max_stars_count int64 1 33.5k ⌀ | max_stars_repo_stars_event_min_datetime stringlengths 24 24 ⌀ | max_stars_repo_stars_event_max_datetime stringlengths 24 24 ⌀ | max_issues_repo_path stringlengths 4 208 | max_issues_repo_name stringlengths 6 106 | max_issues_repo_head_hexsha stringlengths 40 40 | max_issues_repo_licenses list | max_issues_count int64 1 16.3k ⌀ | max_issues_repo_issues_event_min_datetime stringlengths 24 24 ⌀ | max_issues_repo_issues_event_max_datetime stringlengths 24 24 ⌀ | max_forks_repo_path stringlengths 4 208 | max_forks_repo_name stringlengths 6 106 | max_forks_repo_head_hexsha stringlengths 40 40 | max_forks_repo_licenses list | max_forks_count int64 1 6.91k ⌀ | max_forks_repo_forks_event_min_datetime stringlengths 24 24 ⌀ | max_forks_repo_forks_event_max_datetime stringlengths 24 24 ⌀ | content stringlengths 2 991k | avg_line_length float64 1 36k | max_line_length int64 1 977k | alphanum_fraction float64 0 1 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
6203f9e017c8c2182e94b60ccf41264ba403ebc0 | 23,023 | ex | Elixir | lib/geometry/wkb/parser.ex | hrzndhrn/geometry | bffdac0a9554f7f5fd05caceee0fa8f3c96d1c60 | [
"MIT"
] | null | null | null | lib/geometry/wkb/parser.ex | hrzndhrn/geometry | bffdac0a9554f7f5fd05caceee0fa8f3c96d1c60 | [
"MIT"
] | 2 | 2020-10-25T10:06:07.000Z | 2020-10-26T18:15:20.000Z | lib/geometry/wkb/parser.ex | hrzndhrn/geometry | bffdac0a9554f7f5fd05caceee0fa8f3c96d1c60 | [
"MIT"
] | null | null | null | defmodule Geometry.WKB.Parser do
@moduledoc false
alias Geometry.{
GeometryCollection,
GeometryCollectionM,
GeometryCollectionZ,
GeometryCollectionZM,
Hex,
LineString,
LineStringM,
LineStringZ,
LineStringZM,
MultiLineString,
MultiLineStringM,
MultiLineStringZ,
Mu... | 32.020862 | 100 | 0.576467 |
62045bc9474f1b491f651e07ce7290927413b441 | 2,052 | ex | Elixir | clients/dfa_reporting/lib/google_api/dfa_reporting/v33/model/creative_groups_list_response.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/dfa_reporting/lib/google_api/dfa_reporting/v33/model/creative_groups_list_response.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/dfa_reporting/lib/google_api/dfa_reporting/v33/model/creative_groups_list_response.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | # Copyright 2019 Google LLC
#
# 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, s... | 38.716981 | 198 | 0.741715 |
6204a0068625ffeaf54243dd6b353094cd33be09 | 120 | exs | Elixir | test/gw_cli_test.exs | diskshima/git_web_cli | 45bcbfe4b63a37cadd3d948dedf14b36a9e3f9a3 | [
"MIT"
] | null | null | null | test/gw_cli_test.exs | diskshima/git_web_cli | 45bcbfe4b63a37cadd3d948dedf14b36a9e3f9a3 | [
"MIT"
] | 6 | 2016-06-26T15:27:35.000Z | 2016-06-26T15:28:00.000Z | test/gw_cli_test.exs | diskshima/git_web_cli | 45bcbfe4b63a37cadd3d948dedf14b36a9e3f9a3 | [
"MIT"
] | null | null | null | defmodule GitWebCliTest do
use ExUnit.Case
doctest GitWebCli
test "the truth" do
assert 1 + 1 == 2
end
end
| 13.333333 | 26 | 0.683333 |
6204badc72658cd2573ee4afe02ba14f5e5235d3 | 1,005 | exs | Elixir | elixir_heat/config/test.exs | tavareshenrique/nlw-heat | 5e735388cf899b7a6796bb7da8d01aeee6abdd69 | [
"MIT"
] | null | null | null | elixir_heat/config/test.exs | tavareshenrique/nlw-heat | 5e735388cf899b7a6796bb7da8d01aeee6abdd69 | [
"MIT"
] | null | null | null | elixir_heat/config/test.exs | tavareshenrique/nlw-heat | 5e735388cf899b7a6796bb7da8d01aeee6abdd69 | [
"MIT"
] | null | null | null | import Config
# Configure your database
#
# The MIX_TEST_PARTITION environment variable can be used
# to provide built-in test partitioning in CI environment.
# Run `mix help test` for more information.
config :elixir_heat, ElixirHeat.Repo,
username: "postgres",
password: "docker",
database: "elixir_heat_test#{S... | 32.419355 | 86 | 0.763184 |
620524023d6c78d8ef7d9008da6ca95517f105c2 | 321 | ex | Elixir | lib/mix/tasks/taglet/utils.ex | ringofhealth/ex_tag | a0aa0a3c8f57311867e33d2290a944a46351d0e2 | [
"Apache-2.0"
] | 15 | 2017-06-21T20:17:23.000Z | 2020-08-27T05:33:37.000Z | lib/mix/tasks/taglet/utils.ex | ringofhealth/ex_tag | a0aa0a3c8f57311867e33d2290a944a46351d0e2 | [
"Apache-2.0"
] | 3 | 2017-07-20T10:13:38.000Z | 2018-01-08T23:51:17.000Z | lib/mix/tasks/taglet/utils.ex | ringofhealth/ex_tag | a0aa0a3c8f57311867e33d2290a944a46351d0e2 | [
"Apache-2.0"
] | 14 | 2017-08-07T14:54:31.000Z | 2021-04-05T00:09:01.000Z | defmodule Mix.Tasks.Taglet.Utils do
@moduledoc"""
Some helper functions for tasks
"""
def timestamp do
{{y, m, d}, {hh, mm, ss}} = :calendar.universal_time()
"#{y}#{pad(m)}#{pad(d)}#{pad(hh)}#{pad(mm)}#{pad(ss)}"
end
defp pad(i) when i < 10, do: << ?0, ?0 + i >>
defp pad(i), do: to_string(i)
end... | 22.928571 | 58 | 0.563863 |
620543a1de8629d83c973de9e2d7d6ce9dcd1cd9 | 5,142 | ex | Elixir | lib/delta_crdt/aw_lww_map.ex | fmbraga/delta_crdt_ex | 3914be8096d2d39c2e67ddb3af28c0e3b7d0b1ff | [
"MIT"
] | 374 | 2018-05-15T11:37:36.000Z | 2022-01-26T19:44:52.000Z | lib/delta_crdt/aw_lww_map.ex | fmbraga/delta_crdt_ex | 3914be8096d2d39c2e67ddb3af28c0e3b7d0b1ff | [
"MIT"
] | 36 | 2018-05-25T18:33:09.000Z | 2021-09-30T08:33:44.000Z | lib/delta_crdt/aw_lww_map.ex | fmbraga/delta_crdt_ex | 3914be8096d2d39c2e67ddb3af28c0e3b7d0b1ff | [
"MIT"
] | 41 | 2018-05-16T14:41:19.000Z | 2022-03-02T18:10:14.000Z | defmodule DeltaCrdt.AWLWWMap do
defstruct dots: MapSet.new(),
value: %{}
require Logger
@doc false
def new(), do: %__MODULE__{}
defmodule Dots do
@moduledoc false
def compress(dots = %MapSet{}) do
Enum.reduce(dots, %{}, fn {c, i}, dots_map ->
Map.update(dots_map, c, i, fn... | 22.552632 | 93 | 0.551536 |
620545c95f5ff3f5b14d99262f7959d32122bc0f | 402 | exs | Elixir | test/models/tag_test.exs | avinoth/spaces | 00bec5adf4568fef73b49e57808033295a837931 | [
"MIT"
] | 1 | 2016-09-13T10:40:53.000Z | 2016-09-13T10:40:53.000Z | test/models/tag_test.exs | avinoth/spaces | 00bec5adf4568fef73b49e57808033295a837931 | [
"MIT"
] | null | null | null | test/models/tag_test.exs | avinoth/spaces | 00bec5adf4568fef73b49e57808033295a837931 | [
"MIT"
] | null | null | null | defmodule Spaces.TagTest do
use Spaces.ModelCase
alias Spaces.Tag
@valid_attrs %{name: "some content"}
@invalid_attrs %{}
test "changeset with valid attributes" do
changeset = Tag.changeset(%Tag{}, @valid_attrs)
assert changeset.valid?
end
test "changeset with invalid attributes" do
change... | 21.157895 | 53 | 0.711443 |
620559604b645712db323be07573a18d40768773 | 5,779 | ex | Elixir | lib/data/save/migrations.ex | jgsmith/ex_venture | 546adaa8fe80d45a72fde6de8d8d6906902c12d4 | [
"MIT"
] | 2 | 2019-05-14T11:36:44.000Z | 2020-07-01T08:54:04.000Z | lib/data/save/migrations.ex | nickwalton/ex_venture | d8ff1b0181db03f9ddcb7610ae7ab533feecbfbb | [
"MIT"
] | null | null | null | lib/data/save/migrations.ex | nickwalton/ex_venture | d8ff1b0181db03f9ddcb7610ae7ab533feecbfbb | [
"MIT"
] | 1 | 2021-01-29T14:12:40.000Z | 2021-01-29T14:12:40.000Z | defmodule Data.Save.Migrations do
@moduledoc """
Migrate data from one save version to another
Always in the higher direction
"""
alias Data.Item
alias Data.Save.Config
alias Data.Type
@doc """
Migrate an old save forward
"""
def migrate(save) do
case Map.has_key?(save, :version) do
t... | 23.781893 | 76 | 0.59249 |
620559c4437f5571598c3dfafd0a0a1f7f0fd9cf | 154 | ex | Elixir | testData/org/elixir_lang/parser_definition/unmatched_expression_parsing_test_case/ExclamationPointUnqualifiedNoParenthesesCallBlock.ex | keyno63/intellij-elixir | 4033e319992c53ddd42a683ee7123a97b5e34f02 | [
"Apache-2.0"
] | 1,668 | 2015-01-03T05:54:27.000Z | 2022-03-25T08:01:20.000Z | testData/org/elixir_lang/parser_definition/unmatched_expression_parsing_test_case/ExclamationPointUnqualifiedNoParenthesesCallBlock.ex | keyno63/intellij-elixir | 4033e319992c53ddd42a683ee7123a97b5e34f02 | [
"Apache-2.0"
] | 2,018 | 2015-01-01T22:43:39.000Z | 2022-03-31T20:13:08.000Z | testData/org/elixir_lang/parser_definition/unmatched_expression_parsing_test_case/ExclamationPointUnqualifiedNoParenthesesCallBlock.ex | keyno63/intellij-elixir | 4033e319992c53ddd42a683ee7123a97b5e34f02 | [
"Apache-2.0"
] | 145 | 2015-01-15T11:37:16.000Z | 2021-12-22T05:51:02.000Z | !one key: value do end
!one two three, key: value do end
!one two, key: value do end
!one two, three do end
!one two + three do end
!one two three do end
| 22 | 33 | 0.694805 |
620567f8a1288340ac551d7415e79e0a8ac99d50 | 585 | ex | Elixir | lib/web/controllers/admin/user_controller.ex | christhekeele/ex_venture | 4f4b329f50a133e219969f9823144a4cb9bf738d | [
"MIT"
] | 1 | 2021-12-28T20:57:32.000Z | 2021-12-28T20:57:32.000Z | lib/web/controllers/admin/user_controller.ex | christhekeele/ex_venture | 4f4b329f50a133e219969f9823144a4cb9bf738d | [
"MIT"
] | null | null | null | lib/web/controllers/admin/user_controller.ex | christhekeele/ex_venture | 4f4b329f50a133e219969f9823144a4cb9bf738d | [
"MIT"
] | null | null | null | defmodule Web.Admin.UserController do
use Web, :controller
alias ExVenture.Users
plug(Web.Plugs.ActiveTab, tab: :users)
plug(Web.Plugs.FetchPage when action in [:index])
def index(conn, _params) do
%{page: page, per: per} = conn.assigns
%{page: users, pagination: pagination} = Users.all(page: page,... | 21.666667 | 76 | 0.62735 |
6205854384bad28c6833fdaffcb5ed813d451cf4 | 2,027 | ex | Elixir | clients/compute/lib/google_api/compute/v1/model/autoscaler_aggregated_list_warning_data.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/compute/lib/google_api/compute/v1/model/autoscaler_aggregated_list_warning_data.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | 1 | 2020-12-18T09:25:12.000Z | 2020-12-18T09:25:12.000Z | clients/compute/lib/google_api/compute/v1/model/autoscaler_aggregated_list_warning_data.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | 1 | 2020-10-04T10:12:44.000Z | 2020-10-04T10:12:44.000Z | # Copyright 2019 Google LLC
#
# 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, s... | 40.54 | 527 | 0.744943 |
6205b198177569033a651015f7b04179d337d959 | 10,422 | ex | Elixir | lib/web/conn.ex | IvanPereyra-23/PaaS | 0179c7b57645473308b0a295a70b6284ed220fbf | [
"Apache-2.0"
] | 1 | 2020-08-27T18:43:11.000Z | 2020-08-27T18:43:11.000Z | lib/web/conn.ex | IvanPereyra-23/PaaS | 0179c7b57645473308b0a295a70b6284ed220fbf | [
"Apache-2.0"
] | null | null | null | lib/web/conn.ex | IvanPereyra-23/PaaS | 0179c7b57645473308b0a295a70b6284ed220fbf | [
"Apache-2.0"
] | 1 | 2020-08-27T18:43:21.000Z | 2020-08-27T18:43:21.000Z | # Copyright(c) 2015-2020 ACCESS CO., LTD. All rights reserved.
use Croma
alias Antikythera.Http
defmodule Antikythera.Request do
@moduledoc """
Definition of `Antikythera.Request` struct.
"""
defmodule PathMatches do
use Croma.SubtypeOfMap, key_module: Croma.Atom, value_module: Croma.String
end
defm... | 36.440559 | 144 | 0.657743 |
6205f2897a60b6f16e1a13bd62e396f6f9697498 | 2,666 | ex | Elixir | clients/cloud_tasks/lib/google_api/cloud_tasks/v2beta2/model/task_status.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2021-12-20T03:40:53.000Z | 2021-12-20T03:40:53.000Z | clients/cloud_tasks/lib/google_api/cloud_tasks/v2beta2/model/task_status.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2020-08-18T00:11:23.000Z | 2020-08-18T00:44:16.000Z | clients/cloud_tasks/lib/google_api/cloud_tasks/v2beta2/model/task_status.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | null | null | null | # Copyright 2019 Google LLC
#
# 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, s... | 47.607143 | 307 | 0.746437 |
620604951aca979d17ff2aec3ca4a1ff7af7649b | 1,464 | exs | Elixir | exercises/word-count/test/word_count_test.exs | filalex77/exercism-elixir | df6beeea3fe8b003a0f761aa3f02b66a8a5e83ff | [
"MIT"
] | null | null | null | exercises/word-count/test/word_count_test.exs | filalex77/exercism-elixir | df6beeea3fe8b003a0f761aa3f02b66a8a5e83ff | [
"MIT"
] | null | null | null | exercises/word-count/test/word_count_test.exs | filalex77/exercism-elixir | df6beeea3fe8b003a0f761aa3f02b66a8a5e83ff | [
"MIT"
] | null | null | null | defmodule WordsTest do
use ExUnit.Case
test "count one word" do
assert Words.count("word") == %{"word" => 1}
end
@tag :pending
test "count one of each" do
expected = %{"one" => 1, "of" => 1, "each" => 1}
assert Words.count("one of each") == expected
end
@tag :pending
test "count multiple ... | 26.142857 | 86 | 0.588115 |
6206098a8e438a6732ef1be6efdf8b26176d295e | 2,724 | exs | Elixir | design/0004-wire-protocol/prototype/codec.exs | zwizwa/proposals | 758f8967657aea377187bfc385861585f1734772 | [
"Apache-2.0"
] | 17 | 2020-03-26T00:43:55.000Z | 2021-08-06T19:31:50.000Z | design/0004-wire-protocol/prototype/codec.exs | zwizwa/proposals | 758f8967657aea377187bfc385861585f1734772 | [
"Apache-2.0"
] | 49 | 2020-01-19T05:28:38.000Z | 2022-02-16T18:33:52.000Z | design/0004-wire-protocol/prototype/codec.exs | zwizwa/proposals | 758f8967657aea377187bfc385861585f1734772 | [
"Apache-2.0"
] | 8 | 2020-01-24T08:49:54.000Z | 2021-12-04T13:56:33.000Z |
defmodule Ockam.Message.Ping, do: defstruct []
defmodule Ockam.Message.Pong, do: defstruct []
defmodule Ockam.Message.Payload, do: defstruct [:data]
defmodule Ockam.Message.Payload.AuthenticatedEncrypted, do: defstruct [:encrypted_data, :authentication_tag]
defmodule Ockam.Message.KeyAgreement.T1.M1, do: defstruct [:d... | 37.833333 | 124 | 0.714758 |
620615946821140f16fbb7651143d74c4b8f6ce5 | 1,768 | ex | Elixir | lib/ex_esi/cache/ets_store.ex | lukasni/ex-esi | b902a2a4d9ef834473c71b5c470320cc2854e8eb | [
"MIT"
] | null | null | null | lib/ex_esi/cache/ets_store.ex | lukasni/ex-esi | b902a2a4d9ef834473c71b5c470320cc2854e8eb | [
"MIT"
] | null | null | null | lib/ex_esi/cache/ets_store.ex | lukasni/ex-esi | b902a2a4d9ef834473c71b5c470320cc2854e8eb | [
"MIT"
] | null | null | null | defmodule ExEsi.Cache.ETSStore do
use GenServer
@behaviour ExEsi.Cache
@name __MODULE__
@expire_every :timer.minutes(5)
# Client API
def start(default \\ []) do
GenServer.start(__MODULE__, default, name: @name)
end
def start_link(default \\ []) do
GenServer.start_link(__MODULE__, default, ... | 20.8 | 80 | 0.63914 |
620675e4019ccaaa1332a4ae53c03a8e64c24100 | 3,809 | ex | Elixir | apps/omg_eth/lib/omg_eth/root_chain.ex | omisego/elixir-omg | 2c68973d8f29033d137f63a6e060f12e2a7dcd59 | [
"Apache-2.0"
] | 177 | 2018-08-24T03:51:02.000Z | 2020-05-30T13:29:25.000Z | apps/omg_eth/lib/omg_eth/root_chain.ex | omisego/elixir-omg | 2c68973d8f29033d137f63a6e060f12e2a7dcd59 | [
"Apache-2.0"
] | 1,042 | 2018-08-25T00:52:39.000Z | 2020-06-01T05:15:17.000Z | apps/omg_eth/lib/omg_eth/root_chain.ex | omisego/elixir-omg | 2c68973d8f29033d137f63a6e060f12e2a7dcd59 | [
"Apache-2.0"
] | 47 | 2018-08-24T12:06:33.000Z | 2020-04-28T11:49:25.000Z | # Copyright 2019-2020 OMG Network Pte Ltd
#
# 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... | 31.479339 | 112 | 0.714098 |
62067a9bc5b0258f6617a20a33297dee646fd53c | 413 | exs | Elixir | test/winner_web/views/error_view_test.exs | manojsamanta/winner | 63293ff2f53e7dd271470bfb36498a303a2394b0 | [
"MIT"
] | null | null | null | test/winner_web/views/error_view_test.exs | manojsamanta/winner | 63293ff2f53e7dd271470bfb36498a303a2394b0 | [
"MIT"
] | null | null | null | test/winner_web/views/error_view_test.exs | manojsamanta/winner | 63293ff2f53e7dd271470bfb36498a303a2394b0 | [
"MIT"
] | null | null | null | defmodule WinnerWeb.ErrorViewTest do
use WinnerWeb.ConnCase, async: true
# Bring render/3 and render_to_string/3 for testing custom views
import Phoenix.View
test "renders 404.html" do
assert render_to_string(WinnerWeb.ErrorView, "404.html", []) == "Not Found"
end
test "renders 500.html" do
asser... | 27.533333 | 91 | 0.731235 |
62067d97b0307445b7671e0e383fc7379221f471 | 459 | ex | Elixir | lib/scheduler/scheduler_supervisor.ex | roi-levoso/erflow | e8683fd93720703ea706af8f2317376dba3b401f | [
"MIT"
] | null | null | null | lib/scheduler/scheduler_supervisor.ex | roi-levoso/erflow | e8683fd93720703ea706af8f2317376dba3b401f | [
"MIT"
] | null | null | null | lib/scheduler/scheduler_supervisor.ex | roi-levoso/erflow | e8683fd93720703ea706af8f2317376dba3b401f | [
"MIT"
] | null | null | null | defmodule Scheduler.SchedulerSupervisor do
use Supervisor
def start_link(init_arg) do
Supervisor.start_link(__MODULE__, init_arg, name: __MODULE__)
end
@impl true
def init(_init_arg) do
children = [
{Scheduler.JobSupervisor, name: Scheduler.JobSupervisor},
{Scheduler.Cron, name: Schedule... | 24.157895 | 65 | 0.72549 |
62068319c629d933ca07a1d3a084f67b14b7f262 | 1,827 | exs | Elixir | request-header/config/prod.exs | dalamilla/phoenix-projects | 52654fb0d3ff7d5b556569dac5c0863e230e3a00 | [
"MIT"
] | null | null | null | request-header/config/prod.exs | dalamilla/phoenix-projects | 52654fb0d3ff7d5b556569dac5c0863e230e3a00 | [
"MIT"
] | null | null | null | request-header/config/prod.exs | dalamilla/phoenix-projects | 52654fb0d3ff7d5b556569dac5c0863e230e3a00 | [
"MIT"
] | null | null | null | import Config
# For production, don't forget to configure the url host
# to something meaningful, Phoenix uses this information
# when generating URLs.
#
# Note we also include the path to a cache manifest
# containing the digested version of static files. This
# manifest is generated by the `mix phx.digest` task,
# w... | 35.823529 | 66 | 0.713191 |
6206b8d57e0c3d662bd860b67d8643d2450d7dd3 | 806 | ex | Elixir | lib/advent_of_code/day_13_b.ex | rob-brown/AdventOfCode2017 | cb8a56fba4b1999820b3aec4c4f03d7094836484 | [
"MIT"
] | 3 | 2017-12-26T20:51:47.000Z | 2019-05-14T04:59:38.000Z | lib/advent_of_code/day_13_b.ex | rob-brown/AdventOfCode2017 | cb8a56fba4b1999820b3aec4c4f03d7094836484 | [
"MIT"
] | null | null | null | lib/advent_of_code/day_13_b.ex | rob-brown/AdventOfCode2017 | cb8a56fba4b1999820b3aec4c4f03d7094836484 | [
"MIT"
] | null | null | null | defmodule AdventOfCode.Day13B do
def delay(input) do
input
|> Stream.reject(& &1 == "")
|> Stream.map(&String.trim/1)
|> Stream.map(& String.split &1, ": ")
|> Enum.map(fn x -> x |> Enum.map(&String.to_integer/1) |> List.to_tuple end)
|> attempt(0)
end
defp attempt(scanners, delay) do
... | 18.744186 | 81 | 0.548387 |
6206d012f8478f7bc0219b857c3c8656669657b1 | 3,111 | ex | Elixir | lib/logger_json/plug/metadata_formatters/google_cloud_logger.ex | wingyplus/logger_json | f60e1b750f24c8338d741e4307e7e68ae9a6212a | [
"MIT"
] | null | null | null | lib/logger_json/plug/metadata_formatters/google_cloud_logger.ex | wingyplus/logger_json | f60e1b750f24c8338d741e4307e7e68ae9a6212a | [
"MIT"
] | null | null | null | lib/logger_json/plug/metadata_formatters/google_cloud_logger.ex | wingyplus/logger_json | f60e1b750f24c8338d741e4307e7e68ae9a6212a | [
"MIT"
] | 1 | 2020-03-29T20:39:38.000Z | 2020-03-29T20:39:38.000Z | if Code.ensure_loaded?(Plug) do
defmodule LoggerJSON.Plug.MetadataFormatters.GoogleCloudLogger do
@moduledoc """
This formatter builds a metadata which is natively supported by Google Cloud Logger:
* `httpRequest` - see [LogEntry#HttpRequest](https://cloud.google.com/logging/docs/reference/v2/rest/v2/L... | 33.815217 | 132 | 0.648987 |
6206e264722121b342acd237596e85f616ec7027 | 207 | ex | Elixir | test/automated/support/async_case.ex | Carburetor/rill | 6ba477373cff28f56fbead9a316166d994da67d3 | [
"MIT"
] | 1 | 2022-01-26T15:06:14.000Z | 2022-01-26T15:06:14.000Z | test/automated/support/async_case.ex | rill-project/rill | 16d35f9dda1ec58190fa6bda9923372834ab456b | [
"MIT"
] | null | null | null | test/automated/support/async_case.ex | rill-project/rill | 16d35f9dda1ec58190fa6bda9923372834ab456b | [
"MIT"
] | null | null | null | defmodule AsyncCase do
defmacro __using__(opts) do
opts =
opts
|> Keyword.put_new(:async, true)
|> Macro.escape()
quote do
use ExUnit.Case, unquote(opts)
end
end
end
| 15.923077 | 38 | 0.603865 |
6206ed4e7dfb332639a874db4eb9975ba9040251 | 1,254 | exs | Elixir | mix.exs | darraghenright/surface | 6a6b1699f2f04c4f45686d96d48e33ab521423c9 | [
"MIT"
] | null | null | null | mix.exs | darraghenright/surface | 6a6b1699f2f04c4f45686d96d48e33ab521423c9 | [
"MIT"
] | null | null | null | mix.exs | darraghenright/surface | 6a6b1699f2f04c4f45686d96d48e33ab521423c9 | [
"MIT"
] | null | null | null | defmodule Surface.MixProject do
use Mix.Project
@version "0.1.0-alpha.1"
def project do
[
app: :surface,
version: @version,
elixir: "~> 1.7",
description: "A component based library for Phoenix LiveView",
elixirc_paths: elixirc_paths(Mix.env()),
start_permanent: Mix.env()... | 21.62069 | 68 | 0.54067 |
6206f2d9919b6c46456addbc5f6dc1e0af47f194 | 1,071 | ex | Elixir | lib/arkenston_web/channels/user_socket.ex | dolfinus/omicron-backend | dd3544a421ce8b05447fe72640f73f180549270f | [
"MIT"
] | 1 | 2019-04-29T18:07:08.000Z | 2019-04-29T18:07:08.000Z | lib/arkenston_web/channels/user_socket.ex | dolfinus/omicron-backend | dd3544a421ce8b05447fe72640f73f180549270f | [
"MIT"
] | 126 | 2020-12-03T15:39:31.000Z | 2022-03-30T22:02:23.000Z | lib/arkenston_web/channels/user_socket.ex | dolfinus/arkenston-backend | 258880936dce673eb15db0c4b52e68d3d40c58ff | [
"MIT"
] | null | null | null | defmodule ArkenstonWeb.UserSocket do
use Phoenix.Socket
## Channels
# channel "room:*", ArkenstonWeb.RoomChannel
# Socket params are passed from the client and can
# be used to verify and authenticate a user. After
# verification, you can put default assigns into
# the socket that will be set for all ch... | 31.5 | 84 | 0.698413 |
620703312ea1d499baaf336eaeb41fad1db1be53 | 311 | ex | Elixir | lib/hl7/2.1/segments/qrf.ex | calvinb/elixir-hl7 | 5e953fa11f9184857c0ec4dda8662889f35a6bec | [
"Apache-2.0"
] | null | null | null | lib/hl7/2.1/segments/qrf.ex | calvinb/elixir-hl7 | 5e953fa11f9184857c0ec4dda8662889f35a6bec | [
"Apache-2.0"
] | null | null | null | lib/hl7/2.1/segments/qrf.ex | calvinb/elixir-hl7 | 5e953fa11f9184857c0ec4dda8662889f35a6bec | [
"Apache-2.0"
] | null | null | null | defmodule HL7.V2_1.Segments.QRF do
@moduledoc false
require Logger
use HL7.Segment,
fields: [
segment: nil,
where_subject_filter: nil,
when_data_start_date_time: nil,
when_data_end_date_time: nil,
what_user_qualifier: nil,
other_qry_subject_filter: nil
]
end
| 19.4375 | 37 | 0.688103 |
62070e8835fef8041f5079d08bf379879bc7f606 | 1,020 | exs | Elixir | test/changelog_web/controllers/json_feed_controller_test.exs | type1fool/changelog.com | fbec3528cc3f5adfdc75b008bb92b17efc4f248f | [
"MIT"
] | 1 | 2020-05-20T16:58:17.000Z | 2020-05-20T16:58:17.000Z | test/changelog_web/controllers/json_feed_controller_test.exs | type1fool/changelog.com | fbec3528cc3f5adfdc75b008bb92b17efc4f248f | [
"MIT"
] | null | null | null | test/changelog_web/controllers/json_feed_controller_test.exs | type1fool/changelog.com | fbec3528cc3f5adfdc75b008bb92b17efc4f248f | [
"MIT"
] | null | null | null | defmodule ChangelogWeb.JsonFeedControllerTest do
use ChangelogWeb.ConnCase
alias ChangelogWeb.Helpers.SharedHelpers
test "the news feed", %{conn: conn} do
post = insert(:published_post, body: "zomg")
post_news_item = post |> post_news_item_with_story("**a story**") |> insert
episode = insert(:publis... | 39.230769 | 88 | 0.727451 |
62071f85f875cfafd4b8806d119a2130ef8ee604 | 254 | ex | Elixir | {{APP_NAME}}_umbrella/apps/{{APP_NAME}}_cms/lib/{{APP_NAME}}_cms/views/error_view.ex | Vorzious/Phoenix-Template | 7baa93c97047906afa2557fd0b0980a0bafd320d | [
"MIT"
] | null | null | null | {{APP_NAME}}_umbrella/apps/{{APP_NAME}}_cms/lib/{{APP_NAME}}_cms/views/error_view.ex | Vorzious/Phoenix-Template | 7baa93c97047906afa2557fd0b0980a0bafd320d | [
"MIT"
] | null | null | null | {{APP_NAME}}_umbrella/apps/{{APP_NAME}}_cms/lib/{{APP_NAME}}_cms/views/error_view.ex | Vorzious/Phoenix-Template | 7baa93c97047906afa2557fd0b0980a0bafd320d | [
"MIT"
] | null | null | null | defmodule {{MODULE_NAME}}Cms.ErrorView do
use {{MODULE_NAME}}Cms, :view
# In case no render clause matches or no
# template is found, let's render it as 500
def template_not_found(_template, assigns) do
render "500.html", assigns
end
end
| 23.090909 | 47 | 0.720472 |
620732764651c4c593852d2df916fa5f4e2c9c14 | 2,998 | ex | Elixir | lib/ecto_role/schema.supervisor.ex | fossabot/ecto-role | 083d5189833f2e333d12e07d23f7a1f4e9314afc | [
"MIT"
] | 2 | 2019-05-23T10:14:46.000Z | 2020-01-26T23:30:54.000Z | lib/ecto_role/schema.supervisor.ex | fossabot/ecto-role | 083d5189833f2e333d12e07d23f7a1f4e9314afc | [
"MIT"
] | 2 | 2018-01-28T22:00:20.000Z | 2018-04-16T17:35:35.000Z | lib/ecto_role/schema.supervisor.ex | fossabot/ecto-role | 083d5189833f2e333d12e07d23f7a1f4e9314afc | [
"MIT"
] | 2 | 2018-02-14T18:55:12.000Z | 2018-04-16T17:34:52.000Z | defmodule EctoRole.Schema.Supervisor do
use Supervisor
require Logger
alias EctoRole.Schema.Server, as: SS
alias EctoRole.Schema, as: SCHEMA
@moduledoc """
A Supervisor to Start and Manage your Schemas.
"""
@registry_name :ecto_role_schema_registry
def start_link do
Supervisor.start_link(__MO... | 19.854305 | 66 | 0.581388 |
62079b8b0bc40881923ad3811ff47a0616196b52 | 1,517 | exs | Elixir | test/commodity_api/iam/user/address/log/log_test.exs | akdilsiz/commodity-cloud | 08c366c9fc95fbb3565131672db4cc52f8b870c9 | [
"Apache-2.0"
] | 7 | 2019-04-11T21:12:49.000Z | 2021-04-14T12:56:42.000Z | test/commodity_api/iam/user/address/log/log_test.exs | akdilsiz/commodity-cloud | 08c366c9fc95fbb3565131672db4cc52f8b870c9 | [
"Apache-2.0"
] | null | null | null | test/commodity_api/iam/user/address/log/log_test.exs | akdilsiz/commodity-cloud | 08c366c9fc95fbb3565131672db4cc52f8b870c9 | [
"Apache-2.0"
] | 2 | 2019-06-06T18:05:33.000Z | 2019-07-16T08:49:45.000Z | ##
# Copyright 2018 Abdulkadir DILSIZ
#
# 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... | 29.173077 | 77 | 0.720501 |
62079eca2de38cd22bc1d916ee56485958c3f981 | 1,027 | exs | Elixir | test/qencode/client_test.exs | char0n/qencode | 22751a652e0af229b89e9b70498a0d36761c30e5 | [
"BSD-3-Clause"
] | 2 | 2019-07-03T11:51:39.000Z | 2019-08-06T15:34:34.000Z | test/qencode/client_test.exs | char0n/qencode | 22751a652e0af229b89e9b70498a0d36761c30e5 | [
"BSD-3-Clause"
] | 5 | 2019-07-19T17:34:09.000Z | 2019-11-04T10:59:11.000Z | test/qencode/client_test.exs | char0n/qencode | 22751a652e0af229b89e9b70498a0d36761c30e5 | [
"BSD-3-Clause"
] | null | null | null | defmodule Qencode.ClientTest do
@moduledoc false
alias Qencode.Client
use ExUnit.Case
doctest Qencode.Client
describe "given valid api_key" do
setup [:provide_api_key]
test "should return access token", %{api_key: api_key} do
client = Client.new!(api_key)
assert %{session_token: session... | 24.452381 | 61 | 0.689387 |
6207afbc9c9d9f8cbb51d5f99fa86f4bdb13a869 | 559 | ex | Elixir | lib/horde/process_canary.ex | amatalai/horde | b94c96e186450672279d40b754c36b80dea9e2b8 | [
"MIT"
] | null | null | null | lib/horde/process_canary.ex | amatalai/horde | b94c96e186450672279d40b754c36b80dea9e2b8 | [
"MIT"
] | null | null | null | lib/horde/process_canary.ex | amatalai/horde | b94c96e186450672279d40b754c36b80dea9e2b8 | [
"MIT"
] | null | null | null | defmodule Horde.ProcessCanary do
@moduledoc false
use GenServer
def child_spec(args) do
%{id: __MODULE__, start: {__MODULE__, :start_link, [args]}, shutdown: 1_000}
end
def start_link(args) do
GenServer.start_link(__MODULE__, args)
end
def init({child_spec, graceful_shutdown_manager}) do
P... | 24.304348 | 80 | 0.738819 |
6207cc4b54b36d8d45055db08500278926b8ec7a | 2,711 | ex | Elixir | lib/main.ex | xeejp/TheTragedyOfTheCommons | a674f24383a91125d25d9b6de55a4ae30750c305 | [
"MIT"
] | null | null | null | lib/main.ex | xeejp/TheTragedyOfTheCommons | a674f24383a91125d25d9b6de55a4ae30750c305 | [
"MIT"
] | 1 | 2016-12-27T02:06:06.000Z | 2016-12-27T02:06:06.000Z | lib/main.ex | xeejp/TheTragedyOfTheCommons | a674f24383a91125d25d9b6de55a4ae30750c305 | [
"MIT"
] | null | null | null | defmodule TragedyOfTheCommons.Main do
alias TragedyOfTheCommons.Host
alias TragedyOfTheCommons.Participant
require Logger
def init do
%{
is_first_visit: true,
page: "waiting",
joinable: true,
description: nil,
groups: %{},
participants: %{},
participants_number: 0... | 25.101852 | 104 | 0.576909 |
6207fca24454fdf1b9ef5b033010ee8473adf157 | 108 | exs | Elixir | apps/evm/test/evm/operation/exchange_test.exs | wolflee/mana | db66dac85addfaad98d40da5bd4082b3a0198bb1 | [
"ECL-2.0",
"Apache-2.0",
"MIT-0",
"MIT"
] | 152 | 2018-10-27T04:52:03.000Z | 2022-03-26T10:34:00.000Z | apps/evm/test/evm/operation/exchange_test.exs | wolflee/mana | db66dac85addfaad98d40da5bd4082b3a0198bb1 | [
"ECL-2.0",
"Apache-2.0",
"MIT-0",
"MIT"
] | 270 | 2018-04-14T07:34:57.000Z | 2018-10-25T18:10:45.000Z | apps/evm/test/evm/operation/exchange_test.exs | wolflee/mana | db66dac85addfaad98d40da5bd4082b3a0198bb1 | [
"ECL-2.0",
"Apache-2.0",
"MIT-0",
"MIT"
] | 25 | 2018-10-27T12:15:13.000Z | 2022-01-25T20:31:14.000Z | defmodule EVM.Operation.ExchangeTest do
use ExUnit.Case, async: true
doctest EVM.Operation.Exchange
end
| 21.6 | 39 | 0.805556 |
62080780630a394e117a69d5a408f2bb6ff56d36 | 2,352 | ex | Elixir | clients/content/lib/google_api/content/v21/model/test_order_line_item.ex | kaaboaye/elixir-google-api | 1896784c4342151fd25becd089a5beb323eff567 | [
"Apache-2.0"
] | null | null | null | clients/content/lib/google_api/content/v21/model/test_order_line_item.ex | kaaboaye/elixir-google-api | 1896784c4342151fd25becd089a5beb323eff567 | [
"Apache-2.0"
] | null | null | null | clients/content/lib/google_api/content/v21/model/test_order_line_item.ex | kaaboaye/elixir-google-api | 1896784c4342151fd25becd089a5beb323eff567 | [
"Apache-2.0"
] | null | null | null | # Copyright 2019 Google LLC
#
# 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, s... | 42 | 167 | 0.743197 |
6208680b87e533d57a3d5b77312300bbe10982c9 | 2,832 | exs | Elixir | exercises/robot-simulator/test/robot_simulator_test.exs | DuoPan/elixir | e96388f242c383c1f45935570ed2f42394171fc6 | [
"MIT"
] | 2 | 2019-07-09T05:23:38.000Z | 2019-07-29T01:39:59.000Z | exercises/robot-simulator/test/robot_simulator_test.exs | DuoPan/elixir | e96388f242c383c1f45935570ed2f42394171fc6 | [
"MIT"
] | null | null | null | exercises/robot-simulator/test/robot_simulator_test.exs | DuoPan/elixir | e96388f242c383c1f45935570ed2f42394171fc6 | [
"MIT"
] | null | null | null | defmodule RobotSimulatorTest do
use ExUnit.Case
test "create has sensible defaults" do
robot = RobotSimulator.create()
assert RobotSimulator.position(robot) == {0, 0}
assert RobotSimulator.direction(robot) == :north
end
@tag :pending
test "create works with valid arguments" do
robot = RobotS... | 37.76 | 93 | 0.70798 |
6208902b386719e5289078e2eb6de224bf091cd7 | 687 | ex | Elixir | kousa/lib/broth/router.ex | lazarospsa/dogehouse | 4400518f5b6bce929e40eada615356e8814a8d28 | [
"MIT"
] | 1 | 2021-03-25T12:35:40.000Z | 2021-03-25T12:35:40.000Z | kousa/lib/broth/router.ex | lazarospsa/dogehouse | 4400518f5b6bce929e40eada615356e8814a8d28 | [
"MIT"
] | 1 | 2022-03-25T19:20:22.000Z | 2022-03-25T19:20:22.000Z | kousa/lib/broth/router.ex | lazarospsa/dogehouse | 4400518f5b6bce929e40eada615356e8814a8d28 | [
"MIT"
] | 1 | 2021-03-19T13:04:24.000Z | 2021-03-19T13:04:24.000Z | defmodule Broth do
import Plug.Conn
alias Broth.Routes.GitHubAuth
alias Broth.Routes.TwitterAuth
alias Broth.Routes.ScheduledRoom
alias Broth.Routes.Dev
use Plug.Router
use Sentry.PlugCapture
plug(Broth.Plugs.Cors)
plug(Kousa.Metric.PrometheusExporter)
plug(:match)
plug(:dispatch)
options _ d... | 18.567568 | 47 | 0.673945 |
6208a08daf84d0b424b8d0b31f8e59431d921f04 | 302 | ex | Elixir | lib/librecov/helpers/happy.ex | yknx4/opencov | dc961a41e29b41b0657bc2a64bb67350a65477b8 | [
"MIT"
] | 8 | 2021-08-22T10:37:57.000Z | 2022-01-10T11:27:06.000Z | lib/librecov/helpers/happy.ex | yknx4/librecov | dc961a41e29b41b0657bc2a64bb67350a65477b8 | [
"MIT"
] | 109 | 2021-08-20T04:08:04.000Z | 2022-01-03T07:39:18.000Z | lib/librecov/helpers/happy.ex | Librecov/librecov | dc961a41e29b41b0657bc2a64bb67350a65477b8 | [
"MIT"
] | null | null | null | defmodule Librecov.Helpers.Happy do
@doc """
Unwraps any tuple.
## Examples
iex> Librecov.Helpers.Happy.unwrap({:ok, "foo"})
"foo"
iex> Librecov.Helpers.Happy.unwrap({:ok, "foo", 1})
"foo"
"""
def unwrap({_, bool}),
do: bool
def unwrap({_, bool, _}),
do: bool
end
| 17.764706 | 55 | 0.582781 |
6208a23be7f05b2437778d22a63f8da109fe28a5 | 186 | ex | Elixir | lib/spear/records/streams.ex | NFIBrokerage/spear | 611223d2cdba97daa63f2ddd81a08b4f55e72198 | [
"Apache-2.0"
] | 34 | 2021-04-15T22:16:38.000Z | 2022-03-11T10:20:11.000Z | lib/spear/records/streams.ex | NFIBrokerage/spear | 611223d2cdba97daa63f2ddd81a08b4f55e72198 | [
"Apache-2.0"
] | 32 | 2021-04-05T18:07:35.000Z | 2021-11-04T19:32:58.000Z | lib/spear/records/streams.ex | NFIBrokerage/spear | 611223d2cdba97daa63f2ddd81a08b4f55e72198 | [
"Apache-2.0"
] | 1 | 2021-10-11T15:53:42.000Z | 2021-10-11T15:53:42.000Z | defmodule Spear.Records.Streams do
@moduledoc """
A record macro interface for interacting with the EventStoreDB Streams API
"""
use Spear.Records, service_module: :streams
end
| 23.25 | 76 | 0.763441 |
6208bea480d52f4e612e12a3a0d4a2f6712e39f0 | 101 | exs | Elixir | test/conduit/plug/ack_exception_test.exs | peek-travel/conduit | f37b96513769bdf70c89eebd77bb03023d248158 | [
"MIT"
] | 119 | 2016-11-21T13:19:22.000Z | 2021-11-07T17:29:05.000Z | test/conduit/plug/ack_exception_test.exs | peek-travel/conduit | f37b96513769bdf70c89eebd77bb03023d248158 | [
"MIT"
] | 104 | 2018-02-02T20:42:46.000Z | 2021-08-03T05:36:09.000Z | test/conduit/plug/ack_exception_test.exs | peek-travel/conduit | f37b96513769bdf70c89eebd77bb03023d248158 | [
"MIT"
] | 21 | 2018-08-03T02:38:21.000Z | 2022-03-16T18:26:58.000Z | defmodule Conduit.Plug.AckExceptionTest do
use ExUnit.Case
doctest Conduit.Plug.AckException
end
| 20.2 | 42 | 0.831683 |
6208de880de48274128bff9d731e211fd6908c4d | 597 | ex | Elixir | backend/lib/caffe_web/schema/context.ex | eeng/caffe | d85d0dd56a8204c715052ddaf3d990e47c5df0e9 | [
"MIT"
] | 7 | 2020-03-27T08:26:52.000Z | 2021-08-29T09:50:31.000Z | backend/lib/caffe_web/schema/context.ex | eeng/caffe | d85d0dd56a8204c715052ddaf3d990e47c5df0e9 | [
"MIT"
] | null | null | null | backend/lib/caffe_web/schema/context.ex | eeng/caffe | d85d0dd56a8204c715052ddaf3d990e47c5df0e9 | [
"MIT"
] | null | null | null | defmodule CaffeWeb.Schema.Context do
@behaviour Plug
import Plug.Conn
def init(opts), do: opts
def call(conn, _) do
context = build_context(conn)
Absinthe.Plug.put_options(conn, context: context)
end
defp build_context(conn) do
with ["Bearer " <> token] <- get_req_header(conn, "authorization"... | 22.961538 | 71 | 0.648241 |
6208f9a290ad86dc6b39a4b7625eb43a61bf99aa | 646 | ex | Elixir | chromoid_web/lib/chromoid_discord/guild_supervisor.ex | ConnorRigby/chromoid | 6424a9234227d18d7c287ded869caeb31511bb97 | [
"Apache-2.0"
] | 7 | 2020-11-18T11:29:20.000Z | 2022-01-16T03:16:14.000Z | chromoid_web/lib/chromoid_discord/guild_supervisor.ex | ConnorRigby/chromoid | 6424a9234227d18d7c287ded869caeb31511bb97 | [
"Apache-2.0"
] | null | null | null | chromoid_web/lib/chromoid_discord/guild_supervisor.ex | ConnorRigby/chromoid | 6424a9234227d18d7c287ded869caeb31511bb97 | [
"Apache-2.0"
] | 1 | 2021-01-06T15:40:46.000Z | 2021-01-06T15:40:46.000Z | defmodule ChromoidDiscord.GuildSupervisor do
@moduledoc "Interface for starting supervised guilds"
use DynamicSupervisor
@doc false
def start_link(args) do
DynamicSupervisor.start_link(__MODULE__, args, name: __MODULE__)
end
@doc "Starts a Guild instance. Should be called from the Event source"
def... | 28.086957 | 72 | 0.764706 |
62090712716671760ddf91f004fb8c9c58b1da34 | 82 | exs | Elixir | test/views/page_view_test.exs | kenta-aktsk/media_sample | a0368236bd81c18ac136a54aa7383332a5e3cf36 | [
"MIT"
] | 99 | 2016-04-19T11:11:57.000Z | 2021-12-12T14:38:02.000Z | test/views/page_view_test.exs | ogamw/media_sample | a0368236bd81c18ac136a54aa7383332a5e3cf36 | [
"MIT"
] | 48 | 2016-04-06T02:28:46.000Z | 2016-05-31T06:56:56.000Z | test/views/page_view_test.exs | ogamw/media_sample | a0368236bd81c18ac136a54aa7383332a5e3cf36 | [
"MIT"
] | 32 | 2016-04-19T11:12:00.000Z | 2021-03-25T18:19:52.000Z | defmodule MediaSample.PageViewTest do
use MediaSample.ConnCase, async: true
end
| 20.5 | 39 | 0.829268 |
620934196b1d3ce4f6dfe19f22514a8b0c081cdc | 1,201 | ex | Elixir | lib/hexa_web/controllers/h3tmap_controller.ex | libreearth/hexa | 81938c3a5abc710eb16055d73c43cbf60dbf487e | [
"MIT"
] | null | null | null | lib/hexa_web/controllers/h3tmap_controller.ex | libreearth/hexa | 81938c3a5abc710eb16055d73c43cbf60dbf487e | [
"MIT"
] | null | null | null | lib/hexa_web/controllers/h3tmap_controller.ex | libreearth/hexa | 81938c3a5abc710eb16055d73c43cbf60dbf487e | [
"MIT"
] | null | null | null | defmodule HexaWeb.H3tMapController do
use HexaWeb, :controller
alias Hexa.ImageLibrary
@zooms %{
"0" => 0,
"1" => 1,
"2" => 2,
"3" => 2,
"4" => 3,
"5" => 4,
"6" => 4,
"7" => 5,
"8" => 5,
"9" => 6,
"10" => 7,
"11" => 8,
"12" => 8,
"13" => 9,
"14" => 9,
... | 17.661765 | 103 | 0.49542 |
62095b40b91759e1d1149a093567d90df36fa8ce | 239 | exs | Elixir | priv/repo/migrations/20150715104728_jobs_bigint.exs | houshuang/survey | 948acaf20840af82af1d9af3147acca94cb4fcf8 | [
"Apache-2.0"
] | 48 | 2015-06-29T21:20:25.000Z | 2021-05-09T04:27:41.000Z | priv/repo/migrations/20150715104728_jobs_bigint.exs | houshuang/survey | 948acaf20840af82af1d9af3147acca94cb4fcf8 | [
"Apache-2.0"
] | null | null | null | priv/repo/migrations/20150715104728_jobs_bigint.exs | houshuang/survey | 948acaf20840af82af1d9af3147acca94cb4fcf8 | [
"Apache-2.0"
] | 15 | 2015-06-29T21:13:57.000Z | 2021-07-27T10:02:40.000Z | defmodule Survey.Repo.Migrations.JobsBigint do
use Ecto.Migration
def change do
alter table(:jobs) do
remove :next_try
remove :checked_out
add :next_try, :bigint
add :checked_out, :bigint
end
end
end
| 18.384615 | 46 | 0.67364 |
620965790872becd0cb5c363365af5d01dc7ae6c | 1,110 | exs | Elixir | clients/os_login/mix.exs | chingor13/elixir-google-api | 85e13fa25c4c9f4618bb463ab4c79245fc6d2a7b | [
"Apache-2.0"
] | 1 | 2018-12-03T23:43:10.000Z | 2018-12-03T23:43:10.000Z | clients/os_login/mix.exs | chingor13/elixir-google-api | 85e13fa25c4c9f4618bb463ab4c79245fc6d2a7b | [
"Apache-2.0"
] | null | null | null | clients/os_login/mix.exs | chingor13/elixir-google-api | 85e13fa25c4c9f4618bb463ab4c79245fc6d2a7b | [
"Apache-2.0"
] | null | null | null | defmodule GoogleApi.OSLogin.V1alpha.Mixfile do
use Mix.Project
@version "0.8.0"
def project do
[app: :google_api_os_login,
version: @version,
elixir: "~> 1.4",
build_embedded: Mix.env == :prod,
start_permanent: Mix.env == :prod,
description: description(),
package: package(),
... | 23.125 | 108 | 0.6 |
620985132d56f3cf0079faaa522d6a8dd26e930b | 872 | ex | Elixir | lib/mix/lib/mix/tasks/deps.clean.ex | joearms/elixir | 9a0f8107bd8bbd089acb96fe0041d61a05e88a9b | [
"Apache-2.0"
] | 4 | 2016-04-05T05:51:36.000Z | 2019-10-31T06:46:35.000Z | lib/mix/lib/mix/tasks/deps.clean.ex | joearms/elixir | 9a0f8107bd8bbd089acb96fe0041d61a05e88a9b | [
"Apache-2.0"
] | null | null | null | lib/mix/lib/mix/tasks/deps.clean.ex | joearms/elixir | 9a0f8107bd8bbd089acb96fe0041d61a05e88a9b | [
"Apache-2.0"
] | 5 | 2015-02-01T06:01:19.000Z | 2019-08-29T09:02:35.000Z | defmodule Mix.Tasks.Deps.Clean do
use Mix.Task
@shortdoc "Remove dependencies files"
@recursive true
@moduledoc """
Clean dependencies.
By default, cleans all dependencies. A list of deps can
be given to clean specific ones. Clean does not unlock
the repositories, unless --unlock is given.
"""
i... | 23.567568 | 68 | 0.641055 |
62099145d97d2eea21c68803b22713af264d8274 | 268 | ex | Elixir | elixir/elixir-sips/samples/exactor_test/lib/count_actor.ex | afronski/playground-erlang | 6ac4b58b2fd717260c22a33284547d44a9b5038e | [
"MIT"
] | 2 | 2015-12-09T02:16:51.000Z | 2021-07-26T22:53:43.000Z | elixir/elixir-sips/samples/exactor_test/lib/count_actor.ex | afronski/playground-erlang | 6ac4b58b2fd717260c22a33284547d44a9b5038e | [
"MIT"
] | null | null | null | elixir/elixir-sips/samples/exactor_test/lib/count_actor.ex | afronski/playground-erlang | 6ac4b58b2fd717260c22a33284547d44a9b5038e | [
"MIT"
] | 1 | 2016-05-08T18:40:31.000Z | 2016-05-08T18:40:31.000Z | defmodule CountActor do
use ExActor.GenServer, export: :counter
defstart start(x), do: initial_state(x)
defcall get, state: state, do: reply(state)
defcast inc, state: state, do: new_state(state + 1)
defcast dec, state: state, do: new_state(state - 1)
end
| 26.8 | 53 | 0.716418 |
620991e1ea7907b9c286b3e35dcc2f1171dbd67f | 2,143 | ex | Elixir | clients/dataflow/lib/google_api/dataflow/v1b3/model/side_input_info.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2021-12-20T03:40:53.000Z | 2021-12-20T03:40:53.000Z | clients/dataflow/lib/google_api/dataflow/v1b3/model/side_input_info.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2020-08-18T00:11:23.000Z | 2020-08-18T00:44:16.000Z | clients/dataflow/lib/google_api/dataflow/v1b3/model/side_input_info.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | null | null | null | # Copyright 2019 Google LLC
#
# 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, s... | 40.433962 | 312 | 0.715819 |
62099ce56f16736c41022783ba5b780e478b2afc | 2,241 | exs | Elixir | test/test_helper.exs | phaleth/wasmex | 6fdb790c5dbbe229e12db71629b3a58ea9bbbf9f | [
"MIT"
] | 243 | 2020-01-15T11:36:36.000Z | 2022-03-30T09:38:04.000Z | test/test_helper.exs | phaleth/wasmex | 6fdb790c5dbbe229e12db71629b3a58ea9bbbf9f | [
"MIT"
] | 255 | 2020-01-16T00:00:16.000Z | 2022-03-29T10:05:52.000Z | test/test_helper.exs | phaleth/wasmex | 6fdb790c5dbbe229e12db71629b3a58ea9bbbf9f | [
"MIT"
] | 11 | 2020-04-24T14:57:33.000Z | 2022-03-25T12:04:40.000Z | defmodule TestHelper do
@ets_table __MODULE__
@wasm_test_source_dir "#{Path.dirname(__ENV__.file)}/wasm_test"
@wasm_import_test_source_dir "#{Path.dirname(__ENV__.file)}/wasm_import_test"
@wasi_test_source_dir "#{Path.dirname(__ENV__.file)}/wasi_test"
def wasm_test_file_path,
do: "#{@wasm_test_source_di... | 38.637931 | 96 | 0.695672 |
6209b282664c4a6f27c53e97b0cdeededc6c7c23 | 1,278 | ex | Elixir | lib/radex/writer/json/index.ex | smartlogic/radex | 001d2b6fc564d9fbcbd98fcffdc89a03dc210c80 | [
"MIT"
] | 3 | 2017-10-12T18:23:33.000Z | 2019-05-14T21:28:09.000Z | lib/radex/writer/json/index.ex | smartlogic/radex | 001d2b6fc564d9fbcbd98fcffdc89a03dc210c80 | [
"MIT"
] | null | null | null | lib/radex/writer/json/index.ex | smartlogic/radex | 001d2b6fc564d9fbcbd98fcffdc89a03dc210c80 | [
"MIT"
] | null | null | null | defmodule Radex.Writer.JSON.Index do
@moduledoc """
Generate the index file
"""
alias Radex.Writer
alias Radex.Writer.Index
@behaviour Index
@doc """
Write the index
"""
@spec write(map, path :: Path.t()) :: :ok
@impl Radex.Writer.Index
def write(metadata, path) do
File.mkdir_p(path)
... | 22.421053 | 88 | 0.640063 |
6209dee57cc2f89a5b5216e6b264f09316e4c9da | 21,897 | ex | Elixir | deps/timex/lib/parse/datetime/parser.ex | robot-overlord/starter_kit | 254153221d0a3a06324c65ad8e89d610de2429c3 | [
"MIT"
] | 1 | 2020-01-31T10:23:37.000Z | 2020-01-31T10:23:37.000Z | deps/timex/lib/parse/datetime/parser.ex | robot-overlord/starter_kit | 254153221d0a3a06324c65ad8e89d610de2429c3 | [
"MIT"
] | null | null | null | deps/timex/lib/parse/datetime/parser.ex | robot-overlord/starter_kit | 254153221d0a3a06324c65ad8e89d610de2429c3 | [
"MIT"
] | null | null | null | defmodule Timex.Parse.DateTime.Parser do
@moduledoc """
This is the base plugin behavior for all Timex date/time string parsers.
"""
import Combine.Parsers.Base, only: [eof: 0, map: 2, pipe: 2]
alias Timex.{Timezone, TimezoneInfo, AmbiguousDateTime, AmbiguousTimezoneInfo}
alias Timex.Parse.ParseError
ali... | 41.708571 | 134 | 0.4971 |
6209eca19e15fb522b53eeddd472d1624f0a2265 | 1,651 | exs | Elixir | config/config.exs | sleipnir/permastate-operator | 3937ac749bb5d65a30c690dffec88d6f55371946 | [
"Apache-2.0"
] | 2 | 2021-04-13T20:30:04.000Z | 2021-04-21T22:26:07.000Z | config/config.exs | sleipnir/permastate-operator | 3937ac749bb5d65a30c690dffec88d6f55371946 | [
"Apache-2.0"
] | 6 | 2021-06-02T03:25:37.000Z | 2021-07-20T14:00:09.000Z | config/config.exs | sleipnir/permastate-operator | 3937ac749bb5d65a30c690dffec88d6f55371946 | [
"Apache-2.0"
] | 2 | 2021-06-02T03:36:05.000Z | 2021-07-19T21:05:43.000Z | use Mix.Config
config :logger, level: :debug
if Mix.env() == :dev do
config :k8s,
clusters: %{
default: %{
conf: "~/.kube/config",
conf_opts: [context: "kind-default"]
}
}
config :bonny,
cluster_name: :default
end
if Mix.env() == :prod do
config :k8s,
clusters: %{
... | 25.796875 | 105 | 0.661417 |
6209f24f8d17cbc548808bfb540d38c0f2fc5aec | 2,101 | exs | Elixir | test/yacto/yacto_test.exs | aman-io/yacto | 4c26772343a9029923ad7e25245f17f2be22a1a1 | [
"Apache-2.0"
] | 56 | 2017-11-30T02:07:07.000Z | 2022-02-16T17:38:42.000Z | test/yacto/yacto_test.exs | aman-io/yacto | 4c26772343a9029923ad7e25245f17f2be22a1a1 | [
"Apache-2.0"
] | 22 | 2018-01-04T00:34:51.000Z | 2021-08-01T06:52:10.000Z | test/yacto/yacto_test.exs | aman-io/yacto | 4c26772343a9029923ad7e25245f17f2be22a1a1 | [
"Apache-2.0"
] | 13 | 2018-08-08T05:32:42.000Z | 2021-07-30T14:57:35.000Z | defmodule YactoTest do
use PowerAssert
@databases %{
default: %{module: Yacto.DB.Single, repo: Yacto.QueryTest.Repo.Default},
player: %{
module: Yacto.DB.Shard,
repos: [Yacto.QueryTest.Repo.Player0, Yacto.QueryTest.Repo.Player1]
}
}
setup_all do
default_config = [
database: "... | 24.149425 | 96 | 0.609234 |
620a3f99a0a2f52f865d6ea2b8b38061b929700c | 1,394 | ex | Elixir | test/support/data_case.ex | flowr-app/flowr | 1e88bc917da32df2878e13c9bb1998dbbe61cd62 | [
"0BSD"
] | 2 | 2021-08-01T04:38:08.000Z | 2021-08-01T06:52:29.000Z | test/support/data_case.ex | flowr-app/flowr | 1e88bc917da32df2878e13c9bb1998dbbe61cd62 | [
"0BSD"
] | 3 | 2021-08-01T08:20:13.000Z | 2021-08-01T08:22:07.000Z | test/support/data_case.ex | flowr-app/flowr | 1e88bc917da32df2878e13c9bb1998dbbe61cd62 | [
"0BSD"
] | null | null | null | defmodule Flowr.DataCase do
@moduledoc """
This module defines the setup for tests requiring
access to the application's data layer.
You may define functions here to be used as helpers in
your tests.
Finally, if the test case interacts with the database,
it cannot be async. For this reason, every test r... | 25.814815 | 77 | 0.677188 |
620a41f2c2fbe156031db28bf6527f9409bfacb2 | 1,005 | exs | Elixir | capitulo-11/app/test/weather_test.exs | mdcg/elixir_do_zero_a_concorrencia | 769bfa810f3d4359a969dadd3dc1bca8619ef940 | [
"MIT"
] | null | null | null | capitulo-11/app/test/weather_test.exs | mdcg/elixir_do_zero_a_concorrencia | 769bfa810f3d4359a969dadd3dc1bca8619ef940 | [
"MIT"
] | null | null | null | capitulo-11/app/test/weather_test.exs | mdcg/elixir_do_zero_a_concorrencia | 769bfa810f3d4359a969dadd3dc1bca8619ef940 | [
"MIT"
] | null | null | null | defmodule App.Weather.Test do
use ExUnit.Case, async: true
@api "http://api.openweathermap.org/data/2.5/weather?q="
test "should return a encoded endpoint when take a location" do
appid = App.Weather.get_appid()
endpoint = App.Weather.get_endpoint("Rio de Janeiro")
assert "#{@api}... | 30.454545 | 70 | 0.672637 |
620a4ff6607dc8cbf42592b50f0f83ba4f6e0596 | 1,170 | ex | Elixir | web/channels/user_socket.ex | wojtekmach/mr-rebase | d7265a1a672de6c6c68b1f7a884ead13aed9428f | [
"MIT"
] | 2 | 2016-01-03T08:36:55.000Z | 2016-01-03T21:00:52.000Z | web/channels/user_socket.ex | wojtekmach/mr-rebase | d7265a1a672de6c6c68b1f7a884ead13aed9428f | [
"MIT"
] | null | null | null | web/channels/user_socket.ex | wojtekmach/mr-rebase | d7265a1a672de6c6c68b1f7a884ead13aed9428f | [
"MIT"
] | null | null | null | defmodule MrRebase.UserSocket do
use Phoenix.Socket
## Channels
# channel "rooms:*", MrRebase.RoomChannel
## Transports
transport :websocket, Phoenix.Transports.WebSocket
# transport :longpoll, Phoenix.Transports.LongPoll
# Socket params are passed from the client and can
# be used to verify and auth... | 30.789474 | 83 | 0.702564 |
620a5fd9563c4813a18c49d67f0bc884ef9e8ab9 | 1,796 | exs | Elixir | apps/omg_utils/test/omg_utils/remote_ip_test.exs | omisego/elixir-omg | 2c68973d8f29033d137f63a6e060f12e2a7dcd59 | [
"Apache-2.0"
] | 177 | 2018-08-24T03:51:02.000Z | 2020-05-30T13:29:25.000Z | apps/omg_utils/test/omg_utils/remote_ip_test.exs | omisego/elixir-omg | 2c68973d8f29033d137f63a6e060f12e2a7dcd59 | [
"Apache-2.0"
] | 1,042 | 2018-08-25T00:52:39.000Z | 2020-06-01T05:15:17.000Z | apps/omg_utils/test/omg_utils/remote_ip_test.exs | omisego/elixir-omg | 2c68973d8f29033d137f63a6e060f12e2a7dcd59 | [
"Apache-2.0"
] | 47 | 2018-08-24T12:06:33.000Z | 2020-04-28T11:49:25.000Z | # Copyright 2019-2020 OMG Network Pte Ltd
#
# 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... | 27.630769 | 74 | 0.654788 |
620a68f06500c91310a3f701f252ddb4dcc3bf20 | 1,565 | exs | Elixir | test/smarty_test.exs | aforward-oss/earmark | b44d4817aa2b4047b07f91d633ae83ed27c695ed | [
"Apache-2.0"
] | 2 | 2018-02-11T01:18:24.000Z | 2020-01-12T17:19:22.000Z | test/smarty_test.exs | aforward-oss/earmark | b44d4817aa2b4047b07f91d633ae83ed27c695ed | [
"Apache-2.0"
] | null | null | null | test/smarty_test.exs | aforward-oss/earmark | b44d4817aa2b4047b07f91d633ae83ed27c695ed | [
"Apache-2.0"
] | 1 | 2020-09-15T17:47:35.000Z | 2020-09-15T17:47:35.000Z | defmodule SmartyTest do
use ExUnit.Case
import Support.Helpers
############################################################
# Quotes #
############################################################
test "paired single" do
result = convert_pedantic("a 's... | 29.528302 | 109 | 0.554633 |
620a7ddf319fff3c58376f220657c357720b93d6 | 622 | ex | Elixir | lib/teiserver/telemetry/schemas/match_day_log.ex | badosu/teiserver | 19b623aeb7c2ab28756405f7486e92b714777c54 | [
"MIT"
] | 4 | 2021-07-29T16:23:20.000Z | 2022-02-23T05:34:36.000Z | lib/teiserver/telemetry/schemas/match_day_log.ex | badosu/teiserver | 19b623aeb7c2ab28756405f7486e92b714777c54 | [
"MIT"
] | 14 | 2021-08-01T02:36:14.000Z | 2022-01-30T21:15:03.000Z | lib/teiserver/telemetry/schemas/match_day_log.ex | badosu/teiserver | 19b623aeb7c2ab28756405f7486e92b714777c54 | [
"MIT"
] | 7 | 2021-05-13T12:55:28.000Z | 2022-01-14T06:39:06.000Z | defmodule Teiserver.Telemetry.MatchDayLog do
use CentralWeb, :schema
@primary_key false
schema "teiserver_match_day_logs" do
field :date, :date, primary_key: true
field :data, :map
end
@doc """
Builds a changeset based on the `struct` and `params`.
"""
@spec changeset(Map.t(), Map.t()) :: Ecto... | 27.043478 | 86 | 0.660772 |
620a99c3e307e2ecae4a2d4a2531f7a5a1518887 | 63 | ex | Elixir | lib/rackit/repo.ex | Cobenian/rackit | e886ebbf1a590d4031d5f79f868ce2d725e9910a | [
"Apache-2.0"
] | null | null | null | lib/rackit/repo.ex | Cobenian/rackit | e886ebbf1a590d4031d5f79f868ce2d725e9910a | [
"Apache-2.0"
] | 6 | 2015-06-10T13:33:57.000Z | 2015-06-10T14:10:06.000Z | lib/rackit/repo.ex | Cobenian/rackit | e886ebbf1a590d4031d5f79f868ce2d725e9910a | [
"Apache-2.0"
] | null | null | null | defmodule Rackit.Repo do
use Ecto.Repo, otp_app: :rackit
end
| 15.75 | 33 | 0.761905 |
620a9d269675509f47e57451d0227f3bfab1c12c | 927 | exs | Elixir | test/mix.exs | Premwoik/rpi3_base | 01e4e5e7c9e18384355ed044b01855cf1e5b24fb | [
"Apache-2.0"
] | 2 | 2018-11-27T15:42:45.000Z | 2018-12-18T16:37:57.000Z | test/mix.exs | Premwoik/rpi3_base | 01e4e5e7c9e18384355ed044b01855cf1e5b24fb | [
"Apache-2.0"
] | null | null | null | test/mix.exs | Premwoik/rpi3_base | 01e4e5e7c9e18384355ed044b01855cf1e5b24fb | [
"Apache-2.0"
] | 1 | 2018-12-20T06:04:15.000Z | 2018-12-20T06:04:15.000Z | if Mix.env() == :test do
hash =
:os.cmd('git rev-parse HEAD')
|> to_string
|> String.trim()
System.put_env("NERVES_FW_VCS_IDENTIFIER", hash)
end
defmodule Test.MixProject do
use Mix.Project
def project do
[
app: :test,
version: "0.1.0",
elixir: "~> 1.6",
archives: [ner... | 22.071429 | 72 | 0.619202 |
620ae0d385ef36adecb59b4293b40253d978e0ad | 422 | ex | Elixir | lib/blog/comments/comment.ex | etori-sangiacomo/blog | 6b7548d6dd5de4ba46803ae21f143644ef36ef41 | [
"MIT"
] | null | null | null | lib/blog/comments/comment.ex | etori-sangiacomo/blog | 6b7548d6dd5de4ba46803ae21f143644ef36ef41 | [
"MIT"
] | 9 | 2020-07-22T10:19:52.000Z | 2020-12-13T02:27:02.000Z | lib/blog/comments/comment.ex | theguuholi/blog | 36152d03012d163d76520cf57c51783828d14317 | [
"MIT"
] | null | null | null | defmodule Blog.Comments.Comment do
use Ecto.Schema
import Ecto.Changeset
@derive {Jason.Encoder, only: [:content, :user]}
schema "comments" do
field :content, :string
belongs_to :post, Blog.Posts.Post
belongs_to :user, Blog.Accounts.User
timestamps()
end
@doc false
def changeset(comment... | 20.095238 | 50 | 0.677725 |
620b0b83ca0b7d5d6e2f255b68e9f72662d39148 | 774 | ex | Elixir | implementations/elixir/ockam/ockam_hub/lib/hub/log_formatter.ex | twittner/ockam | 96eadf99da42f7c35539c6e29010a657c579ccba | [
"Apache-2.0"
] | null | null | null | implementations/elixir/ockam/ockam_hub/lib/hub/log_formatter.ex | twittner/ockam | 96eadf99da42f7c35539c6e29010a657c579ccba | [
"Apache-2.0"
] | null | null | null | implementations/elixir/ockam/ockam_hub/lib/hub/log_formatter.ex | twittner/ockam | 96eadf99da42f7c35539c6e29010a657c579ccba | [
"Apache-2.0"
] | null | null | null | defmodule Ockam.Hub.LogFormatter do
@moduledoc """
Formats lines using Logger.Formatter, but replaces line breaks in log messages with `\n`
Config:
`:format_string` in logger config - pattern to format log with
Usage:
config :logger, :console,
format: {Ockam.Hub.LogFormatter, :format} # Use this forma... | 32.25 | 90 | 0.700258 |
620b4975396d832fc287e0db137e6b7659f97c0b | 86 | exs | Elixir | test/views/page_view_test.exs | nihonjinrxs/VolunteerBase | e555ec9ae1d0b4401ae33c0a9fdc411b855f04a4 | [
"MIT"
] | null | null | null | test/views/page_view_test.exs | nihonjinrxs/VolunteerBase | e555ec9ae1d0b4401ae33c0a9fdc411b855f04a4 | [
"MIT"
] | 1 | 2016-06-24T03:43:06.000Z | 2016-06-24T03:43:06.000Z | test/views/page_view_test.exs | nihonjinrxs/VolunteerBase | e555ec9ae1d0b4401ae33c0a9fdc411b855f04a4 | [
"MIT"
] | null | null | null | defmodule Volunteerbase.PageViewTest do
use Volunteerbase.ConnCase, async: true
end
| 21.5 | 41 | 0.837209 |
620b545ed2478721720781e7405d3068aaaab951 | 913 | ex | Elixir | lib/exdis/listener.ex | g-andrade/exdis | 6cb6775b16a237718f10dc5177d9369279e2d528 | [
"MIT"
] | 2 | 2020-03-20T17:25:59.000Z | 2020-03-22T14:17:30.000Z | lib/exdis/listener.ex | g-andrade/exdis | 6cb6775b16a237718f10dc5177d9369279e2d528 | [
"MIT"
] | null | null | null | lib/exdis/listener.ex | g-andrade/exdis | 6cb6775b16a237718f10dc5177d9369279e2d528 | [
"MIT"
] | null | null | null | defmodule Exdis.Listener do
## ------------------------------------------------------------------
## Macro-like Attribute Definitions
## ------------------------------------------------------------------
@listener_ref __MODULE__
## ------------------------------------------------------------------
## Publ... | 30.433333 | 71 | 0.485214 |
620b5d667ead95657e747d1b4f62061d22f29fe3 | 1,471 | ex | Elixir | clients/document_ai/lib/google_api/document_ai/v1/model/google_cloud_documentai_v1_disable_processor_response.ex | renovate-bot/elixir-google-api | 1da34cd39b670c99f067011e05ab90af93fef1f6 | [
"Apache-2.0"
] | 1 | 2021-12-20T03:40:53.000Z | 2021-12-20T03:40:53.000Z | clients/document_ai/lib/google_api/document_ai/v1/model/google_cloud_documentai_v1_disable_processor_response.ex | swansoffiee/elixir-google-api | 9ea6d39f273fb430634788c258b3189d3613dde0 | [
"Apache-2.0"
] | 1 | 2020-08-18T00:11:23.000Z | 2020-08-18T00:44:16.000Z | clients/document_ai/lib/google_api/document_ai/v1/model/google_cloud_documentai_v1_disable_processor_response.ex | dazuma/elixir-google-api | 6a9897168008efe07a6081d2326735fe332e522c | [
"Apache-2.0"
] | null | null | null | # Copyright 2019 Google LLC
#
# 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, s... | 31.297872 | 107 | 0.774303 |
620b7bb0b0afd64b0f96a88ae0330106eab3d5a5 | 2,035 | ex | Elixir | clients/display_video/lib/google_api/display_video/v1/model/viewability_assigned_targeting_option_details.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2021-12-20T03:40:53.000Z | 2021-12-20T03:40:53.000Z | clients/display_video/lib/google_api/display_video/v1/model/viewability_assigned_targeting_option_details.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2020-08-18T00:11:23.000Z | 2020-08-18T00:44:16.000Z | clients/display_video/lib/google_api/display_video/v1/model/viewability_assigned_targeting_option_details.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | null | null | null | # Copyright 2019 Google LLC
#
# 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, s... | 37 | 234 | 0.753808 |
620bb87e955f126823a8ad994a97c10a6134d4f2 | 2,106 | exs | Elixir | test/mix/phoenix_test.exs | angwoontiong/phoenix-ui | 03227b13f3c780b5626d56207bfa99c8a06525d8 | [
"MIT"
] | null | null | null | test/mix/phoenix_test.exs | angwoontiong/phoenix-ui | 03227b13f3c780b5626d56207bfa99c8a06525d8 | [
"MIT"
] | null | null | null | test/mix/phoenix_test.exs | angwoontiong/phoenix-ui | 03227b13f3c780b5626d56207bfa99c8a06525d8 | [
"MIT"
] | null | null | null | defmodule Mix.PhoenixTest do
use ExUnit.Case, async: true
doctest Mix.Phoenix, import: true
test "base/0 returns the module base based on the Mix application" do
assert Mix.Phoenix.base == "Phoenix"
Application.put_env(:phoenix, :app_namespace, Phoenix.Sample.App)
assert Mix.Phoenix.base == "Phoenix... | 25.071429 | 76 | 0.584995 |
620bbc03841ed70da42392fd0dc47f05fb94cd15 | 5,759 | ex | Elixir | lib/new_relic/distributed_trace/w3c_trace_context/trace_state.ex | binaryseed/elixir_agent | 25f1242c10516618d9ea3a9b18712e5bc41efad6 | [
"Apache-2.0"
] | null | null | null | lib/new_relic/distributed_trace/w3c_trace_context/trace_state.ex | binaryseed/elixir_agent | 25f1242c10516618d9ea3a9b18712e5bc41efad6 | [
"Apache-2.0"
] | null | null | null | lib/new_relic/distributed_trace/w3c_trace_context/trace_state.ex | binaryseed/elixir_agent | 25f1242c10516618d9ea3a9b18712e5bc41efad6 | [
"Apache-2.0"
] | null | null | null | defmodule NewRelic.DistributedTrace.W3CTraceContext.TraceState do
@moduledoc false
# https://w3c.github.io/trace-context/#tracestate-header
alias NewRelic.Harvest.Collector.AgentRun
defstruct [:members]
defmodule NewRelicState do
@moduledoc false
defstruct version: "0",
trusted_acco... | 26.417431 | 89 | 0.599062 |
620bbc3e6185720552a1f09c633fe40957c96d7f | 932 | exs | Elixir | test/mix/tasks/hex.config_test.exs | sudix/hex | f739a57d8829ea0b0f7759c164dc9149c3340e49 | [
"Apache-2.0"
] | null | null | null | test/mix/tasks/hex.config_test.exs | sudix/hex | f739a57d8829ea0b0f7759c164dc9149c3340e49 | [
"Apache-2.0"
] | 1 | 2021-06-25T15:19:59.000Z | 2021-06-25T15:19:59.000Z | test/mix/tasks/hex.config_test.exs | sudix/hex | f739a57d8829ea0b0f7759c164dc9149c3340e49 | [
"Apache-2.0"
] | null | null | null | defmodule Mix.Tasks.Hex.ConfigTest do
use HexTest.Case
test "config" do
in_tmp(fn ->
Hex.State.put(:home, System.cwd!())
assert_raise Mix.Error, "Config does not contain key foo", fn ->
Mix.Tasks.Hex.Config.run(["foo"])
end
Mix.Tasks.Hex.Config.run(["foo", "bar"])
Mix.Ta... | 25.189189 | 70 | 0.579399 |
620bdc3da4a0de269b338b2bf13a8bbe60b960d2 | 5,312 | ex | Elixir | web/modules/sql/adapters/mysql.ex | sahilpaudel/AfterGlow | 0859ec14b47c8c5704cc8e5cba86d39aa258fff5 | [
"MIT"
] | null | null | null | web/modules/sql/adapters/mysql.ex | sahilpaudel/AfterGlow | 0859ec14b47c8c5704cc8e5cba86d39aa258fff5 | [
"MIT"
] | null | null | null | web/modules/sql/adapters/mysql.ex | sahilpaudel/AfterGlow | 0859ec14b47c8c5704cc8e5cba86d39aa258fff5 | [
"MIT"
] | null | null | null | defmodule AfterGlow.Sql.Adapters.Mysql do
alias AfterGlow.Sql.Adapters.QueryMakers.Mysql, as: QueryMaker
use Supervisor
require IEx
alias DbConnection
def create_pool(config) do
Mariaex.start_link(
hostname: config["host_url"],
username: config["username"],
password: config["password"],... | 27.811518 | 100 | 0.620858 |
620bf8b843dda94c7d6d82342ef5e0d1b7db980a | 458 | ex | Elixir | lib/pummpcomm/history/low_battery.ex | infinity-aps/pummpcomm | 7380585ecd110ab1c19d2aea3880e51e3f433050 | [
"MIT"
] | 15 | 2017-08-31T00:58:47.000Z | 2020-01-12T03:53:13.000Z | lib/pummpcomm/history/low_battery.ex | vladhj38/pummpcomm | 7380585ecd110ab1c19d2aea3880e51e3f433050 | [
"MIT"
] | 1 | 2017-09-15T02:09:31.000Z | 2017-09-15T02:09:31.000Z | lib/pummpcomm/history/low_battery.ex | vladhj38/pummpcomm | 7380585ecd110ab1c19d2aea3880e51e3f433050 | [
"MIT"
] | 3 | 2017-09-10T17:24:59.000Z | 2019-09-10T19:41:49.000Z | defmodule Pummpcomm.History.LowBattery do
@moduledoc """
Low Battery alarm
"""
@behaviour Pummpcomm.History.Decoder
# Functions
## Pummpcomm.History.Decoder callbacks
@doc """
`timestamp` when Low Battery alarm was raised
"""
@impl Pummpcomm.History.Decoder
@spec decode(binary, Pummpcomm.PumpM... | 24.105263 | 93 | 0.735808 |
620c0f34649f67d61b1872b4a344cff5af893600 | 3,239 | ex | Elixir | clients/analytics/lib/google_api/analytics/v3/model/remarketing_audiences.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2021-12-20T03:40:53.000Z | 2021-12-20T03:40:53.000Z | clients/analytics/lib/google_api/analytics/v3/model/remarketing_audiences.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2020-08-18T00:11:23.000Z | 2020-08-18T00:44:16.000Z | clients/analytics/lib/google_api/analytics/v3/model/remarketing_audiences.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | null | null | null | # Copyright 2019 Google LLC
#
# 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, s... | 47.632353 | 299 | 0.709169 |
620c11c2517fa13fa733820827c96ce44083887e | 3,976 | ex | Elixir | lib/teleplug.ex | primait/teleplug | b6fe6cc535e8ec6dc4fc06d2def7b9a050d51e04 | [
"MIT"
] | 3 | 2021-04-29T12:30:53.000Z | 2021-11-19T22:08:08.000Z | lib/teleplug.ex | primait/teleplug | b6fe6cc535e8ec6dc4fc06d2def7b9a050d51e04 | [
"MIT"
] | 26 | 2021-09-21T15:22:02.000Z | 2022-03-24T02:19:56.000Z | lib/teleplug.ex | primait/teleplug | b6fe6cc535e8ec6dc4fc06d2def7b9a050d51e04 | [
"MIT"
] | null | null | null | defmodule Teleplug do
@moduledoc """
Simple opentelementry instrumented plug.
"""
alias Plug.Conn
require Logger
require OpenTelemetry.Tracer, as: Tracer
require Record
@behaviour Plug
defdelegate setup, to: Teleplug.Instrumentation
@impl true
def init(opts), do: opts
@impl true
def call... | 27.611111 | 176 | 0.668763 |
620c5332b7cd84ae7e57ffaa86a0f10e8890c756 | 1,470 | ex | Elixir | lib/boxes_web/views/error_helpers.ex | mlgx/boxes | f6c8b786bd7188ad57c1e071722e8196d594a034 | [
"Unlicense"
] | null | null | null | lib/boxes_web/views/error_helpers.ex | mlgx/boxes | f6c8b786bd7188ad57c1e071722e8196d594a034 | [
"Unlicense"
] | 2 | 2021-03-08T23:24:09.000Z | 2021-05-07T22:42:15.000Z | lib/boxes_web/views/error_helpers.ex | mlgx/boxes | f6c8b786bd7188ad57c1e071722e8196d594a034 | [
"Unlicense"
] | null | null | null | defmodule BoxesWeb.ErrorHelpers do
@moduledoc """
Conveniences for translating and building error messages.
"""
use Phoenix.HTML
@doc """
Generates tag for inlined form input errors.
"""
def error_tag(form, field) do
Enum.map(Keyword.get_values(form.errors, field), fn (error) ->
content_tag ... | 32.666667 | 74 | 0.669388 |
620c63182cda48395579767bddf860bd44de5d98 | 7,099 | ex | Elixir | apps/omg/test/support/test_helper.ex | omgnetwork/omg-childchain-v1 | 1e2313029ece2282c22ce411edc078a17e6bba09 | [
"Apache-2.0"
] | 1 | 2020-10-06T03:07:47.000Z | 2020-10-06T03:07:47.000Z | apps/omg/test/support/test_helper.ex | omgnetwork/omg-childchain-v1 | 1e2313029ece2282c22ce411edc078a17e6bba09 | [
"Apache-2.0"
] | 9 | 2020-09-16T15:31:17.000Z | 2021-03-17T07:12:35.000Z | apps/omg/test/support/test_helper.ex | omgnetwork/omg-childchain-v1 | 1e2313029ece2282c22ce411edc078a17e6bba09 | [
"Apache-2.0"
] | 1 | 2020-09-30T17:17:27.000Z | 2020-09-30T17:17:27.000Z | # Copyright 2019-2020 OmiseGO Pte Ltd
#
# 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 ... | 34.461165 | 119 | 0.638259 |
620c6c01c72204ad832953d4554c8908b021c841 | 338 | ex | Elixir | robotica_face/lib/robotica_face_web/views/api_view.ex | brianmay/robotica-elixir | 8656510e54b7e32a547e3a54bf946f0e327911c9 | [
"RSA-MD"
] | 1 | 2019-04-23T09:16:44.000Z | 2019-04-23T09:16:44.000Z | robotica_face/lib/robotica_face_web/views/api_view.ex | brianmay/robotica-elixir | 8656510e54b7e32a547e3a54bf946f0e327911c9 | [
"RSA-MD"
] | 107 | 2019-05-26T08:03:26.000Z | 2022-02-03T19:13:56.000Z | robotica_face/lib/robotica_face_web/views/api_view.ex | brianmay/robotica-elixir | 8656510e54b7e32a547e3a54bf946f0e327911c9 | [
"RSA-MD"
] | 1 | 2019-08-10T20:44:24.000Z | 2019-08-10T20:44:24.000Z | defmodule RoboticaFaceWeb.ApiView do
use RoboticaFaceWeb, :view
def render("index.json", %{fulfillmentMessages: fulfillmentMessages}) do
%{
fulfillmentMessages: fulfillmentMessages
}
end
def render("index.json", %{fulfillmentText: fulfillmentText}) do
%{
fulfillmentText: fulfillmentTex... | 21.125 | 74 | 0.710059 |
620c7070465f9f92baff7525a5414dff4b7f4228 | 3,229 | ex | Elixir | lib/ex_limiter/plug.ex | Miserlou/ex_limiter | 31391989dfca30d2f86cba04c5510c386efacdf4 | [
"MIT"
] | 28 | 2018-08-06T16:08:27.000Z | 2022-03-01T16:54:10.000Z | lib/ex_limiter/plug.ex | RiverFinancial/ex_limiter | 74f7b29c35e22af1955b01481a629a3c24bd3e45 | [
"MIT"
] | 3 | 2019-03-11T17:20:50.000Z | 2019-05-10T02:17:53.000Z | lib/ex_limiter/plug.ex | RiverFinancial/ex_limiter | 74f7b29c35e22af1955b01481a629a3c24bd3e45 | [
"MIT"
] | 4 | 2019-04-18T00:06:05.000Z | 2021-12-01T18:30:05.000Z | defmodule ExLimiter.Plug do
@moduledoc """
Plug for enforcing rate limits. The usage should be something like
```
plug ExLimiter.Plug, scale: 1000, limit: 5
```
Additionally, you can pass the following options:
- `:bucket`, a 1-arity function of a `Plug.Conn.t` which determines
the bucket for the ... | 30.462264 | 143 | 0.663983 |
620c823eb69e1f18a10b57c46842d83545c989e5 | 213 | exs | Elixir | apps/alert_processor/priv/repo/migrations/20180305194714_add_return_trip_to_subscriptions.exs | mbta/alerts_concierge | d8e643445ef06f80ca273f2914c6959daea146f6 | [
"MIT"
] | null | null | null | apps/alert_processor/priv/repo/migrations/20180305194714_add_return_trip_to_subscriptions.exs | mbta/alerts_concierge | d8e643445ef06f80ca273f2914c6959daea146f6 | [
"MIT"
] | 21 | 2021-03-12T17:05:30.000Z | 2022-02-16T21:48:35.000Z | apps/alert_processor/priv/repo/migrations/20180305194714_add_return_trip_to_subscriptions.exs | mbta/alerts_concierge | d8e643445ef06f80ca273f2914c6959daea146f6 | [
"MIT"
] | 1 | 2021-12-09T15:09:53.000Z | 2021-12-09T15:09:53.000Z | defmodule AlertProcessor.Repo.Migrations.AddReturnTripToSubscriptions do
use Ecto.Migration
def change do
alter table(:subscriptions) do
add :return_trip, :boolean, default: false
end
end
end
| 21.3 | 72 | 0.755869 |
620c906250234c1c12b9f146daf27327802ed73d | 1,989 | exs | Elixir | test/absinthe/language/object_type_definition_test.exs | hauptbenutzer/absinthe | f1d76e5c249ca337187971b0c96b1870f53716ed | [
"MIT"
] | null | null | null | test/absinthe/language/object_type_definition_test.exs | hauptbenutzer/absinthe | f1d76e5c249ca337187971b0c96b1870f53716ed | [
"MIT"
] | 2 | 2018-08-02T13:35:38.000Z | 2018-08-02T13:36:42.000Z | test/absinthe/language/object_type_definition_test.exs | hauptbenutzer/absinthe | f1d76e5c249ca337187971b0c96b1870f53716ed | [
"MIT"
] | 1 | 2018-11-16T02:34:40.000Z | 2018-11-16T02:34:40.000Z | defmodule Absinthe.Language.ObjectTypeDefinitionTest do
use Absinthe.Case, async: true
alias Absinthe.Blueprint
describe "converting to Blueprint" do
test "works, given a Blueprint Schema 'type' definition" do
assert %Blueprint.Schema.ObjectTypeDefinition{name: "Person"} =
from_input("t... | 26.52 | 113 | 0.575666 |
620cd0284a19c8f1911260e9b64baf5a86fa3a4e | 3,334 | ex | Elixir | lib/exsoda/approvals.ex | socrata/exsoda | d083825b1f26ff848c27a7cf359c7de31bf70914 | [
"Apache-2.0"
] | 13 | 2017-02-01T22:32:22.000Z | 2021-08-03T03:38:46.000Z | lib/exsoda/approvals.ex | rozap/exsoda | 82d05110749a15ecf82ea67eb7822c3b5581da22 | [
"Apache-2.0"
] | 13 | 2016-12-14T19:32:56.000Z | 2019-01-03T18:20:04.000Z | lib/exsoda/approvals.ex | socrata/exsoda | d083825b1f26ff848c27a7cf359c7de31bf70914 | [
"Apache-2.0"
] | 6 | 2016-12-14T04:35:49.000Z | 2021-06-28T21:51:37.000Z | defmodule Exsoda.Approvals do
alias Exsoda.Http
alias Exsoda.Runner
alias Exsoda.Runner.{Operations, Execute}
import Exsoda.Runner, only: [prepend: 2]
defmodule Guidance do
@enforce_keys [:fourfour, :catalog_revision_id]
defstruct [:fourfour, :catalog_revision_id]
defimpl Execute, for: __MODULE... | 34.729167 | 149 | 0.696761 |
620ce60016fc16a5623f0be73379a0c4aeff43ce | 297 | ex | Elixir | web/controllers/user_controller.ex | jbr/phoenix_guardian | 54152b8ca0ffa6afb4076e93814a54c68430f3e8 | [
"MIT"
] | 335 | 2015-06-19T18:27:51.000Z | 2020-11-25T19:00:27.000Z | web/controllers/user_controller.ex | thisdata/phoenix_guardian | 54152b8ca0ffa6afb4076e93814a54c68430f3e8 | [
"MIT"
] | 33 | 2015-06-24T17:00:01.000Z | 2017-11-23T09:53:29.000Z | web/controllers/user_controller.ex | thisdata/phoenix_guardian | 54152b8ca0ffa6afb4076e93814a54c68430f3e8 | [
"MIT"
] | 95 | 2015-06-30T22:18:00.000Z | 2022-01-14T13:47:10.000Z | defmodule PhoenixGuardian.UserController do
use PhoenixGuardian.Web, :controller
alias PhoenixGuardian.Repo
alias PhoenixGuardian.User
alias PhoenixGuardian.Authorization
def new(conn, params, current_user, _claims) do
render conn, "new.html", current_user: current_user
end
end
| 24.75 | 55 | 0.794613 |
620d007f94775d4456f48cb39c69de06b8695f3e | 156 | exs | Elixir | test/realtime_tests_test.exs | fhunleth/realtime_tests | fff4392e47a00db923127da4b1e6a16982103ddc | [
"Apache-2.0"
] | 1 | 2018-11-09T14:47:08.000Z | 2018-11-09T14:47:08.000Z | test/realtime_tests_test.exs | fhunleth/realtime_tests | fff4392e47a00db923127da4b1e6a16982103ddc | [
"Apache-2.0"
] | null | null | null | test/realtime_tests_test.exs | fhunleth/realtime_tests | fff4392e47a00db923127da4b1e6a16982103ddc | [
"Apache-2.0"
] | null | null | null | defmodule RealtimeTestsTest do
use ExUnit.Case
doctest RealtimeTests
test "greets the world" do
assert RealtimeTests.hello() == :world
end
end
| 17.333333 | 42 | 0.74359 |
620d53c5549169e002bed1b5c6fc60bda2b850c6 | 115 | ex | Elixir | apps/data_manager/lib/data_manager/repo.ex | drobban/bottle | 57a502e765a65d635f48ec6d6cbfae1e87dfea75 | [
"Unlicense"
] | null | null | null | apps/data_manager/lib/data_manager/repo.ex | drobban/bottle | 57a502e765a65d635f48ec6d6cbfae1e87dfea75 | [
"Unlicense"
] | null | null | null | apps/data_manager/lib/data_manager/repo.ex | drobban/bottle | 57a502e765a65d635f48ec6d6cbfae1e87dfea75 | [
"Unlicense"
] | null | null | null | defmodule DataManager.Repo do
use Ecto.Repo,
otp_app: :data_manager,
adapter: Ecto.Adapters.Postgres
end
| 19.166667 | 35 | 0.747826 |
620d693240e475c45c38691f049292d3099d6a6e | 1,936 | exs | Elixir | test/huex_test.exs | directionalpad/huex | 2bf2e9596d4c9712d580622fd592ab85ef4b9664 | [
"Apache-2.0"
] | 56 | 2015-07-19T08:04:12.000Z | 2021-11-13T06:15:50.000Z | test/huex_test.exs | directionalpad/huex | 2bf2e9596d4c9712d580622fd592ab85ef4b9664 | [
"Apache-2.0"
] | 10 | 2016-01-04T16:51:23.000Z | 2019-02-17T00:18:03.000Z | test/huex_test.exs | directionalpad/huex | 2bf2e9596d4c9712d580622fd592ab85ef4b9664 | [
"Apache-2.0"
] | 17 | 2016-01-03T04:18:56.000Z | 2022-03-18T12:46:05.000Z | defmodule HuexTest do
use ExUnit.Case, async: false
use ExVCR.Mock, adapter: ExVCR.Adapter.Hackney
setup_all do
ExVCR.Config.cassette_library_dir("test/fixtures/vcr_cassettes")
HTTPoison.start()
end
test "setting up a connection returns Bridge" do
bridge = Huex.connect("http://localhost")
as... | 29.333333 | 84 | 0.679236 |
620d6bff8c20e89e53682ec5848542fcc8a29447 | 1,567 | ex | Elixir | clients/tag_manager/lib/google_api/tag_manager/v2/model/revert_built_in_variable_response.ex | leandrocp/elixir-google-api | a86e46907f396d40aeff8668c3bd81662f44c71e | [
"Apache-2.0"
] | null | null | null | clients/tag_manager/lib/google_api/tag_manager/v2/model/revert_built_in_variable_response.ex | leandrocp/elixir-google-api | a86e46907f396d40aeff8668c3bd81662f44c71e | [
"Apache-2.0"
] | null | null | null | clients/tag_manager/lib/google_api/tag_manager/v2/model/revert_built_in_variable_response.ex | leandrocp/elixir-google-api | a86e46907f396d40aeff8668c3bd81662f44c71e | [
"Apache-2.0"
] | 1 | 2020-11-10T16:58:27.000Z | 2020-11-10T16:58:27.000Z | # Copyright 2017 Google 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
#
# Unless required by applicable law or agreed to in... | 32.645833 | 103 | 0.754946 |
620d6ef379a367cbc32e6e64267a90593679352c | 876 | ex | Elixir | clients/redis/lib/google_api/redis/v1/metadata.ex | jamesvl/elixir-google-api | 6c87fb31d996f08fb42ce6066317e9d652a87acc | [
"Apache-2.0"
] | null | null | null | clients/redis/lib/google_api/redis/v1/metadata.ex | jamesvl/elixir-google-api | 6c87fb31d996f08fb42ce6066317e9d652a87acc | [
"Apache-2.0"
] | 1 | 2020-12-18T09:25:12.000Z | 2020-12-18T09:25:12.000Z | clients/redis/lib/google_api/redis/v1/metadata.ex | myskoach/elixir-google-api | 4f8cbc2fc38f70ffc120fd7ec48e27e46807b563 | [
"Apache-2.0"
] | null | null | null | # Copyright 2020 Google LLC
#
# 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, s... | 32.444444 | 74 | 0.756849 |
620dbcdc188819eff13b40cbae31471cb4093564 | 655 | ex | Elixir | lib/til_web/controllers/resend_confirmation_controller.ex | kw7oe/til | 5ecaa3d199c06d535d1bbbfa05e2dc88e86ad815 | [
"MIT"
] | null | null | null | lib/til_web/controllers/resend_confirmation_controller.ex | kw7oe/til | 5ecaa3d199c06d535d1bbbfa05e2dc88e86ad815 | [
"MIT"
] | 2 | 2020-04-26T14:03:27.000Z | 2020-12-12T17:14:02.000Z | lib/til_web/controllers/resend_confirmation_controller.ex | kw7oe/til | 5ecaa3d199c06d535d1bbbfa05e2dc88e86ad815 | [
"MIT"
] | null | null | null | defmodule TilWeb.ResendConfirmationController do
use TilWeb, :controller
alias Til.Accounts
alias TilWeb.Email
alias Til.Mailer
def new(conn, _) do
render(conn, "new.html")
end
def create(conn, %{"email" => email}) do
case Accounts.get_user_by_email(email) do
nil ->
:ok
use... | 21.833333 | 79 | 0.645802 |
620de29669edfe78fd272fe972fa409ccc1ce5fd | 89 | ex | Elixir | src/turtlebot2_src/src/orocos-bayesian-filtering/orocos_bfl/debian/cron.d.ex | alexoterno/turtlebot2_with_head | ac714f77379dd0f47ddb76d83896fdabee269a03 | [
"MIT"
] | null | null | null | src/turtlebot2_src/src/orocos-bayesian-filtering/orocos_bfl/debian/cron.d.ex | alexoterno/turtlebot2_with_head | ac714f77379dd0f47ddb76d83896fdabee269a03 | [
"MIT"
] | null | null | null | src/turtlebot2_src/src/orocos-bayesian-filtering/orocos_bfl/debian/cron.d.ex | alexoterno/turtlebot2_with_head | ac714f77379dd0f47ddb76d83896fdabee269a03 | [
"MIT"
] | null | null | null | #
# Regular cron jobs for the orocos-bfl package
#
0 4 * * * root orocos-bfl_maintenance
| 17.8 | 46 | 0.719101 |
620de7d8c7b2e9f873cdc266c17dfd54e8626647 | 12,732 | ex | Elixir | lib/rql/query.ex | YgorCastor/ravix | ad3d191e2682b87d533a2d41899ed10e00b4dc55 | [
"Apache-2.0"
] | 9 | 2022-01-11T10:01:54.000Z | 2022-03-31T06:50:59.000Z | lib/rql/query.ex | YgorCastor/ravix | ad3d191e2682b87d533a2d41899ed10e00b4dc55 | [
"Apache-2.0"
] | 2 | 2022-03-21T20:13:13.000Z | 2022-03-28T21:07:47.000Z | lib/rql/query.ex | YgorCastor/ravix | ad3d191e2682b87d533a2d41899ed10e00b4dc55 | [
"Apache-2.0"
] | null | null | null | defmodule Ravix.RQL.Query do
@moduledoc """
Detructurized Raven Query Language structure
"""
defstruct from_token: nil,
where_token: nil,
update_token: nil,
and_tokens: [],
or_tokens: [],
group_token: nil,
select_token: nil,
ord... | 30.605769 | 145 | 0.600456 |
620e8234a151098a654a4bb933cdc43742382a94 | 311 | exs | Elixir | config/test.exs | prio101/mix_todo_app | 7fd487d93b350733ec9f25fa7ddfa626a8535c31 | [
"MIT"
] | null | null | null | config/test.exs | prio101/mix_todo_app | 7fd487d93b350733ec9f25fa7ddfa626a8535c31 | [
"MIT"
] | null | null | null | config/test.exs | prio101/mix_todo_app | 7fd487d93b350733ec9f25fa7ddfa626a8535c31 | [
"MIT"
] | null | null | null | use Mix.Config
config :todolist, TodoList.Repo, [
adapter: Ecto.Adapters.Postgres,
database: "todolist_#{Mix.env}",
username: "postgres",
password: "",
hostname: "localhost",
pool: Ecto.Adapters.SQL.Sandbox]
config :logger,
backends: [:console],
level: :warn,
compile_time_purge_level: :info | 22.214286 | 34 | 0.70418 |
620ea135dff422a7ee86ec47f56e4038673ed959 | 159 | exs | Elixir | apps/importer/config/prod.exs | bus-detective/bus_detective_ng | ef54684d4f640384bd20a4d5550ff51ab440190b | [
"MIT"
] | 8 | 2018-07-06T14:44:10.000Z | 2021-08-19T17:24:25.000Z | apps/importer/config/prod.exs | bus-detective/bus_detective_ng | ef54684d4f640384bd20a4d5550ff51ab440190b | [
"MIT"
] | 12 | 2018-07-15T18:43:04.000Z | 2022-02-10T16:07:47.000Z | apps/importer/config/prod.exs | bus-detective/bus_detective_ng | ef54684d4f640384bd20a4d5550ff51ab440190b | [
"MIT"
] | 1 | 2018-07-13T17:30:20.000Z | 2018-07-13T17:30:20.000Z | use Mix.Config
config :importer,
schedules: %{
System.get_env("FEED_NAME") => %{
gtfs_schedule_url: System.get_env("FEED_SCHEDULE_URL")
}
}
| 17.666667 | 60 | 0.654088 |
620ebf83b803473a6efe8f4b7954e64dcc7bafd8 | 418 | exs | Elixir | priv/repo/migrations/20210503121526_create_presentations.exs | jeepers3327/senti | 2e346759d8a8704f11364a835b6b9cd00a52c640 | [
"MIT"
] | null | null | null | priv/repo/migrations/20210503121526_create_presentations.exs | jeepers3327/senti | 2e346759d8a8704f11364a835b6b9cd00a52c640 | [
"MIT"
] | null | null | null | priv/repo/migrations/20210503121526_create_presentations.exs | jeepers3327/senti | 2e346759d8a8704f11364a835b6b9cd00a52c640 | [
"MIT"
] | null | null | null | defmodule Senti.Repo.Migrations.CreatePresentations do
use Ecto.Migration
def change do
create table(:presentations) do
add :name, :string, null: false
add :allow_multiple_answers, :boolean, default: false, null: false
add :user_id, references(:users, on_delete: :delete_all, type: :binary_id)... | 26.125 | 93 | 0.700957 |
620ef9823bf0e96b0b22311f966d421b6081b39d | 10,640 | exs | Elixir | test/pandex_test.exs | filterkaapi/pandex | f194cae384b0de681eda5f44dc9e108f205768f9 | [
"MIT"
] | 57 | 2015-09-11T07:20:54.000Z | 2021-11-03T19:27:17.000Z | test/pandex_test.exs | filterkaapi/pandex | f194cae384b0de681eda5f44dc9e108f205768f9 | [
"MIT"
] | 5 | 2015-09-21T07:34:38.000Z | 2019-05-30T19:42:07.000Z | test/pandex_test.exs | filterkaapi/pandex | f194cae384b0de681eda5f44dc9e108f205768f9 | [
"MIT"
] | 15 | 2015-09-18T23:50:07.000Z | 2021-03-12T02:45:42.000Z | defmodule PandexTest do
use ExUnit.Case, async: true
doctest Pandex
@min_version_major 2
@min_version_minor 5
test "pandoc version >= #{@min_version_major}.#{@min_version_minor}" do
assert {:ok, [major, minor | _]} = get_pandoc_version()
assert major >= @min_version_major and minor >= @min_version_m... | 18.898757 | 324 | 0.53515 |
620efc18983d333aea60f49d604155a13cce5d09 | 524 | ex | Elixir | lib/edgedb/protocol/datatypes/uint8.ex | f0lio/edgedb-elixir | b285bd8037b0b951aabfa1d1733889880f8bfd66 | [
"MIT"
] | null | null | null | lib/edgedb/protocol/datatypes/uint8.ex | f0lio/edgedb-elixir | b285bd8037b0b951aabfa1d1733889880f8bfd66 | [
"MIT"
] | null | null | null | lib/edgedb/protocol/datatypes/uint8.ex | f0lio/edgedb-elixir | b285bd8037b0b951aabfa1d1733889880f8bfd66 | [
"MIT"
] | null | null | null | defmodule EdgeDB.Protocol.Datatypes.UInt8 do
@moduledoc false
use EdgeDB.Protocol.Datatype
@uint8_max 0xFF
@uint8_min 0x0
defguard is_uint8(number)
when is_integer(number) and @uint8_min <= number and number <= @uint8_max
defdatatype(type: non_neg_integer())
@impl EdgeDB.Protocol.Datatype
... | 21.833333 | 84 | 0.721374 |
620eff603e0898c83854644784c077a005f5e65b | 1,096 | ex | Elixir | lib/turbolinks/helpers.ex | EasterPeanut/turbolinks.ex | c6ff3fa315b2297375c0b95788cd37a9ee0c7e84 | [
"MIT"
] | null | null | null | lib/turbolinks/helpers.ex | EasterPeanut/turbolinks.ex | c6ff3fa315b2297375c0b95788cd37a9ee0c7e84 | [
"MIT"
] | null | null | null | lib/turbolinks/helpers.ex | EasterPeanut/turbolinks.ex | c6ff3fa315b2297375c0b95788cd37a9ee0c7e84 | [
"MIT"
] | null | null | null | defmodule Turbolinks.Helpers do
@moduledoc """
Helper functions for using with frameworks
"""
@doc """
Custom redirection method to return a turbolinks visit and clearcache
"""
def redirect(conn, opts) do
if xhr?(conn) do
conn
|> Plug.Conn.put_status(302)
|> js(turbolinks_resp(opts[... | 21.92 | 71 | 0.607664 |
620f154b2807f39b0097433b411586372eabbaef | 489 | exs | Elixir | test/test_helper.exs | jalcine/solid | 845104b6c5c065f3930e16e3e45573f8fb0f0957 | [
"MIT"
] | null | null | null | test/test_helper.exs | jalcine/solid | 845104b6c5c065f3930e16e3e45573f8fb0f0957 | [
"MIT"
] | null | null | null | test/test_helper.exs | jalcine/solid | 845104b6c5c065f3930e16e3e45573f8fb0f0957 | [
"MIT"
] | null | null | null | ExUnit.start()
defmodule Solid.Helpers do
def render(text, hash \\ %{}) do
case Solid.parse(text) do
{:ok, template} ->
template
|> Solid.render(hash)
|> to_string()
{:error, error} ->
inspect(error)
end
rescue
e ->
IO.puts(Exception.format(:error, e, ... | 20.375 | 68 | 0.597137 |
620f1d77a0718177827875548c70580488e58227 | 228 | ex | Elixir | test/support/job_queue.ex | sendle/ecto_job | 5cea02620d8aa74a73d930a2d6a5349a38eee82f | [
"MIT"
] | null | null | null | test/support/job_queue.ex | sendle/ecto_job | 5cea02620d8aa74a73d930a2d6a5349a38eee82f | [
"MIT"
] | 1 | 2019-02-11T21:07:42.000Z | 2019-02-11T21:07:42.000Z | test/support/job_queue.ex | sendle/ecto_job | 5cea02620d8aa74a73d930a2d6a5349a38eee82f | [
"MIT"
] | null | null | null | defmodule EctoJob.Test.JobQueue do
# credo:disable-for-this-file
use EctoJob.JobQueue, table_name: "jobs"
def perform(multi, params) do
IO.inspect({multi, params})
EctoJob.Test.Repo.transaction(multi)
end
end
| 19 | 42 | 0.723684 |
620f258d278482044eef271cc5a64fbd7309aeef | 6,415 | ex | Elixir | lib/hexpm/web/router.ex | findmypast/hexfmp | 38a50f5e1057833fd98748faac230bf4b9cc26a3 | [
"Apache-2.0"
] | null | null | null | lib/hexpm/web/router.ex | findmypast/hexfmp | 38a50f5e1057833fd98748faac230bf4b9cc26a3 | [
"Apache-2.0"
] | null | null | null | lib/hexpm/web/router.ex | findmypast/hexfmp | 38a50f5e1057833fd98748faac230bf4b9cc26a3 | [
"Apache-2.0"
] | null | null | null | defmodule Hexpm.Web.Router do
use Hexpm.Web, :router
@accepted_formats ~w(json elixir erlang)
pipeline :browser do
plug :accepts, ["html"]
plug :auth_gate
plug :fetch_session
plug :fetch_flash
plug :protect_from_forgery
plug :put_secure_browser_headers
plug :web_user_agent
plug :... | 38.413174 | 88 | 0.641309 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.