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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
65adc9aaa586c440eda0c706b0417950f9dd5817 | 109 | ex | Elixir | lib/perf/model/execution_model.ex | juanzapa/distributed-performance-analyzer | d5f0e8cd6051281d76413236076c45fbaf36b6ba | [
"MIT"
] | 11 | 2020-04-17T18:32:26.000Z | 2021-10-22T00:16:03.000Z | lib/perf/model/execution_model.ex | juanzapa/distributed-performance-analyzer | d5f0e8cd6051281d76413236076c45fbaf36b6ba | [
"MIT"
] | 14 | 2020-05-11T16:26:01.000Z | 2022-03-10T01:31:22.000Z | lib/perf/model/execution_model.ex | juanzapa/distributed-performance-analyzer | d5f0e8cd6051281d76413236076c45fbaf36b6ba | [
"MIT"
] | 8 | 2020-08-19T22:25:13.000Z | 2021-11-12T20:12:22.000Z | defmodule ExecutionModel do
defstruct [:request, :steps, :increment, :duration, constant_load: false]
end
| 21.8 | 75 | 0.770642 |
65adf13f2aadc3aa0d06005598fbadebd38fb220 | 38,418 | ex | Elixir | clients/redis/lib/google_api/redis/v1beta1/api/projects.ex | mocknen/elixir-google-api | dac4877b5da2694eca6a0b07b3bd0e179e5f3b70 | [
"Apache-2.0"
] | null | null | null | clients/redis/lib/google_api/redis/v1beta1/api/projects.ex | mocknen/elixir-google-api | dac4877b5da2694eca6a0b07b3bd0e179e5f3b70 | [
"Apache-2.0"
] | null | null | null | clients/redis/lib/google_api/redis/v1beta1/api/projects.ex | mocknen/elixir-google-api | dac4877b5da2694eca6a0b07b3bd0e179e5f3b70 | [
"Apache-2.0"
] | null | null | null | # 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... | 47.023256 | 669 | 0.666953 |
65adf3586fea7a861efbecd8d78fd03cf662705f | 1,321 | exs | Elixir | config/config.exs | harmon25/ms_graph | abdfb527de91b44b8458bc7ca729ae6d37d56175 | [
"MIT"
] | null | null | null | config/config.exs | harmon25/ms_graph | abdfb527de91b44b8458bc7ca729ae6d37d56175 | [
"MIT"
] | null | null | null | config/config.exs | harmon25/ms_graph | abdfb527de91b44b8458bc7ca729ae6d37d56175 | [
"MIT"
] | null | null | null | # This file is responsible for configuring your application
# and its dependencies with the aid of the Mix.Config module.
use Mix.Config
# This configuration is loaded before any dependency and is restricted
# to this project. If another project depends on this project, this
# file won't be loaded nor affect the paren... | 36.694444 | 73 | 0.735806 |
65ae1f015039bac80f3ade1ba97d0357a652d021 | 9,447 | exs | Elixir | test/callisto/query_test.exs | mkompanets/callisto | a6dd6eabdd561feb7a8d727cc4890ba891ae5b62 | [
"Apache-2.0"
] | null | null | null | test/callisto/query_test.exs | mkompanets/callisto | a6dd6eabdd561feb7a8d727cc4890ba891ae5b62 | [
"Apache-2.0"
] | null | null | null | test/callisto/query_test.exs | mkompanets/callisto | a6dd6eabdd561feb7a8d727cc4890ba891ae5b62 | [
"Apache-2.0"
] | null | null | null | defmodule Callisto.QueryTest do
use ExUnit.Case
alias Callisto.{Query, Vertex}
describe "match/1" do
test "match with string" do
query_str = Query.match("d:Disease") |> to_string
assert query_str == "MATCH d:Disease"
end
test "match with empty map" do
query_str = Query.match(d: Vert... | 41.986667 | 145 | 0.620832 |
65ae4fb762eb2cb09131b66cc16dbae45d21df16 | 937 | ex | Elixir | test/support/channel_case.ex | HackathonSupport/auxilio | 7afc7372d0fbd902580a567be4cd106ece0d5b9b | [
"MIT"
] | null | null | null | test/support/channel_case.ex | HackathonSupport/auxilio | 7afc7372d0fbd902580a567be4cd106ece0d5b9b | [
"MIT"
] | 1 | 2018-02-04T02:33:55.000Z | 2018-12-07T11:22:13.000Z | test/support/channel_case.ex | HackathonSupport/auxilio | 7afc7372d0fbd902580a567be4cd106ece0d5b9b | [
"MIT"
] | null | null | null | defmodule AuxilioWeb.ChannelCase do
@moduledoc """
This module defines the test case to be used by
channel tests.
Such tests rely on `Phoenix.ChannelTest` and also
import other functionality to make it easier
to build common datastructures and query the data layer.
Finally, if the test case interacts wi... | 24.657895 | 69 | 0.716115 |
65ae7238414e1eb6cef9ea3c5e32dc993038689b | 1,826 | exs | Elixir | clients/composer/mix.exs | MasashiYokota/elixir-google-api | 975dccbff395c16afcb62e7a8e411fbb58e9ab01 | [
"Apache-2.0"
] | null | null | null | clients/composer/mix.exs | MasashiYokota/elixir-google-api | 975dccbff395c16afcb62e7a8e411fbb58e9ab01 | [
"Apache-2.0"
] | null | null | null | clients/composer/mix.exs | MasashiYokota/elixir-google-api | 975dccbff395c16afcb62e7a8e411fbb58e9ab01 | [
"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... | 27.253731 | 100 | 0.654436 |
65ae900e1d3ec9548e496df068000a40435d850c | 1,168 | exs | Elixir | chapter-14/working-with-multiple-processes-5/spawn_no_exception.exs | carlos4ndre/elixir-exercises | 3673cf69d08a6c7de53224f8956f0db21e7c5dad | [
"MIT"
] | 55 | 2015-12-09T09:23:50.000Z | 2022-01-31T21:14:59.000Z | chapter-14/working-with-multiple-processes-5/spawn_no_exception.exs | carlos4ndre/elixir-exercises | 3673cf69d08a6c7de53224f8956f0db21e7c5dad | [
"MIT"
] | 3 | 2016-06-15T12:53:39.000Z | 2017-08-21T18:20:42.000Z | chapter-14/working-with-multiple-processes-5/spawn_no_exception.exs | carlos4ndre/elixir-exercises | 3673cf69d08a6c7de53224f8956f0db21e7c5dad | [
"MIT"
] | 18 | 2016-01-01T18:18:23.000Z | 2021-05-24T02:22:42.000Z | defmodule SpawnTest do
import :timer, only: [ sleep: 1 ]
def sad_function do
receive do
{sender, msg} ->
send sender, msg
sad_function
end
end
def run do
{pid, _} = spawn_monitor(SpawnTest, :sad_function, [])
# send messages
send pid, {self, "DragonForce"}
send pi... | 20.137931 | 59 | 0.603596 |
65aea318ba2d56ba9999e01e830ffba289a41e25 | 2,522 | ex | Elixir | lib/mix/tasks/ecto.load.ex | arcz/ecto_sql | 22ecbe3782af32f50c36387c861db77041247de8 | [
"Apache-2.0"
] | null | null | null | lib/mix/tasks/ecto.load.ex | arcz/ecto_sql | 22ecbe3782af32f50c36387c861db77041247de8 | [
"Apache-2.0"
] | null | null | null | lib/mix/tasks/ecto.load.ex | arcz/ecto_sql | 22ecbe3782af32f50c36387c861db77041247de8 | [
"Apache-2.0"
] | null | null | null | defmodule Mix.Tasks.Ecto.Load do
use Mix.Task
import Mix.Ecto
import Mix.EctoSQL
@shortdoc "Loads previously dumped database structure"
@default_opts [force: false, quiet: false]
@aliases [
d: :dump_path,
f: :force,
q: :quiet
]
@switches [
dump_path: :string,
force: :boolean,
... | 28.337079 | 141 | 0.637193 |
65aedf4327d24ac96512ddc96bcb3d7ae8f53b9d | 1,543 | ex | Elixir | test/support/data_case.ex | psolvy/cat_on_duty | b03ba225286c85407ca21576c39225f058b22b56 | [
"MIT"
] | 3 | 2020-11-23T15:30:04.000Z | 2020-12-01T17:11:49.000Z | test/support/data_case.ex | psolvy/cat_on_duty | b03ba225286c85407ca21576c39225f058b22b56 | [
"MIT"
] | 1 | 2020-12-29T09:09:03.000Z | 2020-12-29T09:09:03.000Z | test/support/data_case.ex | psolvy/cat_on_duty | b03ba225286c85407ca21576c39225f058b22b56 | [
"MIT"
] | 1 | 2021-08-11T10:10:16.000Z | 2021-08-11T10:10:16.000Z | defmodule CatOnDuty.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,
we enable the SQL sandbox, so changes done to... | 26.603448 | 77 | 0.689566 |
65aee2486d93a95afab84c27daf866d347281d6f | 978 | ex | Elixir | lib/erlef_web/controllers/page_controller.ex | sstrollo/website | 4f0cc7b2fbfa7bfbdd300abdd13675085b4bd0e4 | [
"Apache-2.0"
] | null | null | null | lib/erlef_web/controllers/page_controller.ex | sstrollo/website | 4f0cc7b2fbfa7bfbdd300abdd13675085b4bd0e4 | [
"Apache-2.0"
] | null | null | null | lib/erlef_web/controllers/page_controller.ex | sstrollo/website | 4f0cc7b2fbfa7bfbdd300abdd13675085b4bd0e4 | [
"Apache-2.0"
] | null | null | null | defmodule ErlefWeb.PageController do
use ErlefWeb, :controller
action_fallback ErlefWeb.FallbackController
def index(conn, _params), do: render(conn)
def board_members(conn, _params) do
members = Enum.shuffle(Erlef.Rosters.get("board"))
render(conn, members: members)
end
def bylaws(conn, _params... | 28.764706 | 98 | 0.724949 |
65af076672f4ab8d8188923d6bd13a4d1d8a61ce | 323 | exs | Elixir | apps/core/priv/repo/migrations/20210408143653_add_queue_attributes.exs | michaeljguarino/forge | 50ee583ecb4aad5dee4ef08fce29a8eaed1a0824 | [
"Apache-2.0"
] | 59 | 2021-09-16T19:29:39.000Z | 2022-03-31T20:44:24.000Z | apps/core/priv/repo/migrations/20210408143653_add_queue_attributes.exs | svilenkov/plural | ac6c6cc15ac4b66a3b5e32ed4a7bee4d46d1f026 | [
"Apache-2.0"
] | 111 | 2021-08-15T09:56:37.000Z | 2022-03-31T23:59:32.000Z | apps/core/priv/repo/migrations/20210408143653_add_queue_attributes.exs | svilenkov/plural | ac6c6cc15ac4b66a3b5e32ed4a7bee4d46d1f026 | [
"Apache-2.0"
] | 4 | 2021-12-13T09:43:01.000Z | 2022-03-29T18:08:44.000Z | defmodule Core.Repo.Migrations.AddQueueAttributes do
use Ecto.Migration
def change do
alter table(:upgrade_queues) do
add :name, :string
add :domain, :string
add :git, :string
add :provider, :integer
end
create unique_index(:upgrade_queues, [:user_id, :name])
end
e... | 21.533333 | 59 | 0.650155 |
65af20c05f641af2cecf3a97a1727a68b2c31099 | 12,538 | exs | Elixir | test/plenario_web/controllers/data_set_controller_test.exs | vforgione/plenario2 | 001526e5c60a1d32794a18f3fd65ead6cade1a29 | [
"Apache-2.0"
] | 13 | 2017-12-11T13:59:42.000Z | 2020-11-16T21:52:31.000Z | test/plenario_web/controllers/data_set_controller_test.exs | vforgione/plenario2 | 001526e5c60a1d32794a18f3fd65ead6cade1a29 | [
"Apache-2.0"
] | 310 | 2017-11-13T22:52:26.000Z | 2018-11-19T17:49:30.000Z | test/plenario_web/controllers/data_set_controller_test.exs | vforgione/plenario2 | 001526e5c60a1d32794a18f3fd65ead6cade1a29 | [
"Apache-2.0"
] | 3 | 2017-12-05T00:36:12.000Z | 2020-03-10T15:15:29.000Z | defmodule PlenarioWeb.Testing.DataSetControllerTest do
use PlenarioWeb.Testing.ConnCase
import Mock
import Plenario.Testing.DataCase
alias Plenario.{
DataSetActions,
FieldActions,
VirtualDateActions,
VirtualPointActions
}
def mock_download(_, _), do: "test/fixtures/id_timestamp.csv"
d... | 28.049217 | 137 | 0.594353 |
65af3abe08a79f6ff8759c2434bb20f0eacf14a2 | 946 | ex | Elixir | test/support/channel_case.ex | guisehn/sface-on-view-demo | 7d9db80d02d1f82e6c874255d56eabcc414215ae | [
"MIT"
] | null | null | null | test/support/channel_case.ex | guisehn/sface-on-view-demo | 7d9db80d02d1f82e6c874255d56eabcc414215ae | [
"MIT"
] | null | null | null | test/support/channel_case.ex | guisehn/sface-on-view-demo | 7d9db80d02d1f82e6c874255d56eabcc414215ae | [
"MIT"
] | null | null | null | defmodule ExampleWeb.ChannelCase do
@moduledoc """
This module defines the test case to be used by
channel tests.
Such tests rely on `Phoenix.ChannelTest` and also
import other functionality to make it easier
to build common data structures and query the data layer.
Finally, if the test case interacts w... | 27.028571 | 64 | 0.738901 |
65af472f89dd61281a8345564871f1f4a1ca0e45 | 3,393 | ex | Elixir | lib/mix/tasks/ash.formatter.ex | elbow-jason/ash | eb63bc9d4d24187ad07d9892088b4e55ad6258e4 | [
"MIT"
] | 1 | 2021-12-27T09:43:29.000Z | 2021-12-27T09:43:29.000Z | lib/mix/tasks/ash.formatter.ex | elbow-jason/ash | eb63bc9d4d24187ad07d9892088b4e55ad6258e4 | [
"MIT"
] | null | null | null | lib/mix/tasks/ash.formatter.ex | elbow-jason/ash | eb63bc9d4d24187ad07d9892088b4e55ad6258e4 | [
"MIT"
] | null | null | null | defmodule Mix.Tasks.Ash.Formatter do
@moduledoc "Generates a .formatter.exs from a list of extensions, and writes it."
use Mix.Task
@formatter_exs_template """
# THIS FILE IS AUTOGENERATED USING `mix ash.formatter`
# DONT MODIFY IT BY HAND
locals_without_parens = __replace_me__
[
inputs: [... | 27.362903 | 95 | 0.653404 |
65af6eaad17d2053203fed99f1e5902683696ed6 | 1,260 | ex | Elixir | lib/phoenix/transports/websocket_serializer.ex | gjaldon/phoenix | a85a13d8bfbd7d768bb86d38da427875df3fb703 | [
"MIT"
] | 1 | 2015-05-19T11:04:16.000Z | 2015-05-19T11:04:16.000Z | lib/phoenix/transports/websocket_serializer.ex | gjaldon/phoenix | a85a13d8bfbd7d768bb86d38da427875df3fb703 | [
"MIT"
] | null | null | null | lib/phoenix/transports/websocket_serializer.ex | gjaldon/phoenix | a85a13d8bfbd7d768bb86d38da427875df3fb703 | [
"MIT"
] | null | null | null | defmodule Phoenix.Transports.WebSocketSerializer do
@moduledoc false
@behaviour Phoenix.Transports.Serializer
alias Phoenix.Socket.Reply
alias Phoenix.Socket.Message
alias Phoenix.Socket.Broadcast
@doc """
Translates a `Phoenix.Socket.Broadcast` into a `Phoenix.Socket.Message`.
"""
def fastlane!(%B... | 24.705882 | 76 | 0.666667 |
65af890551a0572f0e7b1b00f48f9a6fc054503e | 1,096 | ex | Elixir | test/support/conn_case.ex | luisantunesdeveloper/streams | 98b85124dd1c39c2ebe1254e454be98863bacb7e | [
"MIT"
] | null | null | null | test/support/conn_case.ex | luisantunesdeveloper/streams | 98b85124dd1c39c2ebe1254e454be98863bacb7e | [
"MIT"
] | null | null | null | test/support/conn_case.ex | luisantunesdeveloper/streams | 98b85124dd1c39c2ebe1254e454be98863bacb7e | [
"MIT"
] | null | null | null | defmodule Streams.ConnCase do
@moduledoc """
This module defines the test case to be used by
tests that require setting up a connection.
Such tests rely on `Phoenix.ConnTest` and also
import other functionality to make it easier
to build and query models.
Finally, if the test case interacts with the dat... | 24.355556 | 69 | 0.70438 |
65af9dec2cf2a6a589cb17faccac951c6a6d1cdf | 36,425 | ex | Elixir | lib/phoenix_live_view/test/live_view_test.ex | balexand/phoenix_live_view | 980e29d84be5bd009549b3be21eb307b9b891325 | [
"MIT"
] | null | null | null | lib/phoenix_live_view/test/live_view_test.ex | balexand/phoenix_live_view | 980e29d84be5bd009549b3be21eb307b9b891325 | [
"MIT"
] | null | null | null | lib/phoenix_live_view/test/live_view_test.ex | balexand/phoenix_live_view | 980e29d84be5bd009549b3be21eb307b9b891325 | [
"MIT"
] | null | null | null | defmodule Phoenix.LiveViewTest do
@moduledoc """
Conveniences for testing Phoenix LiveViews.
In LiveView tests, we interact with views via process
communication in substitution of a browser. Like a browser,
our test process receives messages about the rendered updates
from the view which can be asserted ag... | 32.234513 | 98 | 0.660041 |
65afa11394ddd9d3c8cb07b5970d30062db5442c | 518 | ex | Elixir | client_query/lib/client_query/repo.ex | gumberss/Ticketing-deno | 959b1b0763d246e05fd261aa5ceb94894dc5fe7b | [
"MIT"
] | 1 | 2020-09-08T00:06:33.000Z | 2020-09-08T00:06:33.000Z | client_query/lib/client_query/repo.ex | gumberss/Ticketing-deno | 959b1b0763d246e05fd261aa5ceb94894dc5fe7b | [
"MIT"
] | null | null | null | client_query/lib/client_query/repo.ex | gumberss/Ticketing-deno | 959b1b0763d246e05fd261aa5ceb94894dc5fe7b | [
"MIT"
] | null | null | null | defmodule ClientQuery.Repo do
use Ecto.Repo,
otp_app: :client_query,
adapter: Ecto.Adapters.Postgres
def init(_, config) do
config = config
|> Keyword.put(:username, System.get_env("PGUSER"))
|> Keyword.put(:password, System.get_env("PGPASSWORD"))
|> Keyword.put(:database, S... | 32.375 | 76 | 0.637066 |
65afbc135da36bfcff18ff4a7651e94296bbf006 | 108 | exs | Elixir | test/scopes/document_test.exs | isshindev/accent | ae4c13139b0a0dfd64ff536b94c940a4e2862150 | [
"BSD-3-Clause"
] | 806 | 2018-04-07T20:40:33.000Z | 2022-03-30T01:39:57.000Z | test/scopes/document_test.exs | isshindev/accent | ae4c13139b0a0dfd64ff536b94c940a4e2862150 | [
"BSD-3-Clause"
] | 194 | 2018-04-07T13:49:37.000Z | 2022-03-30T19:58:45.000Z | test/scopes/document_test.exs | doc-ai/accent | e337e16f3658cc0728364f952c0d9c13710ebb06 | [
"BSD-3-Clause"
] | 89 | 2018-04-09T13:55:49.000Z | 2022-03-24T07:09:31.000Z | defmodule AccentTest.Scopes.Document do
use ExUnit.Case, async: true
doctest Accent.Scopes.Document
end
| 21.6 | 39 | 0.805556 |
65afccc844dbe72e881968f925ca6ef562020b01 | 1,646 | exs | Elixir | mix.exs | serokellcao/preact-phoenix | 6094c0db9411231adb053f2dc351b447dc53732a | [
"MIT"
] | null | null | null | mix.exs | serokellcao/preact-phoenix | 6094c0db9411231adb053f2dc351b447dc53732a | [
"MIT"
] | 2 | 2021-03-10T04:41:11.000Z | 2021-05-11T00:41:00.000Z | mix.exs | serokellcao/preact-phoenix | 6094c0db9411231adb053f2dc351b447dc53732a | [
"MIT"
] | null | null | null | defmodule Detect.MixProject do
use Mix.Project
def project do
[
app: :detect,
version: "0.1.0",
elixir: "~> 1.5",
elixirc_paths: elixirc_paths(Mix.env()),
compilers: [:phoenix, :gettext] ++ Mix.compilers(),
start_permanent: Mix.env() == :prod,
aliases: aliases(),
... | 26.126984 | 79 | 0.575942 |
65affc5fc1abfcd22619d7a6f154bbba5e5b92ff | 2,212 | exs | Elixir | config/config.exs | ClubNix/academy | 962be0defc1d8eedc5d19ac0a65e931c794c6538 | [
"MIT"
] | 3 | 2016-06-18T17:46:14.000Z | 2020-01-21T03:19:41.000Z | config/config.exs | ClubNix/academy | 962be0defc1d8eedc5d19ac0a65e931c794c6538 | [
"MIT"
] | 18 | 2016-06-18T18:05:43.000Z | 2018-03-06T08:19:41.000Z | config/config.exs | ClubNix/academy | 962be0defc1d8eedc5d19ac0a65e931c794c6538 | [
"MIT"
] | 3 | 2016-10-26T19:51:06.000Z | 2018-09-18T09:06:14.000Z | # This file is responsible for configuring your application
# and its dependencies with the aid of the Mix.Config module.
#
# This configuration file is loaded before any dependency and
# is restricted to this project.
use Mix.Config
config :academy, ecto_repos: [Academy.Repo]
# Configures the endpoint
config :academ... | 32.529412 | 86 | 0.724231 |
65b02987909aeae3988967e499cd17829092aa08 | 1,775 | exs | Elixir | test/loggable_test.exs | coingaming/loggable | 7b4ba129ce593e16097407de7bca21882e33a092 | [
"MIT"
] | 5 | 2019-08-21T12:27:02.000Z | 2020-02-05T04:41:19.000Z | test/loggable_test.exs | coingaming/loggable | 7b4ba129ce593e16097407de7bca21882e33a092 | [
"MIT"
] | null | null | null | test/loggable_test.exs | coingaming/loggable | 7b4ba129ce593e16097407de7bca21882e33a092 | [
"MIT"
] | null | null | null | defmodule LoggableTest do
use ExUnit.Case
doctest Loggable
defmodule Wrapper do
@enforce_keys [:user]
defstruct @enforce_keys
end
defmodule User do
@enforce_keys [:name, :balance, :card]
defstruct @enforce_keys
end
defimpl Loggable.Protocol, for: User do
def show(%User{} = x) do
... | 20.402299 | 45 | 0.424789 |
65b0301af2b3f6a581d454ca5773d4fe2f6c1ba5 | 1,285 | ex | Elixir | clients/cloud_shell/lib/google_api/cloud_shell/v1/model/remove_public_key_response.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2021-12-20T03:40:53.000Z | 2021-12-20T03:40:53.000Z | clients/cloud_shell/lib/google_api/cloud_shell/v1/model/remove_public_key_response.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2020-12-18T09:25:12.000Z | 2020-12-18T09:25:12.000Z | clients/cloud_shell/lib/google_api/cloud_shell/v1/model/remove_public_key_response.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... | 30.595238 | 85 | 0.768093 |
65b0411fe954f0ee43aa48ce966630b500b69aba | 561 | exs | Elixir | config/test.exs | fletchermoore/cip | 5dd1c6f105d6a4c8c34a9e824cbad2fcf78a0655 | [
"Unlicense"
] | null | null | null | config/test.exs | fletchermoore/cip | 5dd1c6f105d6a4c8c34a9e824cbad2fcf78a0655 | [
"Unlicense"
] | null | null | null | config/test.exs | fletchermoore/cip | 5dd1c6f105d6a4c8c34a9e824cbad2fcf78a0655 | [
"Unlicense"
] | null | null | null | use Mix.Config
# We don't run a server during test. If one is required,
# you can enable the server option below.
config :cip, CipWeb.Endpoint,
http: [port: 4001],
server: false
# Print only warnings and errors during test
config :logger, level: :warn
# Configure your database
config :cip, Cip.Repo,
adapter: E... | 28.05 | 56 | 0.750446 |
65b04239529d05e0dcd370a01c8c2ef41dc7ccc6 | 1,733 | exs | Elixir | mix.exs | josephyi/hextech | ae892029a424aa52655152af1f0660ea77a5d8e1 | [
"MIT"
] | null | null | null | mix.exs | josephyi/hextech | ae892029a424aa52655152af1f0660ea77a5d8e1 | [
"MIT"
] | null | null | null | mix.exs | josephyi/hextech | ae892029a424aa52655152af1f0660ea77a5d8e1 | [
"MIT"
] | null | null | null | defmodule Hextech.Mixfile do
use Mix.Project
def project do
[app: :hextech,
version: "0.0.1",
elixir: "~> 1.0",
elixirc_paths: elixirc_paths(Mix.env),
compilers: [:phoenix, :gettext] ++ Mix.compilers,
build_embedded: Mix.env == :prod,
start_permanent: Mix.env == :prod,
aliase... | 29.372881 | 80 | 0.581073 |
65b045c919d22540687a2c65aa6a5814d38b3c66 | 946 | exs | Elixir | .check.exs | rheubach/live-share-prop | b92bcaca16fc42e31a3edb5d8922cbfcb2cceb88 | [
"MIT"
] | 68 | 2020-02-13T15:17:39.000Z | 2022-03-29T23:21:19.000Z | .check.exs | rheubach/live-share-prop | b92bcaca16fc42e31a3edb5d8922cbfcb2cceb88 | [
"MIT"
] | 30 | 2020-04-16T17:21:22.000Z | 2021-09-20T21:47:12.000Z | .check.exs | rheubach/live-share-prop | b92bcaca16fc42e31a3edb5d8922cbfcb2cceb88 | [
"MIT"
] | 7 | 2020-06-07T16:19:14.000Z | 2022-02-09T23:31:25.000Z | [
## all available options with default values (see `mix check` docs for description)
# parallel: true,
# skipped: true,
## list of tools (see `mix check` docs for defaults)
tools: [
## curated tools may be disabled (e.g. the check for compilation warnings)
# {:compiler, false},
## ...or adjuste... | 37.84 | 91 | 0.641649 |
65b0bf24ff6a44bbba594b21cbe4f34686fc20ca | 4,655 | exs | Elixir | test/we_reports_web/controllers/proposition_controller_test.exs | himrock922/we_reports | 04cffcd0e56f441e5087b65cf80a31602afae419 | [
"MIT"
] | null | null | null | test/we_reports_web/controllers/proposition_controller_test.exs | himrock922/we_reports | 04cffcd0e56f441e5087b65cf80a31602afae419 | [
"MIT"
] | 5 | 2020-09-09T01:41:39.000Z | 2021-05-11T00:18:38.000Z | test/we_reports_web/controllers/proposition_controller_test.exs | himrock922/we_reports | 04cffcd0e56f441e5087b65cf80a31602afae419 | [
"MIT"
] | null | null | null | defmodule WeReportsWeb.PropositionControllerTest do
use WeReportsWeb.ConnCase
alias WeReports.{Groups, Propositions}
@create_attrs %{description: "some description", name: "some name"}
@update_attrs %{description: "some updated description", name: "some updated name"}
@invalid_attrs %{description: nil, name... | 38.155738 | 135 | 0.706337 |
65b0cf8982eb195ec46995bcaef9b6eb2d57c236 | 1,104 | ex | Elixir | clients/home_graph/lib/google_api/home_graph/v1/connection.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2021-12-20T03:40:53.000Z | 2021-12-20T03:40:53.000Z | clients/home_graph/lib/google_api/home_graph/v1/connection.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2020-08-18T00:11:23.000Z | 2020-08-18T00:44:16.000Z | clients/home_graph/lib/google_api/home_graph/v1/connection.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... | 33.454545 | 74 | 0.737319 |
65b0f1b8d54148fdf8904bc008d891c75b9f507d | 358 | ex | Elixir | lib/pinocchio/application.ex | Kraigie/Pinocchio | d0b93c7e61b011a751d6ffa16cda4a343d1e238d | [
"MIT"
] | 1 | 2018-04-10T01:04:59.000Z | 2018-04-10T01:04:59.000Z | lib/pinocchio/application.ex | Kraigie/Pinocchio | d0b93c7e61b011a751d6ffa16cda4a343d1e238d | [
"MIT"
] | null | null | null | lib/pinocchio/application.ex | Kraigie/Pinocchio | d0b93c7e61b011a751d6ffa16cda4a343d1e238d | [
"MIT"
] | 1 | 2018-09-25T15:55:35.000Z | 2018-09-25T15:55:35.000Z | defmodule Pinocchio.Application do
@moduledoc false
use Application
alias Pinocchio.Consumer
def start(_type, _args) do
children =
for i <- 1..System.schedulers_online(), do: Supervisor.child_spec({Consumer, []}, id: i)
opts = [strategy: :one_for_one, name: Pinocchio.Supervisor]
Supervisor... | 22.375 | 94 | 0.709497 |
65b13f878218c712fa36056d1d60d6a9bafb49ac | 2,648 | ex | Elixir | lib/ua_inspector/database/clients.ex | elixytics/ua_inspector | 11fd98f69b7853b70529ee73355ef57851248572 | [
"Apache-2.0"
] | 57 | 2015-04-07T03:10:45.000Z | 2019-03-11T01:01:40.000Z | lib/ua_inspector/database/clients.ex | elixytics/ua_inspector | 11fd98f69b7853b70529ee73355ef57851248572 | [
"Apache-2.0"
] | 16 | 2015-03-09T19:56:17.000Z | 2019-03-16T14:24:02.000Z | lib/ua_inspector/database/clients.ex | elixytics/ua_inspector | 11fd98f69b7853b70529ee73355ef57851248572 | [
"Apache-2.0"
] | 15 | 2015-02-02T23:14:00.000Z | 2019-03-16T13:15:05.000Z | defmodule UAInspector.Database.Clients do
@moduledoc false
use UAInspector.Storage.Server
require Logger
alias UAInspector.Config
alias UAInspector.Util
alias UAInspector.Util.YAML
@behaviour UAInspector.Database
@doc false
def start_link(init_arg) do
GenServer.start_link(__MODULE__, init_arg... | 28.170213 | 96 | 0.641239 |
65b152c14316ec2ad197cbed0e3cc0a303204d21 | 2,092 | exs | Elixir | mix.exs | ynd-consult-ug/ynd-phx-bootstrap | 784480186fee0375a01a534fcf597d1ef026e7ac | [
"MIT"
] | 33 | 2018-02-01T16:02:05.000Z | 2020-08-20T07:47:33.000Z | mix.exs | ynd-consult/ynd-phx-bootstrap | 784480186fee0375a01a534fcf597d1ef026e7ac | [
"MIT"
] | null | null | null | mix.exs | ynd-consult/ynd-phx-bootstrap | 784480186fee0375a01a534fcf597d1ef026e7ac | [
"MIT"
] | 2 | 2020-10-30T10:49:38.000Z | 2021-03-29T15:07:40.000Z | defmodule YndPhxBootstrap.Mixfile do
use Mix.Project
def project do
[
app: :ynd_phx_bootstrap,
version: "0.0.1",
elixir: "~> 1.4",
elixirc_paths: elixirc_paths(Mix.env),
compilers: [:phoenix, :gettext] ++ Mix.compilers,
start_permanent: Mix.env == :prod,
aliases: alias... | 29.055556 | 87 | 0.575048 |
65b198a19e6ad5ca990338880d47116306e7b339 | 4,604 | exs | Elixir | test/quiz_site/cards/cards_test.exs | rbgraham/quiz_site | 57ded7991e355e2cf9f5edecc823b67833ee0ceb | [
"MIT"
] | 2 | 2017-10-30T00:42:01.000Z | 2017-10-30T21:29:15.000Z | test/quiz_site/cards/cards_test.exs | rbgraham/quiz_site | 57ded7991e355e2cf9f5edecc823b67833ee0ceb | [
"MIT"
] | null | null | null | test/quiz_site/cards/cards_test.exs | rbgraham/quiz_site | 57ded7991e355e2cf9f5edecc823b67833ee0ceb | [
"MIT"
] | null | null | null | defmodule QuizSite.CardsTest do
use QuizSite.DataCase
alias QuizSite.Cards
describe "sections" do
alias QuizSite.Cards.Section
@valid_attrs %{content: "some content", cta: "some cta", title: "some title", image_width: "125px", email_form: false}
@update_attrs %{content: "some updated content", cta:... | 34.878788 | 122 | 0.680278 |
65b1bc29a78b16441adc74a68fa233c44e3a8a02 | 1,812 | exs | Elixir | config/prod.exs | vbertazzo/expokefight | 19b6bd39af43e17c3ee14eab845cb24fb71d6d80 | [
"MIT"
] | null | null | null | config/prod.exs | vbertazzo/expokefight | 19b6bd39af43e17c3ee14eab845cb24fb71d6d80 | [
"MIT"
] | null | null | null | config/prod.exs | vbertazzo/expokefight | 19b6bd39af43e17c3ee14eab845cb24fb71d6d80 | [
"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.529412 | 66 | 0.710817 |
65b1dca888ae10a45f7d066ae6fc7d7ad4871320 | 601 | exs | Elixir | test/cloak/tags/encoder_test.exs | robinvdvleuten/cloak | 70cbf4bc59f15b5f60831d455b8dc7b6f457a1ff | [
"MIT"
] | 475 | 2015-09-19T14:09:11.000Z | 2022-03-28T14:53:27.000Z | test/cloak/tags/encoder_test.exs | robinvdvleuten/cloak | 70cbf4bc59f15b5f60831d455b8dc7b6f457a1ff | [
"MIT"
] | 98 | 2015-12-16T03:53:48.000Z | 2022-03-24T22:34:56.000Z | test/cloak/tags/encoder_test.exs | robinvdvleuten/cloak | 70cbf4bc59f15b5f60831d455b8dc7b6f457a1ff | [
"MIT"
] | 67 | 2015-10-21T11:56:38.000Z | 2022-03-18T13:51:16.000Z | defmodule Cloak.Tags.EncoderTest do
import Cloak.Tags.Encoder
use ExUnit.Case, async: true
doctest Cloak.Tags.Encoder
describe "Cloak.Tags.Encoder/1" do
test "when byte_size(tag) < 128 it returns a bitstring with the length as second byte" do
assert encode(<<25, 13, 33, 41>>) == <<1, 4, 25, 13, 33, ... | 33.388889 | 106 | 0.642263 |
65b2071a1653ae5ee75b536b109aa67499a43a9c | 1,931 | ex | Elixir | clients/document_ai/lib/google_api/document_ai/v1/model/google_cloud_documentai_v1_document_output_config.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_document_output_config.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_document_output_config.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... | 34.482143 | 199 | 0.763335 |
65b20f695c4c47f911270f7dd7ef50c2c34b6b53 | 1,667 | ex | Elixir | platform/target/gpio/circuits_gpio_handler.ex | bahanni/custom_rpi4 | ddefa85d30bacaae40151a63a9a0ebbf4ad30ed5 | [
"MIT"
] | null | null | null | platform/target/gpio/circuits_gpio_handler.ex | bahanni/custom_rpi4 | ddefa85d30bacaae40151a63a9a0ebbf4ad30ed5 | [
"MIT"
] | null | null | null | platform/target/gpio/circuits_gpio_handler.ex | bahanni/custom_rpi4 | ddefa85d30bacaae40151a63a9a0ebbf4ad30ed5 | [
"MIT"
] | null | null | null | defmodule FarmbotOS.Platform.Target.PinBindingWorker.CircuitsGPIOHandler do
@moduledoc "Circuits gpio handler for PinBindings"
@behaviour FarmbotOS.AssetWorker.FarmbotOS.Asset.PinBinding
require Logger
use GenServer
alias Circuits.GPIO
require FarmbotOS.Logger
FarmbotOS.Logger.report_termination()
@de... | 31.45283 | 79 | 0.70246 |
65b295bc307f327c3b43ba5ce23ef2ef4ba292a0 | 2,724 | exs | Elixir | test/changelog_web/email_test.exs | d-m-u/changelog.com | bb0d6ac6d29a3d64dbeb44892f9a8a1ff3ba6325 | [
"MIT"
] | 2,599 | 2016-10-25T15:02:53.000Z | 2022-03-26T02:34:42.000Z | test/changelog_web/email_test.exs | d-m-u/changelog.com | bb0d6ac6d29a3d64dbeb44892f9a8a1ff3ba6325 | [
"MIT"
] | 253 | 2016-10-25T20:29:24.000Z | 2022-03-29T21:52:36.000Z | test/changelog_web/email_test.exs | d-m-u/changelog.com | bb0d6ac6d29a3d64dbeb44892f9a8a1ff3ba6325 | [
"MIT"
] | 298 | 2016-10-25T15:18:31.000Z | 2022-01-18T21:25:52.000Z | defmodule ChangelogWeb.EmailTest do
use Changelog.SchemaCase
use Bamboo.Test
alias Changelog.Newsletters
alias ChangelogWeb.Email
setup do
person = build(:person, auth_token: "54321", auth_token_expires_at: Timex.now())
{:ok, person: person}
end
test "comment mention", %{person: person} do
... | 29.934066 | 95 | 0.683554 |
65b2c8cdbda852401a602204f3fa0a116d5fc1dd | 2,874 | ex | Elixir | lib/grizzly/zwave/smart_start/meta_extension/advanced_join.ex | jellybob/grizzly | 290bee04cb16acbb9dc996925f5c501697b7ac94 | [
"Apache-2.0"
] | null | null | null | lib/grizzly/zwave/smart_start/meta_extension/advanced_join.ex | jellybob/grizzly | 290bee04cb16acbb9dc996925f5c501697b7ac94 | [
"Apache-2.0"
] | null | null | null | lib/grizzly/zwave/smart_start/meta_extension/advanced_join.ex | jellybob/grizzly | 290bee04cb16acbb9dc996925f5c501697b7ac94 | [
"Apache-2.0"
] | null | null | null | defmodule Grizzly.ZWave.SmartStart.MetaExtension.AdvancedJoining do
@moduledoc """
This extension is used to advertise the Security keys to grant during S2
bootstrapping to a SmartStart node in the provisioning list
For more information about S2 security see the `Grizzly.Security` module
"""
@behaviour Griz... | 31.23913 | 96 | 0.64231 |
65b2d483cb96d072dedace838cf72cd24198e034 | 11,531 | ex | Elixir | lib/json/ld/flattening.ex | rustra/jsonld-ex | 4f903a04d4ba9f0f0df1b871a92eb89bc20f38dc | [
"MIT"
] | 12 | 2020-06-18T18:23:34.000Z | 2022-01-05T15:00:09.000Z | lib/json/ld/flattening.ex | rustra/jsonld-ex | 4f903a04d4ba9f0f0df1b871a92eb89bc20f38dc | [
"MIT"
] | 5 | 2020-06-16T16:18:14.000Z | 2021-08-19T20:23:03.000Z | lib/json/ld/flattening.ex | rustra/jsonld-ex | 4f903a04d4ba9f0f0df1b871a92eb89bc20f38dc | [
"MIT"
] | 6 | 2020-06-17T22:25:51.000Z | 2021-08-19T19:55:49.000Z | defmodule JSON.LD.Flattening do
@moduledoc nil
import JSON.LD.{NodeIdentifierMap, Utils}
alias JSON.LD.{NodeIdentifierMap, Options}
@dialyzer {:nowarn_function, flatten: 3}
@spec flatten(map | [map], map | nil, Options.t() | Enum.t()) :: [map]
def flatten(input, context \\ nil, options \\ %Options{}) do
... | 28.055961 | 185 | 0.513225 |
65b2d6fca7a0c30849527c9f1ddf600574feff68 | 4,267 | ex | Elixir | lib/andy/systems/brickpi/sensors/lego_sensor.ex | jfcloutier/andy | 74b93f734d6f6353356041a603a96ad5aed4b5dc | [
"MIT"
] | 7 | 2019-05-29T22:55:25.000Z | 2021-08-22T18:38:29.000Z | lib/andy/systems/brickpi/sensors/lego_sensor.ex | jfcloutier/andy | 74b93f734d6f6353356041a603a96ad5aed4b5dc | [
"MIT"
] | null | null | null | lib/andy/systems/brickpi/sensors/lego_sensor.ex | jfcloutier/andy | 74b93f734d6f6353356041a603a96ad5aed4b5dc | [
"MIT"
] | 1 | 2020-01-25T20:46:43.000Z | 2020-01-25T20:46:43.000Z | defmodule Andy.BrickPi.LegoSensor do
@moduledoc "Lego sensor access."
require Logger
import Andy.BrickPi.Sysfs
alias Andy.Device
alias Andy.BrickPi.{
ColorSensor,
TouchSensor,
InfraredSensor,
UltrasonicSensor,
GyroSensor,
IRSeekerSensor
}
@sys_path "/sys/class/lego-sensor"
@pr... | 24.107345 | 110 | 0.623389 |
65b2e0a3f94bf434dc15f817398e923d7e1f46fd | 3,146 | ex | Elixir | apps/site/lib/site/icalendar_generator.ex | noisecapella/dotcom | d5ef869412102d2230fac3dcc216f01a29726227 | [
"MIT"
] | 42 | 2019-05-29T16:05:30.000Z | 2021-08-09T16:03:37.000Z | apps/site/lib/site/icalendar_generator.ex | noisecapella/dotcom | d5ef869412102d2230fac3dcc216f01a29726227 | [
"MIT"
] | 872 | 2019-05-29T17:55:50.000Z | 2022-03-30T09:28:43.000Z | apps/site/lib/site/icalendar_generator.ex | noisecapella/dotcom | d5ef869412102d2230fac3dcc216f01a29726227 | [
"MIT"
] | 12 | 2019-07-01T18:33:21.000Z | 2022-03-10T02:13:57.000Z | defmodule Site.IcalendarGenerator do
@moduledoc """
Takes event information and generates an ICS file.
File validation was checked with https://icalendar.org/validator.html.
"""
import SiteWeb.CmsRouterHelpers, only: [event_path: 3]
alias CMS.Page.Event
@spec to_ical(Plug.Conn.t(), Event.t()) :: iodata... | 25.577236 | 93 | 0.616974 |
65b2e306c9e168bd8b17620e6221fa46869eb459 | 3,202 | exs | Elixir | test/config/config.exs | danoph/nerves_system_rpi3_ble | 1d2306de2670145ac8c6b5c79c85a5f042623448 | [
"Apache-2.0"
] | null | null | null | test/config/config.exs | danoph/nerves_system_rpi3_ble | 1d2306de2670145ac8c6b5c79c85a5f042623448 | [
"Apache-2.0"
] | null | null | null | test/config/config.exs | danoph/nerves_system_rpi3_ble | 1d2306de2670145ac8c6b5c79c85a5f042623448 | [
"Apache-2.0"
] | null | null | null | use Mix.Config
# Repository specific configuration
system = :nerves_system_rpi3_ble
platform = "rpi3_ble"
arch = "arm"
app_part_devparth = "/dev/mmcblk0p3"
network_interface = System.get_env("NERVES_NETWORK_INTERFACE") || "eth0"
# Environment specific configuration
# Nerves Project test farm configuration
# NERVE... | 36.386364 | 86 | 0.766396 |
65b2ebed27114df3ab66fc77e3eab26233cc8b3c | 50,805 | ex | Elixir | lib/elixir/lib/macro.ex | zillou/elixir | 2cd4f2178299abfc783f399d5b9fdc0c902c3776 | [
"Apache-2.0"
] | null | null | null | lib/elixir/lib/macro.ex | zillou/elixir | 2cd4f2178299abfc783f399d5b9fdc0c902c3776 | [
"Apache-2.0"
] | null | null | null | lib/elixir/lib/macro.ex | zillou/elixir | 2cd4f2178299abfc783f399d5b9fdc0c902c3776 | [
"Apache-2.0"
] | null | null | null | import Kernel, except: [to_string: 1]
defmodule Macro do
@moduledoc ~S"""
Macros are compile-time constructs that are invoked with Elixir's AST
as input and a superset of Elixir's AST as output.
Let's see a simple example that shows the difference between functions and macros:
defmodule Example do
... | 30.959781 | 103 | 0.616849 |
65b2f153bc5f825820c488c85f6d5fcdf39ea9b1 | 5,576 | ex | Elixir | lib/inline.ex | ericgroom/inline | d8b8f4fda3b653dde8e4c26aecdc90ff4da623eb | [
"MIT"
] | 2 | 2020-12-15T12:17:16.000Z | 2021-03-16T04:05:25.000Z | lib/inline.ex | ericgroom/inline | d8b8f4fda3b653dde8e4c26aecdc90ff4da623eb | [
"MIT"
] | null | null | null | lib/inline.ex | ericgroom/inline | d8b8f4fda3b653dde8e4c26aecdc90ff4da623eb | [
"MIT"
] | null | null | null | defmodule Inline do
@moduledoc """
# Overview
Inline is a tiny testing library for helping you develop faster.
The idea behind Inline is to help you develop faster, not completely replace
your existing unit tests. You may even decide just to use Inline while experimenting
and eventually convert your Inline... | 26.807692 | 106 | 0.642575 |
65b321db04ea57ffc1d1c364d706ff5fa5a542b2 | 739 | ex | Elixir | lib/grizzly/zwave/commands/thermostat_fan_mode_get.ex | jellybob/grizzly | 290bee04cb16acbb9dc996925f5c501697b7ac94 | [
"Apache-2.0"
] | 76 | 2019-09-04T16:56:58.000Z | 2022-03-29T06:54:36.000Z | lib/grizzly/zwave/commands/thermostat_fan_mode_get.ex | jellybob/grizzly | 290bee04cb16acbb9dc996925f5c501697b7ac94 | [
"Apache-2.0"
] | 124 | 2019-09-05T14:01:24.000Z | 2022-02-28T22:58:14.000Z | lib/grizzly/zwave/commands/thermostat_fan_mode_get.ex | jellybob/grizzly | 290bee04cb16acbb9dc996925f5c501697b7ac94 | [
"Apache-2.0"
] | 10 | 2019-10-23T19:25:45.000Z | 2021-11-17T13:21:20.000Z | defmodule Grizzly.ZWave.Commands.ThermostatFanModeGet do
@moduledoc """
This module implements command THERMOSTAT_FAN_MODE_GET of the
COMMAND_CLASS_THERMOSTAT_FAN_MODE command class
This command is used to request the fan mode.
Params: -none-
"""
@behaviour Grizzly.ZWave.Command
alias Grizzly.ZWave... | 18.948718 | 63 | 0.700947 |
65b3266e383d35211cdf6d35aee5f465eaf98a29 | 11,101 | ex | Elixir | clients/webmaster/lib/google_api/webmaster/v3/api/sitemaps.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2021-12-20T03:40:53.000Z | 2021-12-20T03:40:53.000Z | clients/webmaster/lib/google_api/webmaster/v3/api/sitemaps.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2020-08-18T00:11:23.000Z | 2020-08-18T00:44:16.000Z | clients/webmaster/lib/google_api/webmaster/v3/api/sitemaps.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... | 42.696154 | 187 | 0.622016 |
65b32ab4087e4dee12a0e0018e267103db939b39 | 63,489 | ex | Elixir | lib/generated/break.ex | xinz/chinese_name | 922cf27fe1204db1152f111d162f010e6555b6ba | [
"MIT"
] | null | null | null | lib/generated/break.ex | xinz/chinese_name | 922cf27fe1204db1152f111d162f010e6555b6ba | [
"MIT"
] | null | null | null | lib/generated/break.ex | xinz/chinese_name | 922cf27fe1204db1152f111d162f010e6555b6ba | [
"MIT"
] | null | null | null | defmodule ChineseName.Generated.Break do
@moduledoc false
def split("伊尔根觉罗" <> given_name), do: {"伊尔根觉罗", given_name}
def split("叶赫纳兰" <> given_name), do: {"叶赫纳兰", given_name}
def split("额尔德特" <> given_name), do: {"额尔德特", given_name}
def split("讷殷富察" <> given_name), do: {"讷殷富察", given_name}
def split("依尔觉罗... | 53.987245 | 61 | 0.594229 |
65b340645f2b90fc097459850ad7e783fcabbea0 | 222 | exs | Elixir | priv/repo/migrations/20181115205414_add_is_digest_enabled_to_space_users.exs | mindriot101/level | 0a2cbae151869c2d9b79b3bfb388f5d00739ae12 | [
"Apache-2.0"
] | 928 | 2018-04-03T16:18:11.000Z | 2019-09-09T17:59:55.000Z | priv/repo/migrations/20181115205414_add_is_digest_enabled_to_space_users.exs | mindriot101/level | 0a2cbae151869c2d9b79b3bfb388f5d00739ae12 | [
"Apache-2.0"
] | 74 | 2018-04-03T00:46:50.000Z | 2019-03-10T18:57:27.000Z | priv/repo/migrations/20181115205414_add_is_digest_enabled_to_space_users.exs | mindriot101/level | 0a2cbae151869c2d9b79b3bfb388f5d00739ae12 | [
"Apache-2.0"
] | 89 | 2018-04-03T17:33:20.000Z | 2019-08-19T03:40:20.000Z | defmodule Level.Repo.Migrations.AddIsDigestEnabledToSpaceUsers do
use Ecto.Migration
def change do
alter table(:space_users) do
add :is_digest_enabled, :boolean, null: false, default: true
end
end
end
| 22.2 | 66 | 0.747748 |
65b38ce069506b6e34e62be22207c3e5d045aded | 593 | exs | Elixir | mix.exs | mrluc/exreps | e9a8738125791f1c9da14fb0b704bcce589d831a | [
"MIT"
] | 1 | 2020-08-09T12:15:57.000Z | 2020-08-09T12:15:57.000Z | mix.exs | mrluc/exreps | e9a8738125791f1c9da14fb0b704bcce589d831a | [
"MIT"
] | null | null | null | mix.exs | mrluc/exreps | e9a8738125791f1c9da14fb0b704bcce589d831a | [
"MIT"
] | null | null | null | defmodule SpacedRepetitions.Mixfile do
use Mix.Project
@description "Spaced repetitions library with basic sm2 implementation"
@package [
files: [ "lib", "mix.exs", "README.md", "LICENSE.md"],
contributors: [ "github/mrluc" ],
licenses: [ "MIT" ],
links: %{"Github" => "https://github.com/mrluc/... | 21.962963 | 73 | 0.559865 |
65b395c8bc84dedf14063a78186f80bfdee4015d | 2,020 | ex | Elixir | apps/omg_watcher_info/lib/omg_watcher_info/application.ex | omisego/elixir-omg | 2c68973d8f29033d137f63a6e060f12e2a7dcd59 | [
"Apache-2.0"
] | 177 | 2018-08-24T03:51:02.000Z | 2020-05-30T13:29:25.000Z | apps/omg_watcher_info/lib/omg_watcher_info/application.ex | omisego/elixir-omg | 2c68973d8f29033d137f63a6e060f12e2a7dcd59 | [
"Apache-2.0"
] | 1,042 | 2018-08-25T00:52:39.000Z | 2020-06-01T05:15:17.000Z | apps/omg_watcher_info/lib/omg_watcher_info/application.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... | 29.705882 | 120 | 0.694059 |
65b3a114212817246abd5e3207f5611076478d10 | 384 | ex | Elixir | apps/re/lib/accounts/notification_preferences.ex | ruby2elixir/emcasa-backend | 70d7f4f233555417941ffa6ada84cf8740c21dd2 | [
"MIT"
] | 4 | 2019-11-01T16:29:31.000Z | 2020-10-10T21:20:12.000Z | apps/re/lib/accounts/notification_preferences.ex | caspg/backend | 34df9dc14ab8ed75de4578fefa2e087580c7e867 | [
"MIT"
] | null | null | null | apps/re/lib/accounts/notification_preferences.ex | caspg/backend | 34df9dc14ab8ed75de4578fefa2e087580c7e867 | [
"MIT"
] | 5 | 2019-11-04T21:25:45.000Z | 2020-02-13T23:49:36.000Z | defmodule Re.Accounts.NotificationPreferences do
@moduledoc """
Embedded schema for notification prefenreces
"""
use Ecto.Schema
import Ecto.Changeset
embedded_schema do
field :email, :boolean, default: true
field :app, :boolean, default: true
end
@attributes ~w(email app)a
def changeset(st... | 22.588235 | 77 | 0.713542 |
65b3a63d9a3fa13994e31528e36c35ed79b555a9 | 18,937 | ex | Elixir | lib/elixir/lib/supervisor.ex | diogovk/elixir | 7b8213affaad38b50afaa3dfc3a43717f35ba4e7 | [
"Apache-2.0"
] | null | null | null | lib/elixir/lib/supervisor.ex | diogovk/elixir | 7b8213affaad38b50afaa3dfc3a43717f35ba4e7 | [
"Apache-2.0"
] | null | null | null | lib/elixir/lib/supervisor.ex | diogovk/elixir | 7b8213affaad38b50afaa3dfc3a43717f35ba4e7 | [
"Apache-2.0"
] | null | null | null | defmodule Supervisor do
@moduledoc ~S"""
A behaviour module for implementing supervision functionality.
A supervisor is a process which supervises other processes, called
child processes. Supervisors are used to build a hierarchical process
structure called a supervision tree, a nice way to structure fault-t... | 38.102616 | 92 | 0.706131 |
65b3f3e535eb1c03cb97084214465536bdd58e9a | 153 | ex | Elixir | lib/cache/channel.ex | SpaceEEC/crux_cache | 359194162b3c12da16e44fb29dacd02f99eb0148 | [
"MIT"
] | 2 | 2018-05-22T07:13:50.000Z | 2018-07-05T13:51:42.000Z | lib/cache/channel.ex | SpaceEEC/crux_cache | 359194162b3c12da16e44fb29dacd02f99eb0148 | [
"MIT"
] | null | null | null | lib/cache/channel.ex | SpaceEEC/crux_cache | 359194162b3c12da16e44fb29dacd02f99eb0148 | [
"MIT"
] | null | null | null | defmodule Crux.Cache.Channel do
@moduledoc """
Default `Crux.Structs.Channel` cache.
"""
use Crux.Cache.Base, struct: Crux.Structs.Channel
end
| 21.857143 | 51 | 0.712418 |
65b42b16a30097cc1743613bb52e125436080097 | 3,522 | ex | Elixir | lib/mix/lib/mix/tasks/local.rebar.ex | diogovk/elixir | 7b8213affaad38b50afaa3dfc3a43717f35ba4e7 | [
"Apache-2.0"
] | null | null | null | lib/mix/lib/mix/tasks/local.rebar.ex | diogovk/elixir | 7b8213affaad38b50afaa3dfc3a43717f35ba4e7 | [
"Apache-2.0"
] | null | null | null | lib/mix/lib/mix/tasks/local.rebar.ex | diogovk/elixir | 7b8213affaad38b50afaa3dfc3a43717f35ba4e7 | [
"Apache-2.0"
] | null | null | null | defmodule Mix.Tasks.Local.Rebar do
use Mix.Task
@rebar2_list_url "/installs/rebar-1.x.csv"
@rebar2_escript_url "/installs/[ELIXIR_VERSION]/rebar-[REBAR_VERSION]"
@rebar3_list_url "/installs/rebar3-1.x.csv"
@rebar3_escript_url "/installs/[ELIXIR_VERSION]/rebar3-[REBAR_VERSION]"
@shortdoc "Instal... | 32.611111 | 85 | 0.650767 |
65b4320669a28e8653f1fcaf47afe41134888d46 | 13,023 | ex | Elixir | clients/admin/lib/google_api/admin/directory_v1/api/domain_aliases.ex | MasashiYokota/elixir-google-api | 975dccbff395c16afcb62e7a8e411fbb58e9ab01 | [
"Apache-2.0"
] | null | null | null | clients/admin/lib/google_api/admin/directory_v1/api/domain_aliases.ex | MasashiYokota/elixir-google-api | 975dccbff395c16afcb62e7a8e411fbb58e9ab01 | [
"Apache-2.0"
] | 1 | 2020-12-18T09:25:12.000Z | 2020-12-18T09:25:12.000Z | clients/admin/lib/google_api/admin/directory_v1/api/domain_aliases.ex | MasashiYokota/elixir-google-api | 975dccbff395c16afcb62e7a8e411fbb58e9ab01 | [
"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... | 44.145763 | 196 | 0.619903 |
65b49b1117bb0c256f3911314db0f4d1719eb0a7 | 21,375 | exs | Elixir | test/phoenix/router/helpers_test.exs | alanpeabody/phoenix | 94e38415da40e0b317c30e1d114dd05594955d95 | [
"MIT"
] | null | null | null | test/phoenix/router/helpers_test.exs | alanpeabody/phoenix | 94e38415da40e0b317c30e1d114dd05594955d95 | [
"MIT"
] | null | null | null | test/phoenix/router/helpers_test.exs | alanpeabody/phoenix | 94e38415da40e0b317c30e1d114dd05594955d95 | [
"MIT"
] | 1 | 2020-02-08T16:23:00.000Z | 2020-02-08T16:23:00.000Z | defmodule Phoenix.Router.HelpersTest do
use ExUnit.Case, async: true
use RouterHelper
alias Phoenix.Router.Helpers
## Unit tests
test "defhelper with :identifiers" do
route = build(:match, :get, "/foo/:bar", nil, Hello, :world, "hello_world")
assert extract_defhelper(route, 0) == String.strip """
... | 41.264479 | 157 | 0.655158 |
65b4bee515de82174030be5aa4cc868431e171c3 | 1,606 | ex | Elixir | lib/guess_who/contenders/by_attributes.ex | alanvoss/guess_who | 75227d97202283ffeeb6134fb8b2a591a9c49fbe | [
"MIT"
] | null | null | null | lib/guess_who/contenders/by_attributes.ex | alanvoss/guess_who | 75227d97202283ffeeb6134fb8b2a591a9c49fbe | [
"MIT"
] | null | null | null | lib/guess_who/contenders/by_attributes.ex | alanvoss/guess_who | 75227d97202283ffeeb6134fb8b2a591a9c49fbe | [
"MIT"
] | 3 | 2021-10-07T23:28:18.000Z | 2021-10-08T00:54:14.000Z | defmodule GuessWho.Contenders.ByAttributes do
@behaviour GuessWho.Contender
alias GuessWho.Attributes
@impl true
def name() do
"JowensByAttributes"
end
@impl true
def turn(nil, nil) do
first = "male"
state = %{
remaining_characters: Attributes.characters(),
attribute: first,
... | 20.857143 | 98 | 0.673101 |
65b4c267d248538b095636a42f84ce742d4c9f27 | 3,127 | ex | Elixir | lib/prx_access.ex | PRX/prx_access-elixir | 14b37ce614d32ddef49103fb6e91d2968255153a | [
"MIT"
] | null | null | null | lib/prx_access.ex | PRX/prx_access-elixir | 14b37ce614d32ddef49103fb6e91d2968255153a | [
"MIT"
] | null | null | null | lib/prx_access.ex | PRX/prx_access-elixir | 14b37ce614d32ddef49103fb6e91d2968255153a | [
"MIT"
] | null | null | null | defmodule PrxAccess do
@moduledoc """
Client library for accessing PRX APIs
"""
alias PrxAccess.Auth
alias PrxAccess.Remote
alias PrxAccess.Resource
alias PrxAccess.Resource.Link
alias PrxAccess.Error
@doc """
Get any resource by url
"""
def get("" <> url, opts \\ []) do
{token, opts} = Ke... | 26.277311 | 84 | 0.597058 |
65b4f0722001379daf45a8e348337a5dc8a3461b | 397 | exs | Elixir | contest/b_nom_de_groupe/sol/b_nom_de_groupe.exs | totorigolo/coding-battle2020 | 0eee321848e3c6afdfa23be9bea479c6e6b40d0a | [
"MIT"
] | 1 | 2020-10-25T15:43:43.000Z | 2020-10-25T15:43:43.000Z | contest/b_nom_de_groupe/sol/b_nom_de_groupe.exs | totorigolo/coding-battle2020 | 0eee321848e3c6afdfa23be9bea479c6e6b40d0a | [
"MIT"
] | 14 | 2020-10-18T21:28:17.000Z | 2021-02-28T13:07:29.000Z | contest/b_nom_de_groupe/sol/b_nom_de_groupe.exs | totorigolo/coding-battle2020 | 0eee321848e3c6afdfa23be9bea479c6e6b40d0a | [
"MIT"
] | 11 | 2020-10-18T18:49:09.000Z | 2021-11-05T20:35:58.000Z | groupName = IO.read(:stdio, :line) |> String.trim()
nbVowels = Enum.count(String.codepoints(groupName), fn c -> c =~ ~r/[aeiouy]/ end)
nbConsonants = String.length(groupName) - nbVowels
score = 2 * nbVowels - nbConsonants
score = score + if String.contains?(groupName, "ker"), do: 5, else: 0
score = score * if score >... | 36.090909 | 86 | 0.68262 |
65b51162b3573602bc714868649ba0c607b1b8d0 | 1,196 | exs | Elixir | phone-number/phone_number.exs | wobh/xelixir | 63e5beec40d5c441cf6cf87f30c29848f481bb1b | [
"MIT"
] | null | null | null | phone-number/phone_number.exs | wobh/xelixir | 63e5beec40d5c441cf6cf87f30c29848f481bb1b | [
"MIT"
] | null | null | null | phone-number/phone_number.exs | wobh/xelixir | 63e5beec40d5c441cf6cf87f30c29848f481bb1b | [
"MIT"
] | null | null | null | defmodule Phone do
@doc """
Remove formatting from a phone number.
Returns "0000000000" if phone number is not valid
(10 digits or "1" followed by 10 digits)
## Examples
iex> Phone.number("123-456-7890")
"1234567890"
iex> Phone.number("+1 (303) 555-1212")
"3035551212"
iex> Phone.number("867.530... | 17.588235 | 53 | 0.647993 |
65b517de4d1e9b1060b18f1d0d5e551fe2743a9b | 7,428 | ex | Elixir | lib/livebook/runtime.ex | alaadahmed/livebook | 24668c6edb6ee638a3f5291b27bd42a3dfc0c18d | [
"Apache-2.0"
] | 1,846 | 2021-04-13T14:46:36.000Z | 2021-07-14T20:37:40.000Z | lib/livebook/runtime.ex | alaadahmed/livebook | 24668c6edb6ee638a3f5291b27bd42a3dfc0c18d | [
"Apache-2.0"
] | 411 | 2021-07-15T07:41:54.000Z | 2022-03-31T21:34:22.000Z | lib/livebook/runtime.ex | alaadahmed/livebook | 24668c6edb6ee638a3f5291b27bd42a3dfc0c18d | [
"Apache-2.0"
] | 130 | 2021-04-13T15:43:55.000Z | 2021-07-12T16:57:46.000Z | defprotocol Livebook.Runtime do
@moduledoc false
# This protocol defines an interface for evaluation backends.
#
# Usually a runtime involves a set of processes responsible
# for evaluation, which could be running on a different node,
# however the protocol does not require that.
@typedoc """
An arbit... | 30.567901 | 94 | 0.683495 |
65b53bf0179f26f75e1a17738dd09b90cb088c3f | 1,872 | ex | Elixir | lib/logger_logstash_backend.ex | defndaines/logger_logstash_backend | 0670cda41374a3d899dbd3aa00780ced08a9b9f5 | [
"Apache-2.0"
] | null | null | null | lib/logger_logstash_backend.ex | defndaines/logger_logstash_backend | 0670cda41374a3d899dbd3aa00780ced08a9b9f5 | [
"Apache-2.0"
] | null | null | null | lib/logger_logstash_backend.ex | defndaines/logger_logstash_backend | 0670cda41374a3d899dbd3aa00780ced08a9b9f5 | [
"Apache-2.0"
] | null | null | null | defmodule Logger.Backends.Logstash do
use GenEvent
@default_format "$time $level $node $message\n"
def init([_]) do
{:ok, socket} = :gen_udp.open(0)
{:ok, configure([socket: socket])}
end
def handle_call({:configure, opts}, %{name: _name}) do
{:ok, :ok, configure(opts)}
end
def handle_even... | 31.728814 | 88 | 0.634615 |
65b57291c48c975de90953312f0ad0bd949886b5 | 1,819 | exs | Elixir | config/dev.exs | lairjr/go_champs_api | 01cb3ff2c655910839e5caf4282a8e50543e32a1 | [
"MIT"
] | null | null | null | config/dev.exs | lairjr/go_champs_api | 01cb3ff2c655910839e5caf4282a8e50543e32a1 | [
"MIT"
] | 5 | 2021-09-29T04:01:54.000Z | 2021-11-02T03:11:52.000Z | config/dev.exs | lairjr/tournamentsapi | dde8f8f659074527d3861391af3ab29f070179f2 | [
"MIT"
] | 1 | 2021-11-02T14:43:15.000Z | 2021-11-02T14:43:15.000Z | use Mix.Config
# For development, we disable any cache and enable
# debugging and code reloading.
#
# The watchers configuration can be used to run external
# watchers to your application. For example, we use it
# with webpack to recompile .js and .css sources.
config :go_champs_api, GoChampsApiWeb.Endpoint,
http: [... | 31.362069 | 68 | 0.725673 |
65b57b0d469439237d8c2acef9aeb24c85c570cd | 1,545 | ex | Elixir | deps/gettext/lib/gettext/po/translation.ex | luishendrix92/exrez | c9a001ff32c2081449ce190d151e7df09a0a42ee | [
"MIT"
] | null | null | null | deps/gettext/lib/gettext/po/translation.ex | luishendrix92/exrez | c9a001ff32c2081449ce190d151e7df09a0a42ee | [
"MIT"
] | 1 | 2020-07-17T10:07:44.000Z | 2020-07-17T10:07:44.000Z | teachme/deps/gettext/lib/gettext/po/translation.ex | kodeklubben-sandefjord/kodeklubben-sandefjord.github.io | 89351bceb132f87b1d2a0bcb325fb278d7ad48a4 | [
"MIT"
] | null | null | null | defmodule Gettext.PO.Translation do
@moduledoc """
A struct that holds information on a translation.
This struct describes a translation that has no plural form, such as the one
in the following snippet of `.po` file:
msgid "Hello world!"
msgstr "Ciao mondo!"
Translations with a plural form are... | 30.294118 | 84 | 0.612298 |
65b5c50007ec0c9f64489a28625077ebda7142cc | 1,132 | ex | Elixir | lib/credo/service/source_file_issues.ex | rodrigues/credo | b4e08477a2141d5537d8fc9c5cc08ebf93a5ee23 | [
"MIT"
] | null | null | null | lib/credo/service/source_file_issues.ex | rodrigues/credo | b4e08477a2141d5537d8fc9c5cc08ebf93a5ee23 | [
"MIT"
] | null | null | null | lib/credo/service/source_file_issues.ex | rodrigues/credo | b4e08477a2141d5537d8fc9c5cc08ebf93a5ee23 | [
"MIT"
] | null | null | null | defmodule Credo.Service.SourceFileIssues do
use GenServer
alias Credo.SourceFile
@table_name __MODULE__
def start_link(opts \\ []) do
{:ok, _pid} = GenServer.start_link(__MODULE__, opts, name: __MODULE__)
end
def append(%SourceFile{filename: filename}, issue) do
GenServer.call(__MODULE__, {:appe... | 24.608696 | 74 | 0.684629 |
65b5ecd37e85fd216d92a9fa583709269c5e2bf9 | 1,145 | exs | Elixir | test/ratatouille/renderer/element/tree_test.exs | krgn/ratatouille | b5ed610c7e8fe64f6be372144c1d3a670b6fabed | [
"MIT"
] | null | null | null | test/ratatouille/renderer/element/tree_test.exs | krgn/ratatouille | b5ed610c7e8fe64f6be372144c1d3a670b6fabed | [
"MIT"
] | null | null | null | test/ratatouille/renderer/element/tree_test.exs | krgn/ratatouille | b5ed610c7e8fe64f6be372144c1d3a670b6fabed | [
"MIT"
] | null | null | null | defmodule Ratatouille.Renderer.TreeTest do
use ExUnit.Case, async: true
alias Ratatouille.Renderer.Canvas
alias Ratatouille.Renderer.Element.Tree
import Ratatouille.View
describe "render/3" do
test "renders a tree with nested nodes" do
canvas =
Tree.render(
Canvas.from_dimension... | 22.019231 | 55 | 0.457642 |
65b61bf637ac298078a8c5cb20e53e90cc08cd12 | 583 | exs | Elixir | config/test.exs | cruessler/lafamiglia | 084915a2d44a5e69fb6ad9321eac08ced0e3016a | [
"MIT"
] | 5 | 2016-10-20T10:00:59.000Z | 2017-11-19T08:14:18.000Z | config/test.exs | cruessler/lafamiglia | 084915a2d44a5e69fb6ad9321eac08ced0e3016a | [
"MIT"
] | 39 | 2020-04-22T05:27:32.000Z | 2022-03-13T17:22:26.000Z | config/test.exs | cruessler/lafamiglia | 084915a2d44a5e69fb6ad9321eac08ced0e3016a | [
"MIT"
] | null | null | null | use Mix.Config
# We don't run a server during test. If one is required,
# you can enable the server option below.
config :la_famiglia, LaFamigliaWeb.Endpoint,
http: [port: 4001],
server: false,
secret_key_base: String.duplicate("a", 64)
# Print only warnings and errors during test
config :logger, level: :warn
... | 27.761905 | 56 | 0.749571 |
65b6460109330fc68fd312b93feb7396b816d332 | 1,106 | ex | Elixir | frontiers_site/test/support/conn_case.ex | wasmCloud/frontiers | 20eb6f4f7e59332341cd3973869758c670b54e2c | [
"Apache-2.0"
] | 1 | 2021-06-13T22:12:50.000Z | 2021-06-13T22:12:50.000Z | frontiers_site/test/support/conn_case.ex | wasmCloud/frontiers | 20eb6f4f7e59332341cd3973869758c670b54e2c | [
"Apache-2.0"
] | null | null | null | frontiers_site/test/support/conn_case.ex | wasmCloud/frontiers | 20eb6f4f7e59332341cd3973869758c670b54e2c | [
"Apache-2.0"
] | null | null | null | defmodule FrontiersSiteWeb.ConnCase do
@moduledoc """
This module defines the test case to be used by
tests that require setting up a connection.
Such tests rely on `Phoenix.ConnTest` and also
import other functionality to make it easier
to build common data structures and query the data layer.
Finally,... | 29.105263 | 67 | 0.74141 |
65b67297594d286bd9d79cc9776988bea6fb03d7 | 4,391 | ex | Elixir | lib/elixir/lib/gen_event/stream.ex | Tica2/elixir | 6cf1dcbfe4572fc75619f05e40c10fd0844083ef | [
"Apache-2.0"
] | null | null | null | lib/elixir/lib/gen_event/stream.ex | Tica2/elixir | 6cf1dcbfe4572fc75619f05e40c10fd0844083ef | [
"Apache-2.0"
] | null | null | null | lib/elixir/lib/gen_event/stream.ex | Tica2/elixir | 6cf1dcbfe4572fc75619f05e40c10fd0844083ef | [
"Apache-2.0"
] | null | null | null | defmodule GenEvent.Stream do
@moduledoc """
Defines a `GenEvent` stream.
This is a struct returned by `stream/2`. The struct is public and
contains the following fields:
* `:manager` - the manager reference given to `GenEvent.stream/2`
* `:timeout` - the timeout between events, defaults to `:infinit... | 26.293413 | 100 | 0.586427 |
65b6ac9623767a9de4809625c22dbab825f7e41d | 3,584 | ex | Elixir | lib/tesla/middleware/form_urlencoded.ex | moosecodebv/tesla | eb919a534aa115e7d1555d0c833fa2ebecbe5b9e | [
"MIT"
] | 1 | 2019-06-25T07:01:01.000Z | 2019-06-25T07:01:01.000Z | lib/tesla/middleware/form_urlencoded.ex | moosecodebv/tesla | eb919a534aa115e7d1555d0c833fa2ebecbe5b9e | [
"MIT"
] | null | null | null | lib/tesla/middleware/form_urlencoded.ex | moosecodebv/tesla | eb919a534aa115e7d1555d0c833fa2ebecbe5b9e | [
"MIT"
] | null | null | null | defmodule Tesla.Middleware.FormUrlencoded do
@moduledoc """
Send request body as `application/x-www-form-urlencoded`.
Performs encoding of `body` from a `Map` such as `%{"foo" => "bar"}` into
url encoded data.
Performs decoding of the response into a map when urlencoded and content-type
is `application/x-... | 23.735099 | 84 | 0.652344 |
65b6b77cba16d438fb350c24a212d76add6be607 | 378 | exs | Elixir | test/toolshed_test.exs | fhunleth/toolbag | 6eda196a2c0506ccad01fb437aa30b81def55eda | [
"Apache-2.0"
] | 51 | 2018-10-20T00:48:39.000Z | 2021-02-26T13:42:03.000Z | test/toolshed_test.exs | fhunleth/toolbag | 6eda196a2c0506ccad01fb437aa30b81def55eda | [
"Apache-2.0"
] | 27 | 2021-02-27T15:57:22.000Z | 2022-03-18T03:12:59.000Z | test/toolshed_test.exs | fhunleth/toolbag | 6eda196a2c0506ccad01fb437aa30b81def55eda | [
"Apache-2.0"
] | 11 | 2018-11-02T00:00:57.000Z | 2021-02-24T19:03:34.000Z | defmodule ToolshedTest do
use ExUnit.Case
import ExUnit.CaptureIO
test "cmd/1 normal printable chars" do
assert capture_io(fn ->
Toolshed.cmd("printf \"hello, world\"")
end) == "hello, world"
end
test "cmd/1 non printable chars" do
assert capture_io(fn ->
Toolshe... | 22.235294 | 52 | 0.587302 |
65b6bc428a53cc08fdf5ea731cebdbcac246155f | 405 | ex | Elixir | year_2021/lib/input_file.ex | bschmeck/advent_of_code | cbec98019c6c00444e0f4c7e15e01b1ed9ae6145 | [
"MIT"
] | null | null | null | year_2021/lib/input_file.ex | bschmeck/advent_of_code | cbec98019c6c00444e0f4c7e15e01b1ed9ae6145 | [
"MIT"
] | null | null | null | year_2021/lib/input_file.ex | bschmeck/advent_of_code | cbec98019c6c00444e0f4c7e15e01b1ed9ae6145 | [
"MIT"
] | null | null | null | defmodule InputFile do
def filename_for(n) do
day = n |> Integer.to_string() |> String.pad_leading(2, "0")
Path.join(:code.priv_dir(:year_2021), "day_#{day}.txt")
end
def contents_of(n, mode \\ :read)
def contents_of(n, :stream) do
filename_for(n)
|> File.stream!([], :line)
end
def conten... | 21.315789 | 64 | 0.619753 |
65b712f2b809a6540703df0f461f4efdcb438b82 | 864 | ex | Elixir | lib/epicenter_web/live/user_logins_live.ex | geometricservices/epi-viewpoin | ecb5316ea0f3f7299d5ff63e2de588539005ac1c | [
"Apache-2.0"
] | 5 | 2021-02-25T18:43:09.000Z | 2021-02-27T06:00:35.000Z | lib/epicenter_web/live/user_logins_live.ex | geometricservices/epi-viewpoint | ecb5316ea0f3f7299d5ff63e2de588539005ac1c | [
"Apache-2.0"
] | 3 | 2021-12-13T17:52:47.000Z | 2021-12-17T01:35:31.000Z | lib/epicenter_web/live/user_logins_live.ex | geometricservices/epi-viewpoint | ecb5316ea0f3f7299d5ff63e2de588539005ac1c | [
"Apache-2.0"
] | 1 | 2022-01-27T23:26:38.000Z | 2022-01-27T23:26:38.000Z | defmodule EpicenterWeb.UserLoginsLive do
use EpicenterWeb, :live_view
import EpicenterWeb.LiveHelpers, only: [assign_defaults: 1, assign_page_title: 2, authenticate_admin_user!: 2, ok: 1]
alias Epicenter.Accounts
alias EpicenterWeb.Format
def mount(%{"id" => id}, session, socket) do
user = Accounts.get... | 25.411765 | 119 | 0.704861 |
65b714a0251237e68252d986d4c93667d70b4346 | 822 | ex | Elixir | lib/amazon_product_advertising_client/item_search.ex | squaretwo/elixir-amazon-product-advertising-client | e62fc4928525c72971a5427d57896bfab530d718 | [
"MIT"
] | null | null | null | lib/amazon_product_advertising_client/item_search.ex | squaretwo/elixir-amazon-product-advertising-client | e62fc4928525c72971a5427d57896bfab530d718 | [
"MIT"
] | null | null | null | lib/amazon_product_advertising_client/item_search.ex | squaretwo/elixir-amazon-product-advertising-client | e62fc4928525c72971a5427d57896bfab530d718 | [
"MIT"
] | null | null | null | defmodule AmazonProductAdvertisingClient.ItemSearch do
@moduledoc """
The [ItemSearch](http://docs.aws.amazon.com/AWSECommerceService/latest/DG/ItemSearch.html) operation
"""
alias __MODULE__
alias AmazonProductAdvertisingClient.Config
defstruct "Availability": "Available",
"BrowseNode": nil,
... | 25.6875 | 102 | 0.659367 |
65b74276a693dd01b3c8a8499bca6c8d5af40e8d | 330 | ex | Elixir | lib/tnd/dice/dice_pool.ex | tndrpg/tnd | a9a348ed7ce2f3d8f55046559f9551e2607f3236 | [
"0BSD"
] | null | null | null | lib/tnd/dice/dice_pool.ex | tndrpg/tnd | a9a348ed7ce2f3d8f55046559f9551e2607f3236 | [
"0BSD"
] | 1 | 2021-05-11T14:31:58.000Z | 2021-05-11T14:31:58.000Z | lib/tnd/dice/dice_pool.ex | tndrpg/tnd | a9a348ed7ce2f3d8f55046559f9551e2607f3236 | [
"0BSD"
] | null | null | null | defmodule Tnd.Dice.DicePool do
defstruct boost: 0,
ability: 0,
proficiency: 0,
setback: 0,
difficulty: 0,
challenge: 0,
success: 0,
advantage: 0,
triumph: 0,
failure: 0,
threat: 0,
despa... | 22 | 30 | 0.430303 |
65b74ab623f7368fed80e857e74943712abf0d28 | 2,583 | ex | Elixir | clients/dataflow/lib/google_api/dataflow/v1b3/model/streaming_setup_task.ex | MasashiYokota/elixir-google-api | 975dccbff395c16afcb62e7a8e411fbb58e9ab01 | [
"Apache-2.0"
] | null | null | null | clients/dataflow/lib/google_api/dataflow/v1b3/model/streaming_setup_task.ex | MasashiYokota/elixir-google-api | 975dccbff395c16afcb62e7a8e411fbb58e9ab01 | [
"Apache-2.0"
] | 1 | 2020-12-18T09:25:12.000Z | 2020-12-18T09:25:12.000Z | clients/dataflow/lib/google_api/dataflow/v1b3/model/streaming_setup_task.ex | MasashiYokota/elixir-google-api | 975dccbff395c16afcb62e7a8e411fbb58e9ab01 | [
"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... | 43.779661 | 167 | 0.739837 |
65b766382fc5b599fefc8a520adf3cbf89964723 | 818 | ex | Elixir | lib/earmark/ast/renderer/footnote_list_renderer.ex | ZeLarpMaster/earmark | 35c9661d6647059e507c0278347e21d92351c417 | [
"Apache-1.1"
] | null | null | null | lib/earmark/ast/renderer/footnote_list_renderer.ex | ZeLarpMaster/earmark | 35c9661d6647059e507c0278347e21d92351c417 | [
"Apache-1.1"
] | null | null | null | lib/earmark/ast/renderer/footnote_list_renderer.ex | ZeLarpMaster/earmark | 35c9661d6647059e507c0278347e21d92351c417 | [
"Apache-1.1"
] | 1 | 2020-03-31T19:53:15.000Z | 2020-03-31T19:53:15.000Z | defmodule Earmark.Ast.Renderer.FootnoteListRenderer do
alias Earmark.Block
import Earmark.Helpers.AstHelpers, only: [merge_attrs: 1]
@moduledoc false
def render_footnote_list(items) do
{ "div", [{"class", "footnotes"}], [
{"hr", [], []},
{"ol", [], _render_footnote_list_items(items)}] }
en... | 24.787879 | 123 | 0.644254 |
65b79e0c50fea6ff854b65c4120bfdd5c9be4b3c | 677 | ex | Elixir | lib/sitemapper/store/s3_store.ex | cbx/sitemapper | dd9078b9d572aab45ce4be375185b92b456b088f | [
"MIT"
] | null | null | null | lib/sitemapper/store/s3_store.ex | cbx/sitemapper | dd9078b9d572aab45ce4be375185b92b456b088f | [
"MIT"
] | null | null | null | lib/sitemapper/store/s3_store.ex | cbx/sitemapper | dd9078b9d572aab45ce4be375185b92b456b088f | [
"MIT"
] | null | null | null | defmodule Sitemapper.S3Store do
@behaviour Sitemapper.Store
def write(filename, body, config) do
bucket = Keyword.fetch!(config, :bucket)
region = Keyword.get(config, :region, "us-east-1")
cache_control = Keyword.get(config, :cache_control, "must-revalidate")
props = [
{:content_type, conten... | 23.344828 | 74 | 0.657312 |
65b7cc950cd7cdacb5273d6e9226c71c49551e6d | 13,557 | ex | Elixir | lib/hex/resolver.ex | IvanIvanoff/hex | 90aa44fa8a1e59f2ae65f490edb984e4d6c853d1 | [
"Apache-2.0"
] | null | null | null | lib/hex/resolver.ex | IvanIvanoff/hex | 90aa44fa8a1e59f2ae65f490edb984e4d6c853d1 | [
"Apache-2.0"
] | null | null | null | lib/hex/resolver.ex | IvanIvanoff/hex | 90aa44fa8a1e59f2ae65f490edb984e4d6c853d1 | [
"Apache-2.0"
] | 1 | 2021-07-26T18:20:06.000Z | 2021-07-26T18:20:06.000Z | defmodule Hex.Resolver do
@moduledoc false
import Hex.Mix
require Record
alias Hex.Resolver.Backtracks
@ets :hex_ets_states
Record.defrecordp(:info, [:registry, :deps, :top_level, :ets, :repos, :backtracks])
Record.defrecordp(:request, [:app, :name, :req, :repo, :parent, :top_level])
Record.defrecord... | 28.601266 | 96 | 0.599543 |
65b7fa7a55bc46782efade6afa8c5ab19129a787 | 541 | exs | Elixir | phoenix/eiga/priv/repo/migrations/20211217225215_create_reviews_table.exs | defndaines/eiga | 89adc25dd6c7a5be86d6dc6be9dffc62ad05bdd8 | [
"Apache-2.0"
] | null | null | null | phoenix/eiga/priv/repo/migrations/20211217225215_create_reviews_table.exs | defndaines/eiga | 89adc25dd6c7a5be86d6dc6be9dffc62ad05bdd8 | [
"Apache-2.0"
] | 2 | 2016-03-10T03:04:11.000Z | 2017-02-11T17:43:44.000Z | phoenix/eiga/priv/repo/migrations/20211217225215_create_reviews_table.exs | defndaines/eiga | 89adc25dd6c7a5be86d6dc6be9dffc62ad05bdd8 | [
"Apache-2.0"
] | null | null | null | defmodule Eiga.Repo.Migrations.CreateReviewsTable do
use Ecto.Migration
def change do
create table(:reviews, primary_key: false) do
add(:review_id, :uuid,
primary_key: true,
null: false,
default: fragment("uuid_generate_v4()")
)
add(:short_title, references(:movies, c... | 25.761905 | 94 | 0.63586 |
65b7fe8080992d109572db0bd8767dde788ccf93 | 847 | ex | Elixir | lib/mix/lib/mix/scm/path.ex | joearms/elixir | 9a0f8107bd8bbd089acb96fe0041d61a05e88a9b | [
"Apache-2.0"
] | 4 | 2016-04-05T05:51:36.000Z | 2019-10-31T06:46:35.000Z | lib/mix/lib/mix/scm/path.ex | joearms/elixir | 9a0f8107bd8bbd089acb96fe0041d61a05e88a9b | [
"Apache-2.0"
] | null | null | null | lib/mix/lib/mix/scm/path.ex | joearms/elixir | 9a0f8107bd8bbd089acb96fe0041d61a05e88a9b | [
"Apache-2.0"
] | 5 | 2015-02-01T06:01:19.000Z | 2019-08-29T09:02:35.000Z | defmodule Mix.SCM.Path do
@behavior Mix.SCM
@moduledoc false
def format(opts) do
[path: opts[:path]]
end
def format_lock(_lock) do
nil
end
def accepts_options(opts) do
if raw = opts[:path] do
Keyword.put opts, :dest, Path.expand(raw)
end
end
def checked_out?(opts) do
File... | 18.822222 | 97 | 0.651712 |
65b800867cd3c71adf6c12b00393d9b2fee94521 | 2,314 | ex | Elixir | clients/classroom/lib/google_api/classroom/v1/model/feed.ex | MasashiYokota/elixir-google-api | 975dccbff395c16afcb62e7a8e411fbb58e9ab01 | [
"Apache-2.0"
] | null | null | null | clients/classroom/lib/google_api/classroom/v1/model/feed.ex | MasashiYokota/elixir-google-api | 975dccbff395c16afcb62e7a8e411fbb58e9ab01 | [
"Apache-2.0"
] | 1 | 2020-12-18T09:25:12.000Z | 2020-12-18T09:25:12.000Z | clients/classroom/lib/google_api/classroom/v1/model/feed.ex | MasashiYokota/elixir-google-api | 975dccbff395c16afcb62e7a8e411fbb58e9ab01 | [
"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... | 43.660377 | 264 | 0.745895 |
65b800fe120547cf34531c4478e81af3d1141350 | 1,497 | ex | Elixir | lib/livebook_web/live/session_live/delete_section_component.ex | lbighetti/livebook | 7b4978d00388ade3465667d62e44891417ff4bac | [
"Apache-2.0"
] | null | null | null | lib/livebook_web/live/session_live/delete_section_component.ex | lbighetti/livebook | 7b4978d00388ade3465667d62e44891417ff4bac | [
"Apache-2.0"
] | null | null | null | lib/livebook_web/live/session_live/delete_section_component.ex | lbighetti/livebook | 7b4978d00388ade3465667d62e44891417ff4bac | [
"Apache-2.0"
] | 1 | 2021-07-07T06:18:36.000Z | 2021-07-07T06:18:36.000Z | defmodule LivebookWeb.SessionLive.DeleteSectionComponent do
use LivebookWeb, :live_component
@impl true
def render(assigns) do
~L"""
<div class="p-6 pb-4 flex flex-col space-y-8">
<h3 class="text-2xl font-semibold text-gray-800">
Delete section
</h3>
<p class="text-gray-700">
... | 32.543478 | 112 | 0.603874 |
65b851fc4ea8a83819849dfef20834aa56a95426 | 432 | ex | Elixir | lib/strategy/push.ex | behind-design/ravenx-pusher | 89265ffb6c5e3a9fe026e2840abc3746c7f43df8 | [
"MIT"
] | 1 | 2017-09-02T10:44:07.000Z | 2017-09-02T10:44:07.000Z | lib/strategy/push.ex | behind-design/ravenx-pusher | 89265ffb6c5e3a9fe026e2840abc3746c7f43df8 | [
"MIT"
] | null | null | null | lib/strategy/push.ex | behind-design/ravenx-pusher | 89265ffb6c5e3a9fe026e2840abc3746c7f43df8 | [
"MIT"
] | null | null | null | defmodule RavenxPusher.Push do
@moduledoc """
RavenxPusher.Push represents a `Push` being sent through `Pusher`.
"""
defstruct data: nil,
event: nil,
channels: nil,
socket_id: nil,
sent?: false
@type t :: %__MODULE__{
data: any,
event: bina... | 21.6 | 68 | 0.527778 |
65b8632a33c1c0e433a4d6b02bcf574eb25a6da1 | 654 | ex | Elixir | lib/message_bounce_benchmark.ex | SirJosh3917/message_bounce_benchmark | 70cb0654acfb12b01bc67da661532955f84d69de | [
"MIT"
] | null | null | null | lib/message_bounce_benchmark.ex | SirJosh3917/message_bounce_benchmark | 70cb0654acfb12b01bc67da661532955f84d69de | [
"MIT"
] | null | null | null | lib/message_bounce_benchmark.ex | SirJosh3917/message_bounce_benchmark | 70cb0654acfb12b01bc67da661532955f84d69de | [
"MIT"
] | null | null | null | defmodule MessageBounceBenchmark.Application do
@moduledoc false
use Application
@impl true
@spec start(any, any) :: {:error, any} | {:ok, pid}
def start(_type, _args) do
topologies = [
gossip_example: [
strategy: Elixir.Cluster.Strategy.Gossip,
config: [
secret: "Message... | 24.222222 | 91 | 0.657492 |
65b866381a06f5f555ef3701b4e18367f69b2b7c | 1,741 | ex | Elixir | clients/identity_toolkit/lib/google_api/identity_toolkit/v3/model/identitytoolkit_relyingparty_reset_password_request.ex | GoNZooo/elixir-google-api | cf3ad7392921177f68091f3d9001f1b01b92f1cc | [
"Apache-2.0"
] | null | null | null | clients/identity_toolkit/lib/google_api/identity_toolkit/v3/model/identitytoolkit_relyingparty_reset_password_request.ex | GoNZooo/elixir-google-api | cf3ad7392921177f68091f3d9001f1b01b92f1cc | [
"Apache-2.0"
] | null | null | null | clients/identity_toolkit/lib/google_api/identity_toolkit/v3/model/identitytoolkit_relyingparty_reset_password_request.ex | GoNZooo/elixir-google-api | cf3ad7392921177f68091f3d9001f1b01b92f1cc | [
"Apache-2.0"
] | 1 | 2018-07-28T20:50:50.000Z | 2018-07-28T20:50:50.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... | 33.480769 | 114 | 0.755313 |
65b886bb4087e94855444d0eb5e4e73a7d1a533e | 708 | exs | Elixir | mix.exs | dustinspecker/conjunction | c8165bdc511889017adef2f4da4073b99fee1461 | [
"MIT"
] | 2 | 2016-12-25T14:33:11.000Z | 2017-02-01T13:19:22.000Z | mix.exs | dustinspecker/conjunction | c8165bdc511889017adef2f4da4073b99fee1461 | [
"MIT"
] | null | null | null | mix.exs | dustinspecker/conjunction | c8165bdc511889017adef2f4da4073b99fee1461 | [
"MIT"
] | null | null | null | defmodule Conjunction.Mixfile do
use Mix.Project
def project do
[
app: :conjunction,
version: "1.0.2",
elixir: "~> 1.3",
build_embedded: Mix.env == :prod,
start_permanent: Mix.env == :prod,
description: description,
package: package,
deps: deps
]
end
def... | 18.153846 | 74 | 0.577684 |
65b902552aebf470681fb9f35e08fd17f16524d3 | 739 | ex | Elixir | lib/pubsub/consumer.ex | michaeljguarino/piazza_core | 9cb24c59687db068cd16d2de94066dc85f871bc0 | [
"MIT"
] | null | null | null | lib/pubsub/consumer.ex | michaeljguarino/piazza_core | 9cb24c59687db068cd16d2de94066dc85f871bc0 | [
"MIT"
] | null | null | null | lib/pubsub/consumer.ex | michaeljguarino/piazza_core | 9cb24c59687db068cd16d2de94066dc85f871bc0 | [
"MIT"
] | null | null | null | defmodule Piazza.PubSub.Consumer do
defmacro __using__(broadcaster: broadcaster, max_demand: demand) do
quote do
use ConsumerSupervisor
def start_link(arg) do
ConsumerSupervisor.start_link(__MODULE__, arg)
end
def init(_arg) do
children = [%{id: Piazza.Consumers.Worker, s... | 29.56 | 133 | 0.695535 |
65b90cb64f27f9277438e2d0890092f428f192ae | 1,012 | ex | Elixir | lib/ElCloud/file_watcher.ex | Sapfir0/elCloud | 3ef9e8d2400898250ee65d36870672e76006c263 | [
"Unlicense"
] | 2 | 2021-05-30T20:11:44.000Z | 2021-12-20T19:08:56.000Z | lib/ElCloud/file_watcher.ex | Sapfir0/elCloud | 3ef9e8d2400898250ee65d36870672e76006c263 | [
"Unlicense"
] | null | null | null | lib/ElCloud/file_watcher.ex | Sapfir0/elCloud | 3ef9e8d2400898250ee65d36870672e76006c263 | [
"Unlicense"
] | 1 | 2022-01-23T05:29:08.000Z | 2022-01-23T05:29:08.000Z | defmodule ElCloud.Watcher do
use GenServer
require Logger
require ElCloudWeb.FileChannel
@indexes_file Application.get_env(:elCloud, ElCloud.Search.Helper)[:indexes_file]
@data_dir Application.get_env(:elCloud, ElCloudWeb.FileStorageController)[:data_dir]
def start_link(dirs) do
IO.puts(Path.absname(di... | 27.351351 | 92 | 0.724308 |
65b93021aa3564c647cf73d86c361fe8efe9b704 | 1,061 | exs | Elixir | config/dev.exs | ryo33/portable-visualixir | 130db30c4a4f15ea1d13a29c31261d9f51e491d9 | [
"MIT"
] | null | null | null | config/dev.exs | ryo33/portable-visualixir | 130db30c4a4f15ea1d13a29c31261d9f51e491d9 | [
"MIT"
] | null | null | null | config/dev.exs | ryo33/portable-visualixir | 130db30c4a4f15ea1d13a29c31261d9f51e491d9 | [
"MIT"
] | null | null | null | use Mix.Config
# For development, we disable any cache and enable
# debugging and code reloading.
#
# The watchers configuration can be used to run external
# watchers to your application. For example, we use it
# with brunch.io to recompile .js and .css sources.
config :visualixir, Visualixir.Endpoint,
http: [port:... | 31.205882 | 74 | 0.720075 |
65b935f7ba27df8c51828e717d0d8cb60a30a4b7 | 1,778 | ex | Elixir | test/support/model_case.ex | mike-north/phoenix-fundamentals-workshop | 9e6af6d1e1dde002e4b78ce4292fcf18cf527b49 | [
"BSD-3-Clause"
] | 2 | 2019-01-23T02:54:19.000Z | 2019-10-18T14:58:41.000Z | test/support/model_case.ex | mike-north/phoenix-fundamentals-workshop | 9e6af6d1e1dde002e4b78ce4292fcf18cf527b49 | [
"BSD-3-Clause"
] | 12 | 2018-01-01T06:42:36.000Z | 2022-03-26T12:45:14.000Z | test/support/model_case.ex | mike-north/phoenix-fundamentals-workshop | 9e6af6d1e1dde002e4b78ce4292fcf18cf527b49 | [
"BSD-3-Clause"
] | 1 | 2018-04-19T06:34:51.000Z | 2018-04-19T06:34:51.000Z | defmodule Eblog.ModelCase do
@moduledoc """
This module defines the test case to be used by
model tests.
You may define functions here to be used as helpers in
your model tests. See `errors_on/2`'s definition as reference.
Finally, if the test case interacts with the database,
it cannot be async. For th... | 26.939394 | 84 | 0.68279 |
65b94d5b6e7f27ef3a73f5a6b5dbde081acd74bb | 1,829 | exs | Elixir | playground_project/mix.exs | JohnBortotti/learning-elixir | 54ce9c50904e809065d0321d51367cea7a5b2bf8 | [
"MIT"
] | null | null | null | playground_project/mix.exs | JohnBortotti/learning-elixir | 54ce9c50904e809065d0321d51367cea7a5b2bf8 | [
"MIT"
] | null | null | null | playground_project/mix.exs | JohnBortotti/learning-elixir | 54ce9c50904e809065d0321d51367cea7a5b2bf8 | [
"MIT"
] | null | null | null | defmodule CrudTdd.MixProject do
use Mix.Project
def project do
[
app: :crud_tdd,
version: "0.1.0",
elixir: "~> 1.7",
elixirc_paths: elixirc_paths(Mix.env()),
compilers: [:phoenix, :gettext] ++ Mix.compilers(),
start_permanent: Mix.env() == :prod,
aliases: aliases(),
... | 27.712121 | 84 | 0.580098 |
65b98ddc1e08602afc62ceff269a2c31c5305ab9 | 312 | ex | Elixir | lib/socializer_web/data.ex | yosufali/socializer | abbd75cf1cedbf1a398fc72b64f4129e39d3e373 | [
"MIT"
] | 311 | 2019-04-21T22:15:08.000Z | 2022-01-23T14:07:03.000Z | lib/socializer_web/data.ex | yosufali/socializer | abbd75cf1cedbf1a398fc72b64f4129e39d3e373 | [
"MIT"
] | 9 | 2020-09-07T09:38:58.000Z | 2022-02-26T18:07:44.000Z | lib/socializer_web/data.ex | yosufali/socializer | abbd75cf1cedbf1a398fc72b64f4129e39d3e373 | [
"MIT"
] | 49 | 2019-04-22T01:29:50.000Z | 2022-03-23T04:34:35.000Z | defmodule SocializerWeb.Data do
import Ecto.Query
def data() do
Dataloader.Ecto.new(Socializer.Repo, query: &query/2)
end
def query(queryable, params) do
case Map.get(params, :order_by) do
nil -> queryable
order_by -> from record in queryable, order_by: ^order_by
end
end
end
| 20.8 | 63 | 0.685897 |
65b9b98b9a6c3dee7721400fb2c6e5473d89423d | 1,915 | exs | Elixir | phoenix/app/config/dev.exs | ohr486/docker-app-template | 9365f95d1102c69dba46474d0498d8306d40ed79 | [
"MIT"
] | null | null | null | phoenix/app/config/dev.exs | ohr486/docker-app-template | 9365f95d1102c69dba46474d0498d8306d40ed79 | [
"MIT"
] | null | null | null | phoenix/app/config/dev.exs | ohr486/docker-app-template | 9365f95d1102c69dba46474d0498d8306d40ed79 | [
"MIT"
] | null | null | null | use Mix.Config
# For development, we disable any cache and enable
# debugging and code reloading.
#
# The watchers configuration can be used to run external
# watchers to your application. For example, we use it
# with brunch.io to recompile .js and .css sources.
config :phx_app, PhxAppWeb.Endpoint,
http: [port: 400... | 32.457627 | 170 | 0.700783 |
65b9d71576804a0426d1b5ea007cf1d0791b5b23 | 1,950 | exs | Elixir | clients/smart_device_management/mix.exs | mcrumm/elixir-google-api | 544f22797cec52b3a23dfb6e39117f0018448610 | [
"Apache-2.0"
] | null | null | null | clients/smart_device_management/mix.exs | mcrumm/elixir-google-api | 544f22797cec52b3a23dfb6e39117f0018448610 | [
"Apache-2.0"
] | null | null | null | clients/smart_device_management/mix.exs | mcrumm/elixir-google-api | 544f22797cec52b3a23dfb6e39117f0018448610 | [
"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... | 29.104478 | 153 | 0.671282 |
65b9e8233be7e75721b75a1968073bf25b9197c5 | 115 | exs | Elixir | test/crutches/range_test.exs | mykewould/crutches | da83f233839720f79ef49f20122f6ad38f08a0a3 | [
"Apache-2.0"
] | 146 | 2015-06-26T08:16:13.000Z | 2021-12-24T08:10:51.000Z | test/crutches/range_test.exs | mykewould/crutches | da83f233839720f79ef49f20122f6ad38f08a0a3 | [
"Apache-2.0"
] | 108 | 2015-07-16T20:09:50.000Z | 2021-04-01T16:33:35.000Z | test/crutches/range_test.exs | mykewould/crutches | da83f233839720f79ef49f20122f6ad38f08a0a3 | [
"Apache-2.0"
] | 49 | 2015-06-26T19:10:43.000Z | 2020-09-21T14:57:43.000Z | defmodule Crutches.RangeTest do
alias Crutches.Range
use ExUnit.Case, async: true
doctest Crutches.Range
end
| 19.166667 | 31 | 0.791304 |
65ba0a70d2432e0279b35ae2a30a1ee38727bd58 | 1,097 | exs | Elixir | mix.exs | bmartin2015/ex_bin | efa6755271f28fb67db862ac849c4449a067e9a4 | [
"MIT"
] | null | null | null | mix.exs | bmartin2015/ex_bin | efa6755271f28fb67db862ac849c4449a067e9a4 | [
"MIT"
] | 2 | 2021-03-09T15:45:09.000Z | 2021-05-10T09:11:46.000Z | mix.exs | bmartin2015/ex_bin | efa6755271f28fb67db862ac849c4449a067e9a4 | [
"MIT"
] | null | null | null | defmodule ExBin.MixProject do
use Mix.Project
def project do
[
app: :ex_bin,
version: "0.1.0",
elixir: "~> 1.5",
elixirc_paths: elixirc_paths(Mix.env()),
compilers: [:phoenix, :gettext] ++ Mix.compilers(),
start_permanent: Mix.env() == :prod,
deps: deps()
]
end
... | 23.847826 | 57 | 0.567001 |
65ba2121d3ad90929d33234161bc08f668e63b05 | 138 | ex | Elixir | web/controllers/page_controller.ex | chasm/elm_pack | 5bbdc4df335376170b6d161bfc65f9fc7eca2648 | [
"MIT"
] | 1 | 2016-08-02T00:36:46.000Z | 2016-08-02T00:36:46.000Z | web/controllers/page_controller.ex | chasm/elm_pack | 5bbdc4df335376170b6d161bfc65f9fc7eca2648 | [
"MIT"
] | null | null | null | web/controllers/page_controller.ex | chasm/elm_pack | 5bbdc4df335376170b6d161bfc65f9fc7eca2648 | [
"MIT"
] | null | null | null | defmodule ElmPack.PageController do
use ElmPack.Web, :controller
def index(conn, _params) do
render conn, "index.html"
end
end
| 17.25 | 35 | 0.731884 |
65ba2c6c601b76f2fbae2b5e9b131e5d1b428855 | 539 | exs | Elixir | priv/repo/migrations/20160302232641_create_authorization.exs | lyncms/lyn | ef825e7ff8df049a41f9a10685324079ebe116f9 | [
"MIT"
] | 96 | 2016-02-26T20:20:33.000Z | 2020-10-02T16:21:00.000Z | priv/repo/migrations/20160302232641_create_authorization.exs | lyncms/lyn | ef825e7ff8df049a41f9a10685324079ebe116f9 | [
"MIT"
] | 12 | 2016-02-27T16:23:55.000Z | 2017-07-04T13:46:00.000Z | priv/repo/migrations/20160302232641_create_authorization.exs | lyncms/lyn | ef825e7ff8df049a41f9a10685324079ebe116f9 | [
"MIT"
] | 24 | 2016-03-10T23:55:33.000Z | 2019-06-07T18:32:34.000Z | defmodule Lyn.Repo.Migrations.CreateAuthorization do
use Ecto.Migration
def change do
create table(:authorizations) do
add :provider, :string
add :uid, :string
add :user_id, references(:users, on_delete: :delete_all)
add :token, :text
add :refresh_token, :text
add :expires_a... | 25.666667 | 66 | 0.673469 |
65ba361fd1d9c4e39c0af46c8d39f4fad3f716be | 3,706 | ex | Elixir | apps/artemis_web/lib/artemis_web/views/team_view.ex | artemis-platform/artemis_dashboard | 5ab3f5ac4c5255478bbebf76f0e43b44992e3cab | [
"MIT"
] | 9 | 2019-08-19T19:56:34.000Z | 2022-03-22T17:56:38.000Z | apps/artemis_web/lib/artemis_web/views/team_view.ex | chrislaskey/atlas_dashboard | 9009ef5aac8fefba126fa7d3e3b82d1b610ee6fe | [
"MIT"
] | 7 | 2019-07-12T21:41:01.000Z | 2020-08-17T21:29:22.000Z | apps/artemis_web/lib/artemis_web/views/team_view.ex | chrislaskey/atlas_dashboard | 9009ef5aac8fefba126fa7d3e3b82d1b610ee6fe | [
"MIT"
] | 2 | 2019-07-05T22:51:47.000Z | 2019-08-19T19:56:37.000Z | defmodule ArtemisWeb.TeamView do
use ArtemisWeb, :view
import Artemis.Helpers, only: [keys_to_atoms: 2]
alias Artemis.Permission
# Bulk Actions
def available_bulk_actions() do
[
%BulkAction{
action: &Artemis.DeleteTeam.call_many(&1, &2),
authorize: &has?(&1, "teams:delete"),
... | 26.661871 | 97 | 0.579601 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.