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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
ac941003f382ddfde63f387545ba73201533c7d2 | 2,420 | exs | Elixir | mix.exs | pragmaticivan/gandalf | d6f79489104f3b3544247856bb93679f47ec9e0d | [
"Apache-2.0",
"MIT"
] | 1 | 2018-05-01T01:34:56.000Z | 2018-05-01T01:34:56.000Z | mix.exs | pragmaticivan/gandalf | d6f79489104f3b3544247856bb93679f47ec9e0d | [
"Apache-2.0",
"MIT"
] | null | null | null | mix.exs | pragmaticivan/gandalf | d6f79489104f3b3544247856bb93679f47ec9e0d | [
"Apache-2.0",
"MIT"
] | null | null | null | defmodule Gandalf.MixProject do
use Mix.Project
@version "0.3.0"
@source_url "https://github.com/pragmaticivan/gandalf"
def project do
[
app: :gandalf,
description: description(),
aliases: aliases(),
package: package(),
version: @version,
elixir: "> 1.5.0",
elixir... | 22.616822 | 65 | 0.508264 |
ac94252831a093b6c95eca0ab2bd62e720eb4bf6 | 30,157 | ex | Elixir | lib/elixir/lib/application.ex | mguimas/elixir | 161f5f9a3b6bc38faa152e08c567486b71b0602a | [
"Apache-2.0"
] | null | null | null | lib/elixir/lib/application.ex | mguimas/elixir | 161f5f9a3b6bc38faa152e08c567486b71b0602a | [
"Apache-2.0"
] | null | null | null | lib/elixir/lib/application.ex | mguimas/elixir | 161f5f9a3b6bc38faa152e08c567486b71b0602a | [
"Apache-2.0"
] | null | null | null | defmodule Application do
@moduledoc """
A module for working with applications and defining application callbacks.
Applications are the idiomatic way to package software in Erlang/OTP. To get
the idea, they are similar to the "library" concept common in other
programming languages, but with some additional c... | 36.421498 | 94 | 0.704314 |
ac944d23ebae66dd359e44badbf4410e0b570775 | 2,282 | ex | Elixir | clients/os_config/lib/google_api/os_config/v1/model/inventory_windows_quick_fix_engineering_package.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2021-12-20T03:40:53.000Z | 2021-12-20T03:40:53.000Z | clients/os_config/lib/google_api/os_config/v1/model/inventory_windows_quick_fix_engineering_package.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2020-08-18T00:11:23.000Z | 2020-08-18T00:44:16.000Z | clients/os_config/lib/google_api/os_config/v1/model/inventory_windows_quick_fix_engineering_package.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... | 39.344828 | 231 | 0.730061 |
ac945b6ec916ea81f62a87ddfbb55f2ed27b5869 | 755 | ex | Elixir | graphql/test/support/channel_case.ex | leighshepperson/got-stats | 820e7aab68a0de39f55ed55fd18ca9e658a084ff | [
"MIT"
] | null | null | null | graphql/test/support/channel_case.ex | leighshepperson/got-stats | 820e7aab68a0de39f55ed55fd18ca9e658a084ff | [
"MIT"
] | null | null | null | graphql/test/support/channel_case.ex | leighshepperson/got-stats | 820e7aab68a0de39f55ed55fd18ca9e658a084ff | [
"MIT"
] | null | null | null | defmodule GOTStats.GraphQL.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 and query models.
Finally, if the test case interacts with the database,
it ca... | 22.205882 | 56 | 0.721854 |
ac94834a4602e8a10a0656d2c9330684a079f14e | 537 | ex | Elixir | lib/exq_batch/application.ex | ananthakumaran/exq_batch | 6771480229161fcbb544a33bead619020fe27fd1 | [
"MIT"
] | 2 | 2020-12-14T00:37:55.000Z | 2022-01-03T01:37:29.000Z | lib/exq_batch/application.ex | ananthakumaran/exq_batch | 6771480229161fcbb544a33bead619020fe27fd1 | [
"MIT"
] | null | null | null | lib/exq_batch/application.ex | ananthakumaran/exq_batch | 6771480229161fcbb544a33bead619020fe27fd1 | [
"MIT"
] | null | null | null | defmodule ExqBatch.Application do
# See https://hexdocs.pm/elixir/Application.html
# for more information on OTP Applications
@moduledoc false
use Application
def start(_type, _args) do
children = [
# Starts a worker by calling: ExqBatch.Worker.start_link(arg)
# {ExqBatch.Worker, arg}
]
... | 26.85 | 67 | 0.711359 |
ac94eb52ff4a5b321e25c7b4323d272af2262ae9 | 2,988 | ex | Elixir | lib/exop/validations/type_validation.ex | madeinussr/exop | f8559a3c3fe8eb9554f6817e679b00e071f78f61 | [
"MIT"
] | 202 | 2016-08-28T13:35:58.000Z | 2021-11-20T20:13:41.000Z | lib/exop/validations/type_validation.ex | madeinussr/exop | f8559a3c3fe8eb9554f6817e679b00e071f78f61 | [
"MIT"
] | 34 | 2016-10-25T13:04:39.000Z | 2021-05-19T07:35:35.000Z | lib/exop/validations/type_validation.ex | madeinussr/exop | f8559a3c3fe8eb9554f6817e679b00e071f78f61 | [
"MIT"
] | 22 | 2016-11-30T14:25:58.000Z | 2021-06-19T11:52:03.000Z | defmodule Exop.TypeValidation do
@known_types ~w(boolean integer float string tuple struct map list atom function keyword module uuid)a
Enum.each(@known_types, fn type ->
def type_supported?(unquote(type), _opts), do: :ok
end)
def type_supported?(nil, nil), do: :ok
def type_supported?(nil, []), do: :ok... | 29.009709 | 104 | 0.619478 |
ac9519106d9341dbbdc3cff54ac0a774973927b9 | 2,490 | exs | Elixir | mix.exs | elixirasturias/example-app | d68d3c141446cf81a9181198b22d51a41b26ce71 | [
"MIT"
] | 3 | 2018-05-31T13:06:48.000Z | 2020-01-14T03:29:30.000Z | mix.exs | elixirasturias/example-app | d68d3c141446cf81a9181198b22d51a41b26ce71 | [
"MIT"
] | null | null | null | mix.exs | elixirasturias/example-app | d68d3c141446cf81a9181198b22d51a41b26ce71 | [
"MIT"
] | null | null | null | defmodule ExampleApp.Mixfile do
use Mix.Project
def project do
[
app: :example_app,
version: "0.0.1",
elixir: "~> 1.6",
elixirc_paths: elixirc_paths(Mix.env()),
compilers: [:phoenix, :gettext] ++ Mix.compilers(),
start_permanent: Mix.env() == :prod,
aliases: aliases(),... | 27.065217 | 103 | 0.557831 |
ac9562bf82c181b97f54efb6b0b0f448bfdd35b3 | 951 | ex | Elixir | lib/plausible_web/plugs/favicon.ex | plausible-insights/plausible | 88173342b9e969894879bfb2e8d203426f6a1b1c | [
"MIT"
] | 984 | 2019-09-02T11:36:41.000Z | 2020-06-08T06:25:48.000Z | lib/plausible_web/plugs/favicon.ex | plausible-insights/plausible | 88173342b9e969894879bfb2e8d203426f6a1b1c | [
"MIT"
] | 24 | 2019-09-10T09:53:17.000Z | 2020-06-08T07:35:26.000Z | lib/plausible_web/plugs/favicon.ex | plausible-insights/plausible | 88173342b9e969894879bfb2e8d203426f6a1b1c | [
"MIT"
] | 51 | 2019-09-03T10:48:10.000Z | 2020-06-07T00:23:34.000Z | defmodule PlausibleWeb.Favicon do
import Plug.Conn
def init(_) do
domains =
case File.read(Application.app_dir(:plausible, "priv/referer_favicon_domains.json")) do
{:ok, contents} ->
Jason.decode!(contents)
_ ->
%{}
end
[favicon_domains: domains]
end
d... | 25.026316 | 93 | 0.588854 |
ac956d95e4fafc15877136e894fb91860f81e066 | 538 | exs | Elixir | test/ex_azure/server_test.exs | rschef/ex_azure | 6663914280a693f3332c65c71afdef1255c813fb | [
"MIT"
] | 10 | 2016-07-07T08:55:15.000Z | 2022-01-19T01:47:34.000Z | test/ex_azure/server_test.exs | rschef/ex_azure | 6663914280a693f3332c65c71afdef1255c813fb | [
"MIT"
] | 5 | 2018-03-06T04:42:02.000Z | 2022-03-16T23:34:42.000Z | test/ex_azure/server_test.exs | rschef/ex_azure | 6663914280a693f3332c65c71afdef1255c813fb | [
"MIT"
] | 8 | 2016-07-21T16:20:39.000Z | 2021-07-16T02:14:57.000Z | defmodule ExAzure.ServerTest do
use ExUnit.Case
@module ExAzure.Server
test "get config from state" do
config = GenServer.call(@module, :config)
assert config[:access_key] == Application.get_env(:ex_azure, :access_key)
assert config[:account] == Application.get_env(:ex_azure, :account)
end
... | 26.9 | 77 | 0.719331 |
ac9583baf9e8d3dcd0b98077f5f18fbd1ff9ce0e | 421 | exs | Elixir | exercises/raindrops/example.exs | jerith/elixir | 9a3f2a2fbee26a7b6a6b3ad74a9e6d1ff2495ed4 | [
"Apache-2.0"
] | 343 | 2017-06-22T16:28:28.000Z | 2022-03-25T21:33:32.000Z | exercises/raindrops/example.exs | jerith/elixir | 9a3f2a2fbee26a7b6a6b3ad74a9e6d1ff2495ed4 | [
"Apache-2.0"
] | 583 | 2017-06-19T10:48:40.000Z | 2022-03-28T21:43:12.000Z | exercises/raindrops/example.exs | jerith/elixir | 9a3f2a2fbee26a7b6a6b3ad74a9e6d1ff2495ed4 | [
"Apache-2.0"
] | 228 | 2017-07-05T07:09:32.000Z | 2022-03-27T08:59:08.000Z | defmodule Raindrops do
def convert(number),
do: output({[sound(number, 3), sound(number, 5), sound(number, 7)], number})
defp sound(n, 3) when rem(n, 3) == 0, do: "Pling"
defp sound(n, 5) when rem(n, 5) == 0, do: "Plang"
defp sound(n, 7) when rem(n, 7) == 0, do: "Plong"
defp sound(_, _), do: ""
defp o... | 32.384615 | 80 | 0.577197 |
ac959313e809eeef1ef424bcc20f772cba09327b | 1,807 | exs | Elixir | test/directions_test.exs | data-twister/ex_maps | c8a92b414953735e4b5eb83d676a5e35b96ad19e | [
"MIT"
] | null | null | null | test/directions_test.exs | data-twister/ex_maps | c8a92b414953735e4b5eb83d676a5e35b96ad19e | [
"MIT"
] | null | null | null | test/directions_test.exs | data-twister/ex_maps | c8a92b414953735e4b5eb83d676a5e35b96ad19e | [
"MIT"
] | null | null | null | defmodule DirectionsTest do
use ExUnit.Case, async: true
alias GoogleMaps, as: Maps
@origin "Cột mốc Quốc Gia, Đất Mũi, Ca Mau, Vietnam"
@destination "Cột cờ Lũng Cú, Đường lên Cột Cờ, Lũng Cú, Ha Giang, Vietnam"
test "directions between two addresses" do
{:ok, result} = Maps.directions(@origin, @destin... | 34.75 | 85 | 0.584947 |
ac95a4409906be7f0776106cf80c30e338102316 | 3,167 | ex | Elixir | lib/state_server.ex | iboard/state_server | 4fa6883caedaa252d27694f3ad586bedbc43f1fd | [
"MIT"
] | null | null | null | lib/state_server.ex | iboard/state_server | 4fa6883caedaa252d27694f3ad586bedbc43f1fd | [
"MIT"
] | null | null | null | lib/state_server.ex | iboard/state_server | 4fa6883caedaa252d27694f3ad586bedbc43f1fd | [
"MIT"
] | null | null | null | defmodule StateServer do
@moduledoc """
The StateServer is a module you can use in your modules to implement a simple GenServer
without the need of writting all that GenServer's boilerplate.any()
### Example
defmodule MyModule do
# make this module a GenServer and import some macros to define c... | 28.276786 | 89 | 0.617935 |
ac95abeac61e2381eae976413f5cd89e29d2b6c2 | 685 | ex | Elixir | lib/pushex/gcm/client/sandbox.ex | talkjs/pushex | e9f4d5c4d4df8165e0e712443c688e97d8d27c1e | [
"MIT"
] | null | null | null | lib/pushex/gcm/client/sandbox.ex | talkjs/pushex | e9f4d5c4d4df8165e0e712443c688e97d8d27c1e | [
"MIT"
] | null | null | null | lib/pushex/gcm/client/sandbox.ex | talkjs/pushex | e9f4d5c4d4df8165e0e712443c688e97d8d27c1e | [
"MIT"
] | 1 | 2018-12-14T08:19:28.000Z | 2018-12-14T08:19:28.000Z | defmodule Pushex.GCM.Client.Sandbox do
@moduledoc false
@behaviour Pushex.GCM.Client
def send_notification(request) do
if request.to == :bad_id do
{:error, %Pushex.GCM.HTTPError{status_code: 401, reason: "not authorized"}}
else
count = if request.registration_ids, do: Enum.count(request.regi... | 34.25 | 92 | 0.566423 |
ac95d2a20087cdce03a077b03fcad5c6513e3a5d | 2,062 | ex | Elixir | lib/commanded/registration/adapter.ex | SimpleBet/commanded | dc89737bd22daf4f6c5b3333b5d8d8de47fea5b8 | [
"MIT"
] | null | null | null | lib/commanded/registration/adapter.ex | SimpleBet/commanded | dc89737bd22daf4f6c5b3333b5d8d8de47fea5b8 | [
"MIT"
] | null | null | null | lib/commanded/registration/adapter.ex | SimpleBet/commanded | dc89737bd22daf4f6c5b3333b5d8d8de47fea5b8 | [
"MIT"
] | null | null | null | defmodule Commanded.Registration.Adapter do
@moduledoc """
Defines a behaviour for a process registry to be used by Commanded.
By default, Commanded will use a local process registry, defined in
`Commanded.Registration.LocalRegistry`, that uses Elixir's `Registry` module
for local process registration. This ... | 32.730159 | 94 | 0.658584 |
ac95dcf1c4e028af4258b6a25d64df086c47ebc5 | 688 | exs | Elixir | test/cog/chat/hipchat/templates/embedded/role_delete_test.exs | matusf/cog | 71708301c7dc570fb0d3498a50f47a70ef957788 | [
"Apache-2.0"
] | 1,003 | 2016-02-23T17:21:12.000Z | 2022-02-20T14:39:35.000Z | test/cog/chat/hipchat/templates/embedded/role_delete_test.exs | matusf/cog | 71708301c7dc570fb0d3498a50f47a70ef957788 | [
"Apache-2.0"
] | 906 | 2016-02-22T22:54:19.000Z | 2022-03-11T15:19:43.000Z | test/cog/chat/hipchat/templates/embedded/role_delete_test.exs | matusf/cog | 71708301c7dc570fb0d3498a50f47a70ef957788 | [
"Apache-2.0"
] | 95 | 2016-02-23T13:42:31.000Z | 2021-11-30T14:39:55.000Z | defmodule Cog.Chat.HipChat.Templates.Embedded.RoleDeleteTest do
use Cog.TemplateCase
test "role-delete template" do
data = %{"results" => [%{"name" => "foo"}]}
expected = "Deleted role 'foo'"
assert_rendered_template(:hipchat, :embedded, "role-delete", data, expected)
end
test "role-delete templat... | 31.272727 | 80 | 0.577035 |
ac95ed2da8ce0c939ae68ebe6e46f226d1fe3d40 | 29,462 | ex | Elixir | lib/oli_web/controllers/page_delivery_controller.ex | argos-education/oli-torus | cff73a277f80c8071217a074d9d8b650a9c068e5 | [
"MIT"
] | 1 | 2022-03-17T20:35:47.000Z | 2022-03-17T20:35:47.000Z | lib/oli_web/controllers/page_delivery_controller.ex | argos-education/oli-torus | cff73a277f80c8071217a074d9d8b650a9c068e5 | [
"MIT"
] | 1 | 2022-03-25T13:46:08.000Z | 2022-03-25T16:06:44.000Z | lib/oli_web/controllers/page_delivery_controller.ex | marc-hughes/oli-torus-1 | aa3c9bb2d91b678a365be839761eaf86c60ee35c | [
"MIT"
] | null | null | null | defmodule OliWeb.PageDeliveryController do
use OliWeb, :controller
require Logger
import OliWeb.Common.FormatDateTime
alias Oli.Delivery.Page.PageContext
alias Oli.Delivery.Sections
alias Oli.Delivery.Sections.Section
alias Oli.Delivery.Paywall
alias Oli.Delivery.Paywall.Discount
alias Oli.Rendering.... | 34.539273 | 160 | 0.651381 |
ac95f0466c6568fdf7a029f635251bf5a0bcf2f3 | 322 | exs | Elixir | config/test.exs | borodark/type_test | b58fb1fad312caad7bae92fcbe897b4dc9fbe778 | [
"MIT"
] | null | null | null | config/test.exs | borodark/type_test | b58fb1fad312caad7bae92fcbe897b4dc9fbe778 | [
"MIT"
] | null | null | null | config/test.exs | borodark/type_test | b58fb1fad312caad7bae92fcbe897b4dc9fbe778 | [
"MIT"
] | null | null | null | use Mix.Config
config :type_test, TypeTest.Repo, [
adapter: Ecto.Adapters.Postgres,
database: "type_test_#{Mix.env}",
username: "postgres",
password: "postgres",
hostname: "localhost",
pool: Ecto.Adapters.SQL.Sandbox]
config :logger,
backends: [:console],
level: :warn,
compile_time_purge_level: :inf... | 21.466667 | 35 | 0.71118 |
ac960858468a1e3de677c1bba6fc5a430a3a5435 | 1,082 | ex | Elixir | lib/ex_license/spdx.ex | samuelmanzanera/ex_license | 4fbf6c6bf2699705ff6b02e15f113d3ee66c3534 | [
"MIT"
] | 4 | 2022-03-14T23:26:07.000Z | 2022-03-27T19:11:29.000Z | lib/ex_license/spdx.ex | apoorv-2204/ex_license | 4fbf6c6bf2699705ff6b02e15f113d3ee66c3534 | [
"MIT"
] | 1 | 2022-03-13T03:54:43.000Z | 2022-03-14T23:25:03.000Z | lib/ex_license/spdx.ex | apoorv-2204/ex_license | 4fbf6c6bf2699705ff6b02e15f113d3ee66c3534 | [
"MIT"
] | 2 | 2022-03-13T02:07:50.000Z | 2022-03-16T02:21:48.000Z | defmodule ExLicense.SPDX do
@moduledoc """
Manage SPDX headers and licenses
"""
@type available_license() ::
:mit | :agpl_v3 | :gpl_v3 | :lgpl_v3 | :mozilla_v2 | :apache_v2 | :boost_v1
@doc """
Return the SPDX License identifier
## Examples
iex> ExLicense.SPDX.id(:mit)
"MIT"
... | 24.044444 | 85 | 0.621996 |
ac960ae636d625060f095f246a2677774b33d2d3 | 386 | ex | Elixir | chapter_1_macros/caller_context.ex | dev-cyprium/metaprogramming_elixir | 5035ba82d1a794d032dc5eb7f8b4eaa4b550fd36 | [
"MIT"
] | null | null | null | chapter_1_macros/caller_context.ex | dev-cyprium/metaprogramming_elixir | 5035ba82d1a794d032dc5eb7f8b4eaa4b550fd36 | [
"MIT"
] | null | null | null | chapter_1_macros/caller_context.ex | dev-cyprium/metaprogramming_elixir | 5035ba82d1a794d032dc5eb7f8b4eaa4b550fd36 | [
"MIT"
] | null | null | null | defmodule Mod do
IO.puts "In macro's context (#{__MODULE__})."
defmacro definfo do
quote do
IO.puts "In caller's context (#{__MODULE__})"
def friendly_info do
IO.puts """
My name is #{__MODULE__}
My functions are #{inspect __info__(:functions)}
"""
end
end... | 17.545455 | 56 | 0.608808 |
ac9633b8811c5209e66bf41eb5b2db791050362e | 378 | ex | Elixir | lib/encodebot/http/router.ex | bbassett/encodebot | a2f60b4a032b1573e7d905a4910d3c09fdc07dc0 | [
"MIT"
] | null | null | null | lib/encodebot/http/router.ex | bbassett/encodebot | a2f60b4a032b1573e7d905a4910d3c09fdc07dc0 | [
"MIT"
] | null | null | null | lib/encodebot/http/router.ex | bbassett/encodebot | a2f60b4a032b1573e7d905a4910d3c09fdc07dc0 | [
"MIT"
] | null | null | null | defmodule Encodebot.HTTP.Router do
use __MODULE__.Helper
plug :match
if Mix.env == :dev do
use Plug.Debugger
plug Plug.Logger
end
plug Plug.XForwardedProto
plug Plug.Parsers, parsers: [Plug.Parsers.Wait1,
Plug.Parsers.JSON,
Plug.Parsers... | 22.235294 | 56 | 0.616402 |
ac96356f4847ebf9944244bab8098a9858ab8d81 | 231 | ex | Elixir | lib/Cldr.ex | mithereal/ex_softbank | 8e64143e0056861c84ed71001929bbb5a10a55bf | [
"MIT"
] | 1 | 2020-01-26T23:28:44.000Z | 2020-01-26T23:28:44.000Z | lib/Cldr.ex | mithereal/ex_softbank | 8e64143e0056861c84ed71001929bbb5a10a55bf | [
"MIT"
] | 1 | 2018-12-02T05:35:28.000Z | 2019-03-14T22:42:30.000Z | lib/Cldr.ex | mithereal/elixir-softbank | 2e63b72c4f25d651f4aee654ee41c25ac938fda3 | [
"MIT"
] | null | null | null | defmodule SoftBank.Cldr do
use Cldr,
locales: Application.get_env(:soft_bank, :locales, ["en", "fr", "zh"]),
default_locale: Application.get_env(:soft_bank, :default_locale, "en"),
providers: [Cldr.Number, Money]
end
| 33 | 75 | 0.69697 |
ac9635bd354fb6bf9b111896e98ba8c6fc1343d5 | 915 | exs | Elixir | test/zss_service/service/timer_test.exs | nickve28/zss_service_suite_service | 6474fe4656141e283360ce9bdec1f522651eb72f | [
"MIT"
] | null | null | null | test/zss_service/service/timer_test.exs | nickve28/zss_service_suite_service | 6474fe4656141e283360ce9bdec1f522651eb72f | [
"MIT"
] | 13 | 2017-05-20T12:19:37.000Z | 2017-07-16T10:31:34.000Z | test/zss_service/service/timer_test.exs | nickve28/zss_service_suite_service_ex | 6474fe4656141e283360ce9bdec1f522651eb72f | [
"MIT"
] | null | null | null | defmodule ZssService.Service.TimerTest do
use ExUnit.Case
alias ZssService.Service.Timer
alias ZssService.Mocks.DateTime, as: DateTimeStub
doctest Timer
describe "when measuring time" do
setup do
DateTimeStub.enable
on_exit(fn ->
DateTimeStub.disable
end)
end
test "#... | 24.72973 | 90 | 0.685246 |
ac96550607553577c0c0978f19f490f11a60bec1 | 158 | ex | Elixir | lib/earmark_parser/block/text.ex | akash-akya/earmark_parser | de2216ca0622a9d2491ea2295d0be1bedcaf64c6 | [
"Apache-2.0"
] | null | null | null | lib/earmark_parser/block/text.ex | akash-akya/earmark_parser | de2216ca0622a9d2491ea2295d0be1bedcaf64c6 | [
"Apache-2.0"
] | null | null | null | lib/earmark_parser/block/text.ex | akash-akya/earmark_parser | de2216ca0622a9d2491ea2295d0be1bedcaf64c6 | [
"Apache-2.0"
] | null | null | null | defmodule EarmarkParser.Block.Text do
@moduledoc false
defstruct attrs: nil, lnb: 0, annotation: nil, line: ""
end
# SPDX-License-Identifier: Apache-2.0
| 26.333333 | 57 | 0.740506 |
ac9665c35eee5eb7cc988e232770bf1d2f8bdfaa | 1,366 | exs | Elixir | run.exs | J3RN/elixir_sense | 0e978dcfbf0a0602743917e3e71dfa40bf7467cf | [
"MIT",
"Unlicense"
] | null | null | null | run.exs | J3RN/elixir_sense | 0e978dcfbf0a0602743917e3e71dfa40bf7467cf | [
"MIT",
"Unlicense"
] | null | null | null | run.exs | J3RN/elixir_sense | 0e978dcfbf0a0602743917e3e71dfa40bf7467cf | [
"MIT",
"Unlicense"
] | null | null | null | requires = [
"elixir_sense/core/builtin_attributes.ex",
"elixir_sense/core/applications.ex",
"elixir_sense/core/state.ex",
"elixir_sense/core/introspection.ex",
"elixir_sense/core/edoc_reader.ex",
"elixir_sense/core/ast.ex",
"elixir_sense/core/metadata_builder.ex",
"elixir_sense/core/metadata.ex",
"el... | 32.52381 | 50 | 0.756955 |
ac9674aa575093cd1a1a1fe978c0d30cabe64796 | 1,323 | ex | Elixir | lib/stream_heda_web/endpoint.ex | QBonaventure/StreamHeda | d5f167c567a7886fcc9ed3b14f19fd875c05b2f0 | [
"MIT"
] | null | null | null | lib/stream_heda_web/endpoint.ex | QBonaventure/StreamHeda | d5f167c567a7886fcc9ed3b14f19fd875c05b2f0 | [
"MIT"
] | 1 | 2021-03-09T23:27:29.000Z | 2021-03-09T23:27:29.000Z | lib/stream_heda_web/endpoint.ex | QBonaventure/StreamHeda | d5f167c567a7886fcc9ed3b14f19fd875c05b2f0 | [
"MIT"
] | null | null | null | defmodule StreamHedaWeb.Endpoint do
use Phoenix.Endpoint, otp_app: :stream_heda
socket "/socket", StreamHedaWeb.UserSocket,
websocket: true,
longpoll: false
# Serve at "/" the static files from "priv/static" directory.
#
# You should set gzip to true if you are running phx.digest
# when deploying ... | 28.148936 | 69 | 0.714286 |
ac967521169aa3873ba3b7131e7f3e3249e5e7af | 4,386 | ex | Elixir | lib/hash_ring.ex | tcyrus/ex_hash_ring | d578e0b5328a3a0bdebbc0b833c61a9e108ca841 | [
"MIT"
] | null | null | null | lib/hash_ring.ex | tcyrus/ex_hash_ring | d578e0b5328a3a0bdebbc0b833c61a9e108ca841 | [
"MIT"
] | null | null | null | lib/hash_ring.ex | tcyrus/ex_hash_ring | d578e0b5328a3a0bdebbc0b833c61a9e108ca841 | [
"MIT"
] | null | null | null | defmodule ExHashRing.HashRing do
@compile :native
@type t :: __MODULE__
@type override_map :: %{atom => [binary]}
use Bitwise
alias ExHashRing.HashRing.Utils
defstruct num_replicas: 0, nodes: [], overrides: %{}, items: {}
@spec new :: t
def new, do: new([])
@spec new([binary], override_map, integ... | 26.107143 | 94 | 0.623575 |
ac96a2494b75dfaf7ba540802d46418ff44e7fcf | 1,478 | ex | Elixir | lib/staff_notes_web/views/user_view.ex | lee-dohm/staff-notes | 07186e8407f1955876fa2dee2dbbfd0bbac91333 | [
"MIT"
] | 1 | 2020-01-26T18:08:40.000Z | 2020-01-26T18:08:40.000Z | lib/staff_notes_web/views/user_view.ex | lee-dohm/staff-notes | 07186e8407f1955876fa2dee2dbbfd0bbac91333 | [
"MIT"
] | 36 | 2017-12-23T20:22:07.000Z | 2018-05-10T09:16:59.000Z | lib/staff_notes_web/views/user_view.ex | lee-dohm/staff-notes | 07186e8407f1955876fa2dee2dbbfd0bbac91333 | [
"MIT"
] | null | null | null | defmodule StaffNotesWeb.UserView do
@moduledoc """
View functions for the user pages.
"""
use StaffNotesWeb, :view
import StaffNotesWeb.Router.Helpers
alias StaffNotes.Accounts.User
alias StaffNotes.Repo
@doc """
Renders a "Create organization" button.
"""
def create_org_button(conn, options \\... | 27.886792 | 98 | 0.700271 |
ac973dcc9c6cf7e0fd73ae644bafb44ddaf60875 | 12,625 | ex | Elixir | clients/cloud_debugger/lib/google_api/cloud_debugger/v2/api/controller.ex | kolorahl/elixir-google-api | 46bec1e092eb84c6a79d06c72016cb1a13777fa6 | [
"Apache-2.0"
] | null | null | null | clients/cloud_debugger/lib/google_api/cloud_debugger/v2/api/controller.ex | kolorahl/elixir-google-api | 46bec1e092eb84c6a79d06c72016cb1a13777fa6 | [
"Apache-2.0"
] | null | null | null | clients/cloud_debugger/lib/google_api/cloud_debugger/v2/api/controller.ex | kolorahl/elixir-google-api | 46bec1e092eb84c6a79d06c72016cb1a13777fa6 | [
"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... | 45.250896 | 196 | 0.650297 |
ac9753cc2f78b15fd5262e0372a5f7519a1a90e4 | 2,825 | ex | Elixir | lib/messaging_status_service/twilio/twilio_log_source.ex | ciroque/messaging_status_service | 0d32873ac6e0a78c92a5cf08da373ba4aaf22da4 | [
"MIT"
] | null | null | null | lib/messaging_status_service/twilio/twilio_log_source.ex | ciroque/messaging_status_service | 0d32873ac6e0a78c92a5cf08da373ba4aaf22da4 | [
"MIT"
] | null | null | null | lib/messaging_status_service/twilio/twilio_log_source.ex | ciroque/messaging_status_service | 0d32873ac6e0a78c92a5cf08da373ba4aaf22da4 | [
"MIT"
] | null | null | null | defmodule MessagingStatusService.TwilioLogSource do
@behaviour MessagingStatusService.LogSourceBehaviour
require Logger
@http_client Application.get_env(:messaging_status_service, :calls)[:http_client]
def retrieve_sms_log(id) do
retrieve_log(sms_uri(id))
end
def retrieve_call_log(id) do
retriev... | 24.565217 | 120 | 0.622655 |
ac9770e4e8330ee69166019c29311d446a172065 | 2,943 | ex | Elixir | lib/bitcoin/protocol/types/block_header.ex | coinscript/bitcoinsv-elixir | 2dda03c81edc5662743ed2922abb5b1910d9c09a | [
"Apache-2.0"
] | 2 | 2019-08-12T04:53:57.000Z | 2019-09-03T03:47:33.000Z | lib/bitcoin/protocol/types/block_header.ex | coinscript/bitcoinsv-elixir | 2dda03c81edc5662743ed2922abb5b1910d9c09a | [
"Apache-2.0"
] | null | null | null | lib/bitcoin/protocol/types/block_header.ex | coinscript/bitcoinsv-elixir | 2dda03c81edc5662743ed2922abb5b1910d9c09a | [
"Apache-2.0"
] | null | null | null | defmodule Bitcoin.Protocol.Types.BlockHeader do
alias Bitcoin.Protocol.Types.VarInteger
# Block version information, based upon the software version creating this block
defstruct version: 0,
# char[32], The hash value of the previous block this particular block references
previous_block:
... | 39.24 | 129 | 0.624873 |
ac97a057ab6ccd233d1f98a70b3b0d2cdfcfa0f3 | 6,924 | ex | Elixir | lib/mazes/settings.ex | angelikatyborska/mazes | cba3b1d6aaaa896f4ca505b477cf03b67523ebf0 | [
"MIT"
] | 116 | 2020-12-26T20:56:01.000Z | 2022-03-12T15:12:37.000Z | lib/mazes/settings.ex | lohayon/mazes | 98a6276ea7440af938edfb14476a5877fdc295e1 | [
"MIT"
] | null | null | null | lib/mazes/settings.ex | lohayon/mazes | 98a6276ea7440af938edfb14476a5877fdc295e1 | [
"MIT"
] | 10 | 2020-12-29T05:11:43.000Z | 2022-01-02T00:57:12.000Z | defmodule Mazes.Settings do
defstruct([
:shape,
:algorithm,
:entrance_exit_strategy,
:width,
:height,
:radius,
:side_length,
:show_solution,
:show_colors,
:hue,
:saturation,
:mask
])
alias Mazes.{
RectangularMaze,
RectangularMazeWithMask,
CircularMaze,
... | 25.644444 | 98 | 0.610919 |
ac97a9a88bce29b6b43c28b8ece44414a34417b9 | 347 | exs | Elixir | priv/repo/seeds.exs | finalclass/forus | f745d3ef63684b8fa61a904d4032b5ae26931943 | [
"MIT"
] | null | null | null | priv/repo/seeds.exs | finalclass/forus | f745d3ef63684b8fa61a904d4032b5ae26931943 | [
"MIT"
] | 1 | 2018-06-19T10:38:48.000Z | 2018-06-19T10:38:48.000Z | priv/repo/seeds.exs | finalclass/forus | f745d3ef63684b8fa61a904d4032b5ae26931943 | [
"MIT"
] | null | null | null | # Script for populating the database. You can run it as:
#
# mix run priv/repo/seeds.exs
#
# Inside the script, you can read and write to any of your
# repositories directly:
#
# Forus.Repo.insert!(%Forus.SomeSchema{})
#
# We recommend using the bang functions (`insert!`, `update!`
# and so on) as they will fai... | 28.916667 | 61 | 0.70317 |
ac97b4a566c47c8c11daa29485633623cdbfbeea | 774 | ex | Elixir | elixir/lib/com/spoonacular/client/model/inline_response_200_53_results.ex | ddsky/spoonacular-api-clients | 63f955ceb2c356fefdd48ec634deb3c3e16a6ae7 | [
"MIT"
] | 21 | 2019-08-09T18:53:26.000Z | 2022-03-14T22:10:10.000Z | elixir/lib/com/spoonacular/client/model/inline_response_200_53_results.ex | ddsky/spoonacular-api-clients | 63f955ceb2c356fefdd48ec634deb3c3e16a6ae7 | [
"MIT"
] | null | null | null | elixir/lib/com/spoonacular/client/model/inline_response_200_53_results.ex | ddsky/spoonacular-api-clients | 63f955ceb2c356fefdd48ec634deb3c3e16a6ae7 | [
"MIT"
] | 55 | 2019-08-13T17:52:47.000Z | 2022-03-27T04:29:34.000Z | # NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
# https://openapi-generator.tech
# Do not edit the class manually.
defmodule com.spoonacular.client.Model.InlineResponse20053Results do
@moduledoc """
"""
@derive [Poison.Encoder]
defstruct [
:"id",
:"name",... | 20.368421 | 91 | 0.613695 |
ac97b57ea14a48d8af4ab765ae064912b9d8dafe | 1,035 | ex | Elixir | src/auth_service/lib/auth_service/schemas/User.ex | wbpascal/statuswebsite | 7a81e530a9176c53abeab0582cb710113101b716 | [
"MIT"
] | 1 | 2021-04-18T20:21:03.000Z | 2021-04-18T20:21:03.000Z | src/auth_service/lib/auth_service/schemas/User.ex | wbpascal/statuswebsite | 7a81e530a9176c53abeab0582cb710113101b716 | [
"MIT"
] | null | null | null | src/auth_service/lib/auth_service/schemas/User.ex | wbpascal/statuswebsite | 7a81e530a9176c53abeab0582cb710113101b716 | [
"MIT"
] | 1 | 2021-04-18T20:21:08.000Z | 2021-04-18T20:21:08.000Z | defmodule AuthService.User do
use Ecto.Schema
import Ecto.Changeset
schema "users" do
field :username, :string
field :password, :string, virtual: true
field :password_hash, :string
timestamps()
end
def changeset(%AuthService.User{} = user, attrs) do
user
|> cast(attrs, [:username, :... | 26.538462 | 98 | 0.663768 |
ac97c96a9a23d86cb5d8f031bcc0e7afb8783c6d | 1,770 | ex | Elixir | lib/workers/enable_gmail_inbox_sync.ex | aboutphilippe/papercups | 30364cc562f41cd9d5a7ca5357b16ab8484bd5c9 | [
"MIT"
] | 1 | 2021-06-17T03:17:24.000Z | 2021-06-17T03:17:24.000Z | lib/workers/enable_gmail_inbox_sync.ex | aboutphilippe/papercups | 30364cc562f41cd9d5a7ca5357b16ab8484bd5c9 | [
"MIT"
] | null | null | null | lib/workers/enable_gmail_inbox_sync.ex | aboutphilippe/papercups | 30364cc562f41cd9d5a7ca5357b16ab8484bd5c9 | [
"MIT"
] | null | null | null | defmodule ChatApi.Workers.EnableGmailInboxSync do
use Oban.Worker, queue: :default
require Logger
alias ChatApi.Google
alias ChatApi.Google.{Gmail, GoogleAuthorization}
@impl Oban.Worker
@spec perform(Oban.Job.t()) :: :ok
def perform(%Oban.Job{args: %{"account_id" => account_id}} = job) do
Logger.i... | 30 | 102 | 0.611299 |
ac97ec78948572e9f1a2cdb80138c6d4c1adb1f4 | 1,022 | ex | Elixir | lib/talon/schema/adapters.ex | talonframework/ex_admin | d164c065ac74c156c3abeca8437e184456db903c | [
"MIT"
] | 170 | 2017-05-25T15:09:53.000Z | 2021-07-09T04:04:14.000Z | lib/talon/schema/adapters.ex | talonframework/ex_admin | d164c065ac74c156c3abeca8437e184456db903c | [
"MIT"
] | 78 | 2017-05-25T09:41:55.000Z | 2019-01-04T20:53:35.000Z | lib/talon/schema/adapters.ex | talonframework/ex_admin | d164c065ac74c156c3abeca8437e184456db903c | [
"MIT"
] | 8 | 2017-06-24T12:28:06.000Z | 2018-09-17T16:11:56.000Z | defmodule Talon.Schema.Adapters do
@type module_or_query :: map | struct | map
@doc """
Retrieve the primay key of a query, schema module, or a schema struct.
## Examples
iex> primary_key from b in Blog
:id
iex> primary_key Blog
:id
iex> primary_key %Blog{}
:id
"""
@c... | 20.44 | 120 | 0.618395 |
ac97f02058f9f0b14a844c5945c0a9b900b08816 | 6,642 | exs | Elixir | test/producer_test.exs | suitepad-gmbh/rabbit | c6ba3cbca6b49362c3a9dd32d3af001a1de750ad | [
"MIT"
] | null | null | null | test/producer_test.exs | suitepad-gmbh/rabbit | c6ba3cbca6b49362c3a9dd32d3af001a1de750ad | [
"MIT"
] | null | null | null | test/producer_test.exs | suitepad-gmbh/rabbit | c6ba3cbca6b49362c3a9dd32d3af001a1de750ad | [
"MIT"
] | null | null | null | defmodule Rabbit.ProducerTest do
use ExUnit.Case, async: false
alias Rabbit.{Connection, Producer}
defmodule TestConnection do
use Rabbit.Connection
@impl Rabbit.Connection
def init(_type, opts) do
{:ok, opts}
end
end
defmodule TestProducer do
use Rabbit.Producer
@impl Rabbi... | 27.446281 | 92 | 0.660494 |
ac9801cdb0ec9f6a9a8e3de9639ce8f1f630764f | 19,988 | exs | Elixir | test/shopping_server_test.exs | uoysip/augcart | 9323d3a525c0614c2585197779528ffa8cee68a2 | [
"MIT"
] | 1 | 2020-01-12T21:44:41.000Z | 2020-01-12T21:44:41.000Z | test/shopping_server_test.exs | uoysip/augcart | 9323d3a525c0614c2585197779528ffa8cee68a2 | [
"MIT"
] | null | null | null | test/shopping_server_test.exs | uoysip/augcart | 9323d3a525c0614c2585197779528ffa8cee68a2 | [
"MIT"
] | null | null | null | defmodule ShoppingListServerTest do
use ExUnit.Case
doctest ShoppingListServer
describe "ShoppingListServer" do
setup [:start_server, :flush_messages]
test "stays alive after being spawned", ctx do
Process.sleep(100)
assert Process.alive?(ctx.pid)
end
end
describe ":new_user when... | 29.437408 | 89 | 0.613118 |
ac981677b3bf0007764348181ce63c974f8ae044 | 358 | ex | Elixir | lib/elixir_sense/providers/suggestion/reducer.ex | BartOtten/elixir_sense | 4a857f2c262b9f8ac2d72e31f4806cecc740192a | [
"MIT",
"Unlicense"
] | 216 | 2019-01-05T02:08:51.000Z | 2022-03-23T23:59:56.000Z | lib/elixir_sense/providers/suggestion/reducer.ex | BartOtten/elixir_sense | 4a857f2c262b9f8ac2d72e31f4806cecc740192a | [
"MIT",
"Unlicense"
] | 102 | 2019-01-18T04:59:06.000Z | 2022-01-10T14:21:24.000Z | lib/elixir_sense/providers/suggestion/reducer.ex | BartOtten/elixir_sense | 4a857f2c262b9f8ac2d72e31f4806cecc740192a | [
"MIT",
"Unlicense"
] | 31 | 2019-01-16T08:19:34.000Z | 2022-03-07T08:06:22.000Z | defmodule ElixirSense.Providers.Suggestion.Reducer do
@moduledoc !"""
Provides common functions for reducers.
"""
def put_context(acc, key, value) do
updated_context = Map.put(acc.context, key, value)
put_in(acc.context, updated_context)
end
def get_context(acc, key) do
g... | 23.866667 | 54 | 0.664804 |
ac981ab95e3c88791edbff90aa30fdbff0ec7eef | 5,665 | ex | Elixir | lib/chat_api/messages/notification.ex | aboutphilippe/papercups | 30364cc562f41cd9d5a7ca5357b16ab8484bd5c9 | [
"MIT"
] | null | null | null | lib/chat_api/messages/notification.ex | aboutphilippe/papercups | 30364cc562f41cd9d5a7ca5357b16ab8484bd5c9 | [
"MIT"
] | null | null | null | lib/chat_api/messages/notification.ex | aboutphilippe/papercups | 30364cc562f41cd9d5a7ca5357b16ab8484bd5c9 | [
"MIT"
] | null | null | null | defmodule ChatApi.Messages.Notification do
@moduledoc """
Notification handlers for messages
"""
alias ChatApi.{EventSubscriptions, Lambdas}
alias ChatApi.Messages.{Helpers, Message}
require Logger
@spec broadcast_to_customer!(Message.t()) :: Message.t()
def broadcast_to_customer!(%Message{private: f... | 27.36715 | 96 | 0.672198 |
ac983259f66c706cb95e56ede5ca53d94882f4ee | 576 | exs | Elixir | ch2/my_project/mix.exs | TheEndIsNear/ElixirInAction | 9b18ebd4845723935e03ec2a0c3cf869aa955541 | [
"MIT"
] | null | null | null | ch2/my_project/mix.exs | TheEndIsNear/ElixirInAction | 9b18ebd4845723935e03ec2a0c3cf869aa955541 | [
"MIT"
] | null | null | null | ch2/my_project/mix.exs | TheEndIsNear/ElixirInAction | 9b18ebd4845723935e03ec2a0c3cf869aa955541 | [
"MIT"
] | null | null | null | defmodule MyProject.MixProject do
use Mix.Project
def project do
[
app: :my_project,
version: "0.1.0",
elixir: "~> 1.9",
start_permanent: Mix.env() == :prod,
deps: deps()
]
end
# Run "mix help compile.app" to learn about applications.
def application do
[
extr... | 19.862069 | 87 | 0.579861 |
ac984923efd5f6ac550582374283bc655f65caa8 | 2,444 | ex | Elixir | clients/firebase_rules/lib/google_api/firebase_rules/v1/connection.ex | GoNZooo/elixir-google-api | cf3ad7392921177f68091f3d9001f1b01b92f1cc | [
"Apache-2.0"
] | null | null | null | clients/firebase_rules/lib/google_api/firebase_rules/v1/connection.ex | GoNZooo/elixir-google-api | cf3ad7392921177f68091f3d9001f1b01b92f1cc | [
"Apache-2.0"
] | null | null | null | clients/firebase_rules/lib/google_api/firebase_rules/v1/connection.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... | 28.752941 | 119 | 0.717267 |
ac98776edcac2c55ec3d7e7fcf7a8cebf5c2b5f3 | 687 | exs | Elixir | mix.exs | nabbisen/journey-planner | 82aa6e081504dfe3a9b2b191b40819404b9fd26b | [
"MIT"
] | null | null | null | mix.exs | nabbisen/journey-planner | 82aa6e081504dfe3a9b2b191b40819404b9fd26b | [
"MIT"
] | null | null | null | mix.exs | nabbisen/journey-planner | 82aa6e081504dfe3a9b2b191b40819404b9fd26b | [
"MIT"
] | null | null | null | defmodule JrnyPlnr.Mixfile do
use Mix.Project
def project do
[app: :jrny_plnr,
version: "0.0.1",
elixir: "~> 1.0",
elixirc_paths: ["lib", "web"],
compilers: [:phoenix] ++ Mix.compilers,
deps: deps]
end
# Configuration for the OTP application
#
# Type `mix help compile.app` for... | 22.16129 | 66 | 0.586608 |
ac98a0857d98700b419ec8a9ca6fc8cf0b154779 | 1,382 | exs | Elixir | chromoid_web/config/config.exs | ConnorRigby/chromoid | 6424a9234227d18d7c287ded869caeb31511bb97 | [
"Apache-2.0"
] | 7 | 2020-11-18T11:29:20.000Z | 2022-01-16T03:16:14.000Z | chromoid_web/config/config.exs | ConnorRigby/chromoid | 6424a9234227d18d7c287ded869caeb31511bb97 | [
"Apache-2.0"
] | null | null | null | chromoid_web/config/config.exs | ConnorRigby/chromoid | 6424a9234227d18d7c287ded869caeb31511bb97 | [
"Apache-2.0"
] | 1 | 2021-01-06T15:40:46.000Z | 2021-01-06T15:40:46.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.
# General application configuration
use Mix.Config
config :chromoid,
ecto_repos: [Chromoid.Repo, ... | 32.139535 | 86 | 0.7822 |
ac98c58ace4bdfbc0ef0e32ce91a02e253c03ed1 | 1,776 | exs | Elixir | mix.exs | joaopealves/elixir-graphql-poc | 1d162ef7461d54bff779c6406f39ff7db6d574f7 | [
"MIT"
] | 1 | 2021-12-06T01:31:28.000Z | 2021-12-06T01:31:28.000Z | mix.exs | joaopealves/elixir-graphql-poc | 1d162ef7461d54bff779c6406f39ff7db6d574f7 | [
"MIT"
] | null | null | null | mix.exs | joaopealves/elixir-graphql-poc | 1d162ef7461d54bff779c6406f39ff7db6d574f7 | [
"MIT"
] | null | null | null | defmodule Poc.MixProject do
use Mix.Project
def project do
[
app: :poc,
version: "0.1.0",
elixir: "~> 1.12",
elixirc_paths: elixirc_paths(Mix.env()),
compilers: [:gettext] ++ Mix.compilers(),
start_permanent: Mix.env() == :prod,
aliases: aliases(),
deps: deps()
... | 26.507463 | 84 | 0.567005 |
ac98c5eb1e4cdd7ea4221b0e748545a0c976d0ce | 1,420 | ex | Elixir | lib/toy_robot/table.ex | lowski/toy-robot | 107e5c68c1ba0813be9efb3949f6fde348aaa05b | [
"MIT"
] | null | null | null | lib/toy_robot/table.ex | lowski/toy-robot | 107e5c68c1ba0813be9efb3949f6fde348aaa05b | [
"MIT"
] | null | null | null | lib/toy_robot/table.ex | lowski/toy-robot | 107e5c68c1ba0813be9efb3949f6fde348aaa05b | [
"MIT"
] | null | null | null | defmodule ToyRobot.Table do
alias ToyRobot.Table
defstruct [:north_boundary, :east_boundary]
@doc """
Check if given position is within table boundaries.
## Examples
iex> alias ToyRobot.Table
ToyRobot.Table
iex> table = %Table{north_boundary: 4, east_boundary: 4}
%Table{north_boundary: 4, ... | 26.296296 | 94 | 0.637324 |
ac98c9ea1d8b0cb762e1f43e1b78f140abb9d66a | 335 | exs | Elixir | priv/repo/migrations/20161223035224_create_notification.exs | Angarsk8/microscope.ex | dc4572ba8b9f1c7b7c94ee78f387e332ac0d936c | [
"MIT"
] | 342 | 2017-01-10T16:13:45.000Z | 2022-02-26T13:55:38.000Z | priv/repo/migrations/20161223035224_create_notification.exs | Angarsk8/microscope.ex | dc4572ba8b9f1c7b7c94ee78f387e332ac0d936c | [
"MIT"
] | 6 | 2017-01-14T17:59:48.000Z | 2018-03-25T21:35:50.000Z | priv/repo/migrations/20161223035224_create_notification.exs | Angarsk8/microscope.ex | dc4572ba8b9f1c7b7c94ee78f387e332ac0d936c | [
"MIT"
] | 38 | 2017-01-11T00:18:21.000Z | 2021-07-11T11:28:12.000Z | defmodule Microscope.Repo.Migrations.CreateNotification do
use Ecto.Migration
def change do
create table(:notifications) do
add :username, :string
add :post_id, :integer
add :user_id, references(:users, on_delete: :nothing)
timestamps()
end
create index(:notifications, [:user_i... | 20.9375 | 59 | 0.689552 |
ac98fb67c50000dcbca0ba489c3ca8dac612eb1e | 1,625 | ex | Elixir | apps/omg_status/lib/omg_status/metric/recorder.ex | kendricktan/elixir-omg | 834c103fd5c4b9e063c1d32b9b4e5728abb64009 | [
"Apache-2.0"
] | null | null | null | apps/omg_status/lib/omg_status/metric/recorder.ex | kendricktan/elixir-omg | 834c103fd5c4b9e063c1d32b9b4e5728abb64009 | [
"Apache-2.0"
] | null | null | null | apps/omg_status/lib/omg_status/metric/recorder.ex | kendricktan/elixir-omg | 834c103fd5c4b9e063c1d32b9b4e5728abb64009 | [
"Apache-2.0"
] | null | null | null | # Copyright 2019 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 writi... | 30.660377 | 95 | 0.688615 |
ac990b2bbc6d3b5bb8c76bb72cdfd106f9a5b4cb | 18,861 | ex | Elixir | lib/phoenix_live_view/channel.ex | hypno2000/phoenix_live_view | f9aa7fea9c7baf87448d8666b7340bbb73583611 | [
"MIT"
] | null | null | null | lib/phoenix_live_view/channel.ex | hypno2000/phoenix_live_view | f9aa7fea9c7baf87448d8666b7340bbb73583611 | [
"MIT"
] | null | null | null | lib/phoenix_live_view/channel.ex | hypno2000/phoenix_live_view | f9aa7fea9c7baf87448d8666b7340bbb73583611 | [
"MIT"
] | null | null | null | defmodule Phoenix.LiveView.Channel do
@moduledoc false
use GenServer, restart: :temporary
require Logger
alias Phoenix.LiveView.{Socket, Utils, Diff, Static}
alias Phoenix.Socket.Message
@prefix :phoenix
def start_link({auth_payload, from, phx_socket}) do
hibernate_after = phx_socket.endpoint.conf... | 31.330565 | 100 | 0.633901 |
ac991f3010fa9f52973d7f66cac2e1294ebb791a | 1,675 | exs | Elixir | test/gonex/controller_test.exs | nmbrone/gonex | eff0cfc418f252ef0877cf91f1466a0d253cfe10 | [
"MIT"
] | null | null | null | test/gonex/controller_test.exs | nmbrone/gonex | eff0cfc418f252ef0877cf91f1466a0d253cfe10 | [
"MIT"
] | null | null | null | test/gonex/controller_test.exs | nmbrone/gonex | eff0cfc418f252ef0877cf91f1466a0d253cfe10 | [
"MIT"
] | null | null | null | defmodule Gonex.ControllerTest do
use ExUnit.Case, async: true
use Plug.Test
import Gonex.Controller
setup do
[
conn: conn(:get, "/"),
conn_gon: conn(:get, "/") |> put_private(:gonex_storage, %{foo: "bar"})
]
end
describe "put_gon/2" do
test "puts given map into the storage", ctx ... | 27.916667 | 77 | 0.605373 |
ac99325e30b66bdaa54670dce41755a4b20fc5da | 994 | ex | Elixir | lib/new_relic/error/trace.ex | ll1498/elixir_agent | a7b3bf1b49639c61d9eba3d4b91b30e0e856b54a | [
"Apache-2.0"
] | 1 | 2020-08-13T05:08:20.000Z | 2020-08-13T05:08:20.000Z | lib/new_relic/error/trace.ex | ll1498/elixir_agent | a7b3bf1b49639c61d9eba3d4b91b30e0e856b54a | [
"Apache-2.0"
] | null | null | null | lib/new_relic/error/trace.ex | ll1498/elixir_agent | a7b3bf1b49639c61d9eba3d4b91b30e0e856b54a | [
"Apache-2.0"
] | null | null | null | defmodule NewRelic.Error.Trace do
defstruct timestamp: nil,
transaction_name: "",
message: nil,
expected: false,
error_type: nil,
cat_guid: "",
stack_trace: nil,
request_uri: nil,
user_attributes: %{}
@moduledoc false
... | 24.243902 | 70 | 0.584507 |
ac99445de6f8b65eaf5b7476ffa0eae3ab28288c | 372 | ex | Elixir | lib/renaissance_web/views/auction_view.ex | xray/Renaissance | 38201fb2160d88239a55020383c59fc8034c9554 | [
"Unlicense"
] | 2 | 2021-02-01T12:09:07.000Z | 2021-03-14T12:20:43.000Z | lib/renaissance_web/views/auction_view.ex | xray/Renaissance | 38201fb2160d88239a55020383c59fc8034c9554 | [
"Unlicense"
] | 11 | 2019-04-09T18:01:16.000Z | 2019-05-16T15:02:24.000Z | lib/renaissance_web/views/auction_view.ex | xray/Renaissance | 38201fb2160d88239a55020383c59fc8034c9554 | [
"Unlicense"
] | 2 | 2019-04-30T22:43:18.000Z | 2019-05-15T20:34:49.000Z | defmodule RenaissanceWeb.AuctionView do
use RenaissanceWeb, :view
alias Renaissance.Helpers
def default_end do
current = DateTime.utc_now()
%{
day: current.day,
hour: current.hour,
minute: current.minute,
month: current.month,
year: current.year
}
end
def float_amo... | 19.578947 | 62 | 0.677419 |
ac995c75447593af16706934e3a1bff3dc47381a | 172 | exs | Elixir | priv/repo/migrations/20200625201609_add_avatar_to_user.exs | abmBispo/elixir-ecommerce | 0507f7621d68ba8f0f65409a1a503683b7c0d37b | [
"MIT"
] | 4 | 2020-05-29T03:33:02.000Z | 2021-08-21T23:01:48.000Z | priv/repo/migrations/20200625201609_add_avatar_to_user.exs | abmBispo/elixir-ecommerce | 0507f7621d68ba8f0f65409a1a503683b7c0d37b | [
"MIT"
] | 2 | 2020-07-29T01:50:46.000Z | 2021-08-31T20:10:47.000Z | priv/repo/migrations/20200625201609_add_avatar_to_user.exs | abmBispo/elixir-ecommerce | 0507f7621d68ba8f0f65409a1a503683b7c0d37b | [
"MIT"
] | 1 | 2022-03-21T18:13:21.000Z | 2022-03-21T18:13:21.000Z | defmodule ElixirEcommerce.Repo.Migrations.AddAvatarToUser do
use Ecto.Migration
def change do
alter table("users") do
add :avatar, :string
end
end
end
| 17.2 | 60 | 0.715116 |
ac996045c55ea9141b10c37111243e91c68d710e | 45 | exs | Elixir | config/config.exs | rupurt/echo_boy | 90c8dd918a2ec6b77b348b5817408f21f3e2f3a8 | [
"MIT"
] | null | null | null | config/config.exs | rupurt/echo_boy | 90c8dd918a2ec6b77b348b5817408f21f3e2f3a8 | [
"MIT"
] | 32 | 2020-03-28T19:26:11.000Z | 2021-08-02T13:17:30.000Z | config/config.exs | rupurt/echo_boy | 90c8dd918a2ec6b77b348b5817408f21f3e2f3a8 | [
"MIT"
] | null | null | null | use Mix.Config
config :echo_boy, port: 4100
| 11.25 | 28 | 0.755556 |
ac998e0d1f748ea4e41868888fbedbf3acc5aa04 | 276 | exs | Elixir | apps/robby_web/priv/repo/migrations/20160318180522_create_room.exs | jeffweiss/openrobby | 9fed2024e6ce87a6fe27ef3af85558f3116aca2a | [
"Apache-2.0"
] | null | null | null | apps/robby_web/priv/repo/migrations/20160318180522_create_room.exs | jeffweiss/openrobby | 9fed2024e6ce87a6fe27ef3af85558f3116aca2a | [
"Apache-2.0"
] | null | null | null | apps/robby_web/priv/repo/migrations/20160318180522_create_room.exs | jeffweiss/openrobby | 9fed2024e6ce87a6fe27ef3af85558f3116aca2a | [
"Apache-2.0"
] | null | null | null | defmodule RobbyWeb.Repo.Migrations.CreateRoom do
use Ecto.Migration
def change do
create table(:rooms) do
add :name, :string
add :user_id, references(:users, on_delete: :nothing)
timestamps()
end
create index(:rooms, [:user_id])
end
end
| 18.4 | 59 | 0.666667 |
ac999608e7a36b986d4b860094e6594cab39f436 | 18,582 | exs | Elixir | lib/ex_unit/test/ex_unit/assertions_test.exs | elkinsd/elixir | 810965e193cb57b82363e7c0c97b719743b7964f | [
"Apache-2.0"
] | null | null | null | lib/ex_unit/test/ex_unit/assertions_test.exs | elkinsd/elixir | 810965e193cb57b82363e7c0c97b719743b7964f | [
"Apache-2.0"
] | null | null | null | lib/ex_unit/test/ex_unit/assertions_test.exs | elkinsd/elixir | 810965e193cb57b82363e7c0c97b719743b7964f | [
"Apache-2.0"
] | null | null | null | Code.require_file "../test_helper.exs", __DIR__
defmodule ExUnit.AssertionsTest.Value do
def tuple, do: {2, 1}
def falsy, do: false
def truthy, do: true
end
alias ExUnit.AssertionsTest.Value
defmodule ExUnit.AssertionsTest do
use ExUnit.Case, async: true
defmacrop assert_ok(arg) do
quote do
asse... | 27.692996 | 132 | 0.615165 |
ac99b2de76d1cddee7e22e18e073d07b006abeae | 3,609 | ex | Elixir | clients/webmaster/lib/google_api/webmaster/v3/api/urlcrawlerrorscounts.ex | GoNZooo/elixir-google-api | cf3ad7392921177f68091f3d9001f1b01b92f1cc | [
"Apache-2.0"
] | null | null | null | clients/webmaster/lib/google_api/webmaster/v3/api/urlcrawlerrorscounts.ex | GoNZooo/elixir-google-api | cf3ad7392921177f68091f3d9001f1b01b92f1cc | [
"Apache-2.0"
] | null | null | null | clients/webmaster/lib/google_api/webmaster/v3/api/urlcrawlerrorscounts.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... | 46.269231 | 217 | 0.714325 |
ac99c96dc35c9ef919f4a83d6cd28c7cbbd22cfc | 941 | ex | Elixir | lib/medic/checks/git.ex | eahanson/medic | 01f35f2aa22e7120cf1bd492e6e5400a29224791 | [
"MIT"
] | 3 | 2021-06-18T18:42:35.000Z | 2022-02-09T01:54:58.000Z | lib/medic/checks/git.ex | eahanson/medic | 01f35f2aa22e7120cf1bd492e6e5400a29224791 | [
"MIT"
] | 3 | 2021-06-17T19:02:32.000Z | 2021-06-17T19:44:35.000Z | lib/medic/checks/git.ex | eahanson/medic | 01f35f2aa22e7120cf1bd492e6e5400a29224791 | [
"MIT"
] | 1 | 2022-03-10T19:16:14.000Z | 2022-03-10T19:16:14.000Z | defmodule Medic.Checks.Git do
@moduledoc """
Common checks for git configuration
## Examples
{Check.Git, :uses_ssh?, ["github.com"]}
"""
@doc """
Checks to make sure that git defaults to using SSH instead of HTTPS.
"""
@spec uses_ssh?(binary()) :: Medic.Check.check_return_t()
def uses_ssh?(do... | 26.138889 | 87 | 0.548353 |
ac9a0e56f2e6bcfdd67959826148bee298a3dd8e | 202 | ex | Elixir | lib/gocd/structures/stage.ex | IanLuites/gocd | c27a2120d24e2210a289ad29861a9fa602efc6bd | [
"MIT"
] | null | null | null | lib/gocd/structures/stage.ex | IanLuites/gocd | c27a2120d24e2210a289ad29861a9fa602efc6bd | [
"MIT"
] | null | null | null | lib/gocd/structures/stage.ex | IanLuites/gocd | c27a2120d24e2210a289ad29861a9fa602efc6bd | [
"MIT"
] | null | null | null | defmodule GoCD.Stage do
@moduledoc ~S"""
GoCD stage.
TODO: more info.
"""
@typedoc @moduledoc
@type t :: %__MODULE__{
name: String.t()
}
defstruct [
:name
]
end
| 11.882353 | 26 | 0.539604 |
ac9a0edb8340decbd1c6c15f802e935754588fa5 | 2,117 | ex | Elixir | clients/real_time_bidding/lib/google_api/real_time_bidding/v1/model/list_publisher_connections_response.ex | yoshi-code-bot/elixir-google-api | cdb6032f01fac5ab704803113c39f2207e9e019d | [
"Apache-2.0"
] | null | null | null | clients/real_time_bidding/lib/google_api/real_time_bidding/v1/model/list_publisher_connections_response.ex | yoshi-code-bot/elixir-google-api | cdb6032f01fac5ab704803113c39f2207e9e019d | [
"Apache-2.0"
] | null | null | null | clients/real_time_bidding/lib/google_api/real_time_bidding/v1/model/list_publisher_connections_response.ex | yoshi-code-bot/elixir-google-api | cdb6032f01fac5ab704803113c39f2207e9e019d | [
"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.490909 | 281 | 0.754842 |
ac9a7f4f1e548b9d7dbef56787561486db2c1619 | 2,540 | ex | Elixir | clients/content/lib/google_api/content/v2/model/orders_custom_batch_response_entry.ex | matehat/elixir-google-api | c1b2523c2c4cdc9e6ca4653ac078c94796b393c3 | [
"Apache-2.0"
] | 1 | 2018-12-03T23:43:10.000Z | 2018-12-03T23:43:10.000Z | clients/content/lib/google_api/content/v2/model/orders_custom_batch_response_entry.ex | matehat/elixir-google-api | c1b2523c2c4cdc9e6ca4653ac078c94796b393c3 | [
"Apache-2.0"
] | null | null | null | clients/content/lib/google_api/content/v2/model/orders_custom_batch_response_entry.ex | matehat/elixir-google-api | c1b2523c2c4cdc9e6ca4653ac078c94796b393c3 | [
"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 ... | 41.639344 | 196 | 0.715748 |
ac9ac293cb07d5829e13b34ab15db45c008bd8cf | 735 | ex | Elixir | lib/calculation/service.ex | jakehafdahl/email-service | 696c1fce52e0d432ade513ce6ad36edcd76ec0cd | [
"MIT"
] | null | null | null | lib/calculation/service.ex | jakehafdahl/email-service | 696c1fce52e0d432ade513ce6ad36edcd76ec0cd | [
"MIT"
] | null | null | null | lib/calculation/service.ex | jakehafdahl/email-service | 696c1fce52e0d432ade513ce6ad36edcd76ec0cd | [
"MIT"
] | null | null | null | defmodule ProfessorStats.CalcService do
alias ProfessorStats.CalcRegistry
def start_link do
import Supervisor.Spec, warn: false
children = [
supervisor(ProfessorStats.PlayerTable.Supervisor, []),
worker(ProfessorStats.CalcRegistry, [ProfessorStats.CalcRegistry])
]
... | 27.222222 | 78 | 0.619048 |
ac9ad8e82ae67dcafd78cde250c68e64f007c168 | 769 | ex | Elixir | test/support/test_case.ex | Simon-Initiative/lti_1p3 | e599a61cdaa00fe20eda19dab88b80324580123f | [
"MIT"
] | 4 | 2021-02-19T13:13:49.000Z | 2021-11-11T09:02:27.000Z | test/support/test_case.ex | Simon-Initiative/lti_1p3 | e599a61cdaa00fe20eda19dab88b80324580123f | [
"MIT"
] | 3 | 2021-02-15T22:46:06.000Z | 2021-03-30T21:26:55.000Z | test/support/test_case.ex | Simon-Initiative/lti_1p3 | e599a61cdaa00fe20eda19dab88b80324580123f | [
"MIT"
] | null | null | null | defmodule Lti_1p3.Test.TestCase 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... | 25.633333 | 89 | 0.73472 |
ac9b02797cccb89b017338669b9cf28abe230d76 | 444 | exs | Elixir | test/octopus_web/views/session_view_test.exs | ubudget/octopus | 84087fbb6bfd5e7611583d7c1098e18d4239f036 | [
"MIT"
] | null | null | null | test/octopus_web/views/session_view_test.exs | ubudget/octopus | 84087fbb6bfd5e7611583d7c1098e18d4239f036 | [
"MIT"
] | null | null | null | test/octopus_web/views/session_view_test.exs | ubudget/octopus | 84087fbb6bfd5e7611583d7c1098e18d4239f036 | [
"MIT"
] | null | null | null | defmodule OctopusWeb.SessionViewTest do
@moduledoc false
use OctopusWeb.ConnCase
import Octopus.Factory
# Bring render/3 and render_to_string/3 for testing custom views
import Phoenix.View
test "renders show.json" do
user = insert(:user)
session = insert(:session, user: user)
assert render(Oc... | 26.117647 | 75 | 0.716216 |
ac9b0daed212d9223d2d4baff13ad6c179949df1 | 1,441 | ex | Elixir | lib/xqlite.ex | OvermindDL1/xqlite | 987f11e4ba9134239d1fe1a2cfc55f49090a72be | [
"MIT"
] | null | null | null | lib/xqlite.ex | OvermindDL1/xqlite | 987f11e4ba9134239d1fe1a2cfc55f49090a72be | [
"MIT"
] | null | null | null | lib/xqlite.ex | OvermindDL1/xqlite | 987f11e4ba9134239d1fe1a2cfc55f49090a72be | [
"MIT"
] | null | null | null | defmodule Xqlite do
@moduledoc ~S"""
This is the central module of this library. All sqlite operations can be
performed from here.
TODO: Add something more useful than a summary.
"""
# --- Types.
@type conn :: {:connection, reference(), reference()}
@type opts :: keyword()
@type db_name :: String.t... | 28.254902 | 93 | 0.645385 |
ac9b133698f59e98bc6bd3f3513baff777028748 | 457 | ex | Elixir | test/e2e/lib/hologram_e2e_web/pages/operators/cons_page.ex | gregjohnsonsaltaire/hologram | aa8e9ea0d599def864c263cc37cc8ee31f02ac4a | [
"MIT"
] | 40 | 2022-01-19T20:27:36.000Z | 2022-03-31T18:17:41.000Z | test/e2e/lib/hologram_e2e_web/pages/operators/cons_page.ex | gregjohnsonsaltaire/hologram | aa8e9ea0d599def864c263cc37cc8ee31f02ac4a | [
"MIT"
] | 42 | 2022-02-03T22:52:43.000Z | 2022-03-26T20:57:32.000Z | test/e2e/lib/hologram_e2e_web/pages/operators/cons_page.ex | gregjohnsonsaltaire/hologram | aa8e9ea0d599def864c263cc37cc8ee31f02ac4a | [
"MIT"
] | 3 | 2022-02-10T04:00:37.000Z | 2022-03-08T22:07:45.000Z | defmodule HologramE2E.Operators.ConsPage do
use Hologram.Page
route "/e2e/operators/cons"
def init(_params, _conn) do
%{
head: 1,
tail: [2, 3],
result: 0
}
end
def template do
~H"""
<button id="button" on:click="calculate">Calculate</button>
<div id="text">Result = {@r... | 18.28 | 63 | 0.603939 |
ac9b2a3bca9062bdac88fc12767f9c1dc9315894 | 604,541 | ex | Elixir | platform/elixir/mail_checker.ex | goldfire/mailchecker | b6c6537d5138c631669f5c55274ecab77c7559f2 | [
"MIT"
] | null | null | null | platform/elixir/mail_checker.ex | goldfire/mailchecker | b6c6537d5138c631669f5c55274ecab77c7559f2 | [
"MIT"
] | null | null | null | platform/elixir/mail_checker.ex | goldfire/mailchecker | b6c6537d5138c631669f5c55274ecab77c7559f2 | [
"MIT"
] | null | null | null | defmodule MailChecker do
@blacklist Enum.into(["0-00.usa.cc","0-attorney.com","0-mail.com","00.msk.ru","000777.info","001.igg.biz","0033.pl","0039.cf","0039.ga","0039.gq","0039.ml","007game.ru","00b2bcr51qv59xst2.cf","00b2bcr51qv59xst2.ga","00b2bcr51qv59xst2.gq","00b2bcr51qv59xst2.ml","00b2bcr51qv59xst2.tk","01bktwi2... | 23,251.576923 | 602,830 | 0.765837 |
ac9b3fc6029b11176f327381eeda1e980d342463 | 896 | exs | Elixir | test/trex_server_test.exs | ignacy/trex | 286506868e77a08a5d7155d4e3af4159de4be55a | [
"MIT"
] | 7 | 2016-07-17T10:51:07.000Z | 2021-07-02T19:20:43.000Z | test/trex_server_test.exs | ignacy/trex | 286506868e77a08a5d7155d4e3af4159de4be55a | [
"MIT"
] | null | null | null | test/trex_server_test.exs | ignacy/trex | 286506868e77a08a5d7155d4e3af4159de4be55a | [
"MIT"
] | null | null | null | defmodule TrexServerTest do
use ExUnit.Case
setup do
Application.stop(:trex)
:ok = Application.start(:trex)
end
setup do
opts = [:binary, packet: :line, active: false]
{:ok, socket} = :gen_tcp.connect('localhost', 4040, opts)
{:ok, socket: socket}
end
test "server interaction", %{sock... | 26.352941 | 81 | 0.640625 |
ac9b65c29abfb7d38e46c87bd353612318bb759d | 103 | exs | Elixir | monitoring_hub/apps/market_spread_reports_ui/test/views/layout_view_test.exs | awesome-archive/wallaroo | 852c19ffad0ed75a767a658a9a72c355e3c4c1c8 | [
"Apache-2.0"
] | null | null | null | monitoring_hub/apps/market_spread_reports_ui/test/views/layout_view_test.exs | awesome-archive/wallaroo | 852c19ffad0ed75a767a658a9a72c355e3c4c1c8 | [
"Apache-2.0"
] | null | null | null | monitoring_hub/apps/market_spread_reports_ui/test/views/layout_view_test.exs | awesome-archive/wallaroo | 852c19ffad0ed75a767a658a9a72c355e3c4c1c8 | [
"Apache-2.0"
] | null | null | null | defmodule MarketSpreadReportsUI.LayoutViewTest do
use MarketSpreadReportsUI.ConnCase, async: true
end | 34.333333 | 49 | 0.873786 |
ac9b69d0da1f6c8bbad84e55130d0917e225b9f5 | 70,530 | exs | Elixir | test/ecto/changeset_test.exs | dvic/ecto | 6efcc52799d9573651b27aac68a699a6dc30d661 | [
"Apache-2.0"
] | null | null | null | test/ecto/changeset_test.exs | dvic/ecto | 6efcc52799d9573651b27aac68a699a6dc30d661 | [
"Apache-2.0"
] | null | null | null | test/ecto/changeset_test.exs | dvic/ecto | 6efcc52799d9573651b27aac68a699a6dc30d661 | [
"Apache-2.0"
] | null | null | null | defmodule Ecto.ChangesetTest do
use ExUnit.Case, async: true
import Ecto.Changeset
defmodule SocialSource do
use Ecto.Schema
@primary_key false
embedded_schema do
field :origin
field :url
end
def changeset(schema \\ %SocialSource{}, params) do
cast(schema, params, ~w(origi... | 38.248373 | 167 | 0.635006 |
ac9b76cf20a7a97c5f646bdce9ec15172bbcb011 | 1,708 | exs | Elixir | test/etslru_test.exs | diodechain/diode_server | 1692788bd92cc17654965878abd059d13b5e236c | [
"Apache-2.0"
] | 8 | 2021-03-12T15:35:09.000Z | 2022-03-06T06:37:49.000Z | test/etslru_test.exs | diodechain/diode_server_ex | 5cf47e5253a0caafd335d0af4dba711d4dcad42d | [
"Apache-2.0"
] | 15 | 2019-09-06T07:58:01.000Z | 2021-03-06T17:04:46.000Z | test/etslru_test.exs | diodechain/diode_server | 1692788bd92cc17654965878abd059d13b5e236c | [
"Apache-2.0"
] | 5 | 2021-10-01T12:52:28.000Z | 2022-02-02T19:29:56.000Z | # Diode Server
# Copyright 2021 Diode
# Licensed under the Diode License, Version 1.1
defmodule EtsLruTest do
use ExUnit.Case
test "base" do
lru = EtsLru.new(10)
assert EtsLru.size(lru) == 0
EtsLru.put(lru, "key", "value")
assert EtsLru.size(lru) == 1
assert EtsLru.get(lru, "key") == "value"
... | 26.276923 | 65 | 0.588993 |
ac9b777a8b031cba28abc342bd9d59ca0efc3a2b | 1,127 | exs | Elixir | config/config.exs | chewy-soft/elixir-struct | 7f2a14a791e0c5dc82aae60289a577dae3e76046 | [
"MIT"
] | 3 | 2020-01-02T19:37:21.000Z | 2022-01-15T09:11:25.000Z | config/config.exs | chewy-soft/elixir-struct | 7f2a14a791e0c5dc82aae60289a577dae3e76046 | [
"MIT"
] | 1 | 2020-03-01T18:36:28.000Z | 2020-06-05T12:30:30.000Z | config/config.exs | chewy-soft/elixir-struct | 7f2a14a791e0c5dc82aae60289a577dae3e76046 | [
"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.354839 | 73 | 0.750665 |
ac9ba347b58cb371c5ab4292fbd8aa1f57cdd09f | 916 | ex | Elixir | lib/yggdrasil/channel.ex | valiot/yggdrasil | 7395591f4eba813f508c8cb25676b0d317fefaa0 | [
"MIT"
] | 96 | 2016-02-11T22:23:30.000Z | 2022-03-20T01:57:45.000Z | lib/yggdrasil/channel.ex | valiot/yggdrasil | 7395591f4eba813f508c8cb25676b0d317fefaa0 | [
"MIT"
] | 8 | 2016-08-09T13:37:15.000Z | 2021-07-19T05:55:21.000Z | lib/yggdrasil/channel.ex | valiot/yggdrasil | 7395591f4eba813f508c8cb25676b0d317fefaa0 | [
"MIT"
] | 5 | 2017-10-26T12:11:29.000Z | 2021-07-26T10:23:13.000Z | defmodule Yggdrasil.Channel do
@moduledoc """
Channel struct definition.
The attributes are defined as follows:
+ `name` - Name of the channel.
+ `transformer` - Module where the encoding or decoding function is
defined.
+ `adapter` - Module where the adapter is defined or identifier.
+ `nam... | 24.105263 | 71 | 0.575328 |
ac9bdcc077eb0348a22364ed9f840c6144f926cf | 550 | ex | Elixir | elixir/lib/com/spoonacular/client/model/inline_object_2.ex | ddsky/spoonacular-api-clients | 63f955ceb2c356fefdd48ec634deb3c3e16a6ae7 | [
"MIT"
] | 21 | 2019-08-09T18:53:26.000Z | 2022-03-14T22:10:10.000Z | elixir/lib/com/spoonacular/client/model/inline_object_2.ex | ddsky/spoonacular-api-clients | 63f955ceb2c356fefdd48ec634deb3c3e16a6ae7 | [
"MIT"
] | null | null | null | elixir/lib/com/spoonacular/client/model/inline_object_2.ex | ddsky/spoonacular-api-clients | 63f955ceb2c356fefdd48ec634deb3c3e16a6ae7 | [
"MIT"
] | 55 | 2019-08-13T17:52:47.000Z | 2022-03-27T04:29:34.000Z | # NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
# https://openapi-generator.tech
# Do not edit the class manually.
defmodule com.spoonacular.client.Model.InlineObject2 do
@moduledoc """
"""
@derive [Poison.Encoder]
defstruct [
:"ingredients",
:"servings"
... | 19.642857 | 91 | 0.678182 |
ac9be18d832f5cfd0225d6ca28f97a254e0a0e61 | 307 | ex | Elixir | lib/type_check/default_overrides/erlang/binary.ex | 0urobor0s/elixir-type_check | 6bac178f4a55798034b12c1dcfb219eabcfb35c0 | [
"MIT"
] | null | null | null | lib/type_check/default_overrides/erlang/binary.ex | 0urobor0s/elixir-type_check | 6bac178f4a55798034b12c1dcfb219eabcfb35c0 | [
"MIT"
] | null | null | null | lib/type_check/default_overrides/erlang/binary.ex | 0urobor0s/elixir-type_check | 6bac178f4a55798034b12c1dcfb219eabcfb35c0 | [
"MIT"
] | null | null | null | # Overrides Erlang's `:binary` module:
defmodule Elixir.TypeCheck.DefaultOverrides.Erlang.Binary do
use TypeCheck
# TODO
@opaque cp() :: {any(), reference()}
@autogen_typespec false
@opaque! cp() :: {'am' | 'bm', term()}
@opaque! part() :: {start :: non_neg_integer(), length :: integer()}
end
| 27.909091 | 70 | 0.654723 |
ac9bec51739deb90fa97076fe93eb52cd4296892 | 9,729 | ex | Elixir | lib/elixir/lib/code.ex | ekosz/elixir | 62e375bc711b4072e1b68de776e96cc31f571d45 | [
"Apache-2.0"
] | 1 | 2017-10-29T16:37:08.000Z | 2017-10-29T16:37:08.000Z | lib/elixir/lib/code.ex | ekosz/elixir | 62e375bc711b4072e1b68de776e96cc31f571d45 | [
"Apache-2.0"
] | null | null | null | lib/elixir/lib/code.ex | ekosz/elixir | 62e375bc711b4072e1b68de776e96cc31f571d45 | [
"Apache-2.0"
] | null | null | null | defmodule Code do
@moduledoc """
The Code module is responsible to manage code compilation,
code evaluation and code loading.
It complements (Erlang's code module)[1] to add behavior
which is specific to Elixir.
[1]: (www.erlang.org/doc/man/code.html)
"""
@doc """
Returns all the loaded files.
... | 30.885714 | 90 | 0.670778 |
ac9c03ce7e7e924ae4cdb88a381ec09d37acd55d | 195 | ex | Elixir | lib/xunid.ex | ayarodionov/xunid | 18fdab9f2744d102d9608d8ee310a3c65685d546 | [
"MIT"
] | null | null | null | lib/xunid.ex | ayarodionov/xunid | 18fdab9f2744d102d9608d8ee310a3c65685d546 | [
"MIT"
] | null | null | null | lib/xunid.ex | ayarodionov/xunid | 18fdab9f2744d102d9608d8ee310a3c65685d546 | [
"MIT"
] | null | null | null | defmodule Xunid do
@moduledoc """
Documentation for `Xunid`.
"""
@doc """
Hello world.
## Examples
iex> Xunid.hello()
:world
"""
def hello do
:world
end
end
| 10.263158 | 28 | 0.54359 |
ac9c28b7c4f97731818ef1f265e1c94096f94689 | 760 | exs | Elixir | backend/priv/repo/migrations/20181129175628_create_places.exs | Prumme/Projet_phx_ex_gql | 6324af91f94f96ee1f8403d5397ab930347e3e4f | [
"Unlicense"
] | null | null | null | backend/priv/repo/migrations/20181129175628_create_places.exs | Prumme/Projet_phx_ex_gql | 6324af91f94f96ee1f8403d5397ab930347e3e4f | [
"Unlicense"
] | 6 | 2020-01-31T19:44:15.000Z | 2021-09-02T04:26:49.000Z | backend/priv/repo/migrations/20181129175628_create_places.exs | Prumme/Projet_phx_ex_gql | 6324af91f94f96ee1f8403d5397ab930347e3e4f | [
"Unlicense"
] | null | null | null | defmodule Getaways.Repo.Migrations.CreatePlaces do
use Ecto.Migration
def change do
create table(:places) do
add :name, :string, null: false
add :slug, :string, null: false
add :description, :string, null: false
add :location, :string, null: false
add :price_per_night, :decimal, n... | 30.4 | 62 | 0.653947 |
ac9c2ac9d9eae1aa14afc72983d52d1c2c314169 | 2,403 | exs | Elixir | config/config.exs | vheathen/club.wallprint.pro | d58d2409d8879d23ed4d60fe3b9c2e1bd82e924d | [
"MIT"
] | null | null | null | config/config.exs | vheathen/club.wallprint.pro | d58d2409d8879d23ed4d60fe3b9c2e1bd82e924d | [
"MIT"
] | 34 | 2019-11-10T11:31:37.000Z | 2019-11-27T21:26:48.000Z | config/config.exs | vheathen/club.wallprint.pro | d58d2409d8879d23ed4d60fe3b9c2e1bd82e924d | [
"MIT"
] | null | null | null | # 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.
# General application configuration
import Config
config :club,
namespace: Club,
ecto_repos: [C... | 30.0375 | 86 | 0.766126 |
ac9c39c8e23b6fc875c2d9357e8516415423809f | 2,591 | ex | Elixir | clients/deployment_manager/lib/google_api/deployment_manager/v2/model/log_config_counter_options.ex | hauptbenutzer/elixir-google-api | 7b9e3a114a49cfc774a7afd03e299a0d43e4e6b2 | [
"Apache-2.0"
] | null | null | null | clients/deployment_manager/lib/google_api/deployment_manager/v2/model/log_config_counter_options.ex | hauptbenutzer/elixir-google-api | 7b9e3a114a49cfc774a7afd03e299a0d43e4e6b2 | [
"Apache-2.0"
] | null | null | null | clients/deployment_manager/lib/google_api/deployment_manager/v2/model/log_config_counter_options.ex | hauptbenutzer/elixir-google-api | 7b9e3a114a49cfc774a7afd03e299a0d43e4e6b2 | [
"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... | 50.803922 | 1,005 | 0.753377 |
ac9c496cad841a617d45661aa0a1b76ac77d6a08 | 1,762 | exs | Elixir | test/mix_adr_test.exs | Jwsonic/mix_adr | 0ca79fa3a7f4b1fa602c22b95f9cc6c5aa0faa7c | [
"MIT"
] | null | null | null | test/mix_adr_test.exs | Jwsonic/mix_adr | 0ca79fa3a7f4b1fa602c22b95f9cc6c5aa0faa7c | [
"MIT"
] | null | null | null | test/mix_adr_test.exs | Jwsonic/mix_adr | 0ca79fa3a7f4b1fa602c22b95f9cc6c5aa0faa7c | [
"MIT"
] | null | null | null | defmodule MixAdrTest do
use ExUnit.Case, async: false
doctest MixAdr
alias MixAdr.Config
describe "Config.load/0" do
setup do
# Clean out application configs between tests
on_exit(fn ->
Enum.each([:adr_dir, :template_file], fn key ->
:ok = Application.delete_env(:mix_adr, key... | 29.366667 | 74 | 0.595914 |
ac9c50445b31183e578bdb66ef2d5546d65cfc25 | 7,214 | ex | Elixir | lib/mockery/assertions.ex | MichalDolata/mockery | 8d6c39b3bd0081d2d789438f946628b52930fd55 | [
"Apache-2.0"
] | null | null | null | lib/mockery/assertions.ex | MichalDolata/mockery | 8d6c39b3bd0081d2d789438f946628b52930fd55 | [
"Apache-2.0"
] | null | null | null | lib/mockery/assertions.ex | MichalDolata/mockery | 8d6c39b3bd0081d2d789438f946628b52930fd55 | [
"Apache-2.0"
] | null | null | null | defmodule Mockery.Assertions do
@moduledoc """
This module contains a set of additional assertion functions.
"""
alias Mockery.Error
alias Mockery.History
alias Mockery.Utils
@doc """
Asserts that function from given module with given name or name and arity
was called at least once.
**NOTE**: Moc... | 28.179688 | 96 | 0.659551 |
ac9c81083b33f8fdcdcd332004cb9c18c02c582b | 3,085 | ex | Elixir | lib/teslamate/updater.ex | douglasevaristo/teslamate | d239023942b319e9446d2da316d0afbddf701b9d | [
"MIT"
] | 1 | 2020-08-31T10:21:12.000Z | 2020-08-31T10:21:12.000Z | lib/teslamate/updater.ex | douglasevaristo/teslamate | d239023942b319e9446d2da316d0afbddf701b9d | [
"MIT"
] | 94 | 2020-10-26T06:28:30.000Z | 2022-03-30T15:03:41.000Z | lib/teslamate/updater.ex | douglasevaristo/teslamate | d239023942b319e9446d2da316d0afbddf701b9d | [
"MIT"
] | null | null | null | defmodule TeslaMate.Updater do
use GenServer
alias Finch.Response
alias TeslaMate.HTTP
require Logger
defmodule State, do: defstruct([:update, :version])
defmodule Release, do: defstruct([:version, :prerelease])
@url "https://api.github.com/repos/adriankumpf/teslamate/releases/latest"
@name __MODULE_... | 27.061404 | 91 | 0.609724 |
ac9c88676267529f1d781235dc2230b24ba66856 | 255 | ex | Elixir | lib/ggity_demo.ex | srowley/ggity_demo | 172815ce7d897ef965df1d992ba50e3290f8348d | [
"MIT"
] | null | null | null | lib/ggity_demo.ex | srowley/ggity_demo | 172815ce7d897ef965df1d992ba50e3290f8348d | [
"MIT"
] | null | null | null | lib/ggity_demo.ex | srowley/ggity_demo | 172815ce7d897ef965df1d992ba50e3290f8348d | [
"MIT"
] | null | null | null | defmodule GGityDemo do
@moduledoc """
GGityDemo keeps the contexts that define your domain
and business logic.
Contexts are also responsible for managing your data, regardless
if it comes from the database, an external API or others.
"""
end
| 25.5 | 66 | 0.756863 |
ac9c8bb3b2427b2792a35122a75fda5731d378db | 945 | ex | Elixir | test/support/channel_case.ex | LittleKidogo/quick_bytes_system | 3f8c1d75b26c5835f70eed3a464351e806a104d9 | [
"MIT"
] | 1 | 2018-08-10T02:53:13.000Z | 2018-08-10T02:53:13.000Z | test/support/channel_case.ex | LittleKidogo/quick_bytes_backend | 3f8c1d75b26c5835f70eed3a464351e806a104d9 | [
"MIT"
] | 34 | 2018-08-07T09:53:18.000Z | 2018-10-24T21:12:01.000Z | test/support/channel_case.ex | LittleKidogo/quick_bytes_backend | 3f8c1d75b26c5835f70eed3a464351e806a104d9 | [
"MIT"
] | null | null | null | defmodule QbBackendWeb.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 ... | 24.868421 | 71 | 0.718519 |
ac9ca2fddcd36dcb8e9c28cd6a0268d2ebe45f05 | 3,599 | ex | Elixir | lib/exml/transpiler.ex | kevinkoltz/exml | c76d2c03d88dcc434f98fa88fd3922d1ca77c691 | [
"Apache-2.0"
] | null | null | null | lib/exml/transpiler.ex | kevinkoltz/exml | c76d2c03d88dcc434f98fa88fd3922d1ca77c691 | [
"Apache-2.0"
] | null | null | null | lib/exml/transpiler.ex | kevinkoltz/exml | c76d2c03d88dcc434f98fa88fd3922d1ca77c691 | [
"Apache-2.0"
] | null | null | null | defmodule ExML.Transpiler do
@moduledoc """
Transpiles EXmL source into EEx source.
Ideally, transpiling would be skipped and EXmL source would compile
directly to an AST.
TODO: move these functions into a behaviour and have modules like ExML.Elements.CfloopRange.transpile()?
or protocols, Transpiler.tran... | 35.284314 | 106 | 0.64379 |
ac9ce8c8989ee22da8a2c88ff6047cdbf9df63e6 | 3,152 | exs | Elixir | apps/api_web/test/api_web/views/shape_view_test.exs | fjlanasa/api | c39bc393aea572bfb81754b2ea1adf9dda9ce24a | [
"MIT"
] | 62 | 2019-01-17T12:34:39.000Z | 2022-03-20T21:49:47.000Z | apps/api_web/test/api_web/views/shape_view_test.exs | fjlanasa/api | c39bc393aea572bfb81754b2ea1adf9dda9ce24a | [
"MIT"
] | 375 | 2019-02-13T15:30:50.000Z | 2022-03-30T18:50:41.000Z | apps/api_web/test/api_web/views/shape_view_test.exs | fjlanasa/api | c39bc393aea572bfb81754b2ea1adf9dda9ce24a | [
"MIT"
] | 14 | 2019-01-16T19:35:57.000Z | 2022-02-26T18:55:54.000Z | defmodule ApiWeb.ShapeViewTest do
use ApiWeb.ConnCase
import ApiWeb.ShapeView
@shape %Model.Shape{
id: "shape",
route_id: "route",
direction_id: 1,
priority: 1,
name: "origin - variant",
polyline: "polyline_string"
}
describe "attributes/2" do
test "excludes fields on versions a... | 36.651163 | 97 | 0.623731 |
ac9d04fa01ba0b56bc31e4d1f2b2e4d7c0b50c58 | 342 | exs | Elixir | priv/repo/migrations/20190303231653_fix_boards_users.exs | alchexmist/erlnote | e1f164e63616316e1d3869ebfae5ed2ae96c3ccd | [
"Apache-2.0"
] | null | null | null | priv/repo/migrations/20190303231653_fix_boards_users.exs | alchexmist/erlnote | e1f164e63616316e1d3869ebfae5ed2ae96c3ccd | [
"Apache-2.0"
] | 1 | 2019-11-02T13:46:12.000Z | 2019-11-02T13:46:12.000Z | priv/repo/migrations/20190303231653_fix_boards_users.exs | alchexmist/erlnote | e1f164e63616316e1d3869ebfae5ed2ae96c3ccd | [
"Apache-2.0"
] | null | null | null | defmodule Erlnote.Repo.Migrations.FixBoardsUsers do
use Ecto.Migration
def change do
alter table(:boards_users, primary_key: false) do
modify :boards_id, references(:boards, on_delete: :delete_all), null: false
modify :users_id, references(:users, on_delete: :delete_all), null: false
remove :... | 26.307692 | 81 | 0.719298 |
ac9d7ad9f200c286dfbf867d3190d7d6179c736c | 996 | ex | Elixir | lib/starship/drive/engine.ex | probably-not/starship | aaa107bb0efec06fc841b0cae99cb69294887337 | [
"MIT"
] | 2 | 2019-10-22T08:22:22.000Z | 2019-11-18T07:24:39.000Z | lib/starship/drive/engine.ex | coby-spotim/starship | aaa107bb0efec06fc841b0cae99cb69294887337 | [
"MIT"
] | null | null | null | lib/starship/drive/engine.ex | coby-spotim/starship | aaa107bb0efec06fc841b0cae99cb69294887337 | [
"MIT"
] | null | null | null | defmodule Starship.Drive.Engine do
@moduledoc """
The TCP Acceptor supervisor, which spawns and supervises `Starship.Drive`
processes to handle the requests to the `Starship` Webserver.
"""
require Logger
@spec start(map) :: no_return
def start(config) do
Process.flag(:trap_exit, true)
loop(conf... | 24.292683 | 95 | 0.634538 |
ac9daede8a2b6c0bc01394fec0c8de7850bec759 | 15,380 | ex | Elixir | lib/phoenix_live_view/html_engine.ex | matthewlehner/phoenix_live_view | 5f3ffe94c2305c14f4fe72d1c05a917b6f751407 | [
"MIT"
] | null | null | null | lib/phoenix_live_view/html_engine.ex | matthewlehner/phoenix_live_view | 5f3ffe94c2305c14f4fe72d1c05a917b6f751407 | [
"MIT"
] | null | null | null | lib/phoenix_live_view/html_engine.ex | matthewlehner/phoenix_live_view | 5f3ffe94c2305c14f4fe72d1c05a917b6f751407 | [
"MIT"
] | null | null | null | defmodule Phoenix.LiveView.HTMLEngine do
@moduledoc """
The HTMLEngine that powers `.heex` templates and the `~H` sigil.
"""
alias Phoenix.LiveView.HTMLTokenizer
@behaviour Phoenix.Template.Engine
# TODO: Use @impl true instead of @doc false when we require Elixir v1.12
@doc false
def compile(path, ... | 29.463602 | 122 | 0.625423 |
ac9db1d39863e5f11877e86a43bcdd9882f058c8 | 617 | exs | Elixir | exercises/lists_and_recursions_1.exs | renanlage/programming-elixir-book | 71e58398269cde2b76a377d28cc906fb528c4134 | [
"MIT"
] | 8 | 2018-08-26T08:10:08.000Z | 2021-04-05T16:05:05.000Z | exercises/lists_and_recursions_1.exs | renanlage/programming-elixir-book | 71e58398269cde2b76a377d28cc906fb528c4134 | [
"MIT"
] | null | null | null | exercises/lists_and_recursions_1.exs | renanlage/programming-elixir-book | 71e58398269cde2b76a377d28cc906fb528c4134 | [
"MIT"
] | 1 | 2019-10-08T09:56:43.000Z | 2019-10-08T09:56:43.000Z | defmodule MyList do
def mapsum([], _func), do: 0
def mapsum([head|tail], func), do: func.(head) + mapsum(tail, func)
end
defmodule MyListTailCall do
def mapsum([list], func), do: _mapsum(list, func, 0)
defp _mapsum([], _, total), do: total
defp _mapsum([head|tail], func, total) do
_mapsum(tail, func, f... | 30.85 | 69 | 0.612642 |
ac9df3e01fc22732a89b66c946744e3398bfaa57 | 1,903 | ex | Elixir | clients/datastore/lib/google_api/datastore/v1/model/google_longrunning_list_operations_response.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/datastore/lib/google_api/datastore/v1/model/google_longrunning_list_operations_response.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | 1 | 2020-12-18T09:25:12.000Z | 2020-12-18T09:25:12.000Z | clients/datastore/lib/google_api/datastore/v1/model/google_longrunning_list_operations_response.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... | 38.06 | 185 | 0.756174 |
ac9e2597c104510526b5cb89dd2ab7e4010862b9 | 63 | exs | Elixir | config/test.exs | jadercorrea/epub-partial-response-api-example | f92fa8e094fd346ace05d7b07304dfd4727661c9 | [
"MIT"
] | null | null | null | config/test.exs | jadercorrea/epub-partial-response-api-example | f92fa8e094fd346ace05d7b07304dfd4727661c9 | [
"MIT"
] | null | null | null | config/test.exs | jadercorrea/epub-partial-response-api-example | f92fa8e094fd346ace05d7b07304dfd4727661c9 | [
"MIT"
] | null | null | null | use Mix.Config
config :epub_api, :endpoint, port: [port: 4000]
| 21 | 47 | 0.730159 |
ac9e37658dae06e4585dfe94193fdb94102d8225 | 1,132 | ex | Elixir | lib/cafex/lock/zk/server.ex | MishaConway/cafex | 32965b7e099bc45de24c229cc76f7b83b35ff7b4 | [
"Apache-2.0"
] | null | null | null | lib/cafex/lock/zk/server.ex | MishaConway/cafex | 32965b7e099bc45de24c229cc76f7b83b35ff7b4 | [
"Apache-2.0"
] | null | null | null | lib/cafex/lock/zk/server.ex | MishaConway/cafex | 32965b7e099bc45de24c229cc76f7b83b35ff7b4 | [
"Apache-2.0"
] | null | null | null | defmodule Cafex.Lock.ZK.Server do
use GenServer
def start_link(parent) do
GenServer.start_link __MODULE__, [parent]
end
def acquire(pid, zk_pid, path, seq) do
GenServer.call pid, {:acquire, zk_pid, path, seq}
end
def release(pid, zk_pid, seq) do
GenServer.call pid, {:release, zk_pid, seq}
e... | 21.769231 | 65 | 0.657244 |
ac9e5d11f2851bef1a62abac9998af2f5fc1352d | 773 | ex | Elixir | lib/redis/echo_client.ex | santosh79/remixdb | 4f5ab898241b61ef00acf508c63363520c7b87d0 | [
"MIT"
] | 48 | 2016-06-01T11:40:34.000Z | 2021-05-26T13:20:42.000Z | lib/redis/echo_client.ex | santosh79/remixdb | 4f5ab898241b61ef00acf508c63363520c7b87d0 | [
"MIT"
] | 2 | 2016-06-06T10:20:03.000Z | 2016-06-11T05:06:10.000Z | lib/redis/echo_client.ex | santosh79/remixdb | 4f5ab898241b61ef00acf508c63363520c7b87d0 | [
"MIT"
] | 3 | 2016-07-02T20:54:58.000Z | 2018-04-10T02:36:26.000Z | import Remixdb.Redis.ResponseHandler, only: [send_ok: 1]
defmodule Remixdb.RedisEchoClient do
use GenServer
def start_link(socket) do
GenServer.start_link __MODULE__, {:ok, socket}, []
end
defmodule State do
defstruct socket: nil, parser: nil
end
def init({:ok, socket}) do
send self(), :real_... | 24.15625 | 82 | 0.683053 |
ac9e64b90e776a1fce71f30636455d358c835b77 | 6,652 | ex | Elixir | clients/groups_settings/lib/google_api/groups_settings/v1/api/groups.ex | hauptbenutzer/elixir-google-api | 7b9e3a114a49cfc774a7afd03e299a0d43e4e6b2 | [
"Apache-2.0"
] | null | null | null | clients/groups_settings/lib/google_api/groups_settings/v1/api/groups.ex | hauptbenutzer/elixir-google-api | 7b9e3a114a49cfc774a7afd03e299a0d43e4e6b2 | [
"Apache-2.0"
] | null | null | null | clients/groups_settings/lib/google_api/groups_settings/v1/api/groups.ex | hauptbenutzer/elixir-google-api | 7b9e3a114a49cfc774a7afd03e299a0d43e4e6b2 | [
"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... | 38.674419 | 170 | 0.680397 |
ac9e6e3a8f64e25f4a6e24b2f065a9499ff4e18e | 2,277 | ex | Elixir | clients/dfa_reporting/lib/google_api/dfa_reporting/v34/model/dimension_value_request.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2021-12-20T03:40:53.000Z | 2021-12-20T03:40:53.000Z | clients/dfa_reporting/lib/google_api/dfa_reporting/v34/model/dimension_value_request.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2020-08-18T00:11:23.000Z | 2020-08-18T00:44:16.000Z | clients/dfa_reporting/lib/google_api/dfa_reporting/v34/model/dimension_value_request.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... | 38.59322 | 174 | 0.704875 |
ac9e84827ab4541e65d36c9e40f508a5f4705790 | 865 | ex | Elixir | lib/bitcoin_price_scraper/jwt_auth.ex | ohyecloudy/bitcoin_price_scraper | 888eca9641c555e961739f9292d0ddd3d3172b92 | [
"MIT"
] | 1 | 2021-09-06T06:09:11.000Z | 2021-09-06T06:09:11.000Z | lib/bitcoin_price_scraper/jwt_auth.ex | data-miner00/bitcoin_price_scraper | 888eca9641c555e961739f9292d0ddd3d3172b92 | [
"MIT"
] | null | null | null | lib/bitcoin_price_scraper/jwt_auth.ex | data-miner00/bitcoin_price_scraper | 888eca9641c555e961739f9292d0ddd3d3172b92 | [
"MIT"
] | 2 | 2021-06-27T03:35:27.000Z | 2022-03-28T17:38:51.000Z | defmodule BitcoinPriceScraper.JwtAuth do
alias BitcoinPriceScraper.Jwt
@behaviour Tesla.Middleware
@impl Tesla.Middleware
def call(env, next, _options) do
env
|> add_auth_header()
|> Tesla.run(next)
end
defp add_auth_header(env) do
payload = %{
access_key: Application.get_env(:bitco... | 21.625 | 81 | 0.597688 |
ac9e95a58d75522eed43393b8e62fabc7ad31556 | 1,461 | ex | Elixir | lib/documents/conventions.ex | YgorCastor/ravix | ad3d191e2682b87d533a2d41899ed10e00b4dc55 | [
"Apache-2.0"
] | 9 | 2022-01-11T10:01:54.000Z | 2022-03-31T06:50:59.000Z | lib/documents/conventions.ex | YgorCastor/ravix | ad3d191e2682b87d533a2d41899ed10e00b4dc55 | [
"Apache-2.0"
] | 2 | 2022-03-21T20:13:13.000Z | 2022-03-28T21:07:47.000Z | lib/documents/conventions.ex | YgorCastor/ravix | ad3d191e2682b87d533a2d41899ed10e00b4dc55 | [
"Apache-2.0"
] | null | null | null | defmodule Ravix.Documents.Conventions do
@moduledoc """
Document conventions structure
## Fields
- max_number_of_requests_per_session: How many requests can be done in a single session
- max_ids_to_catch: Maximum amount of ids that can be loaded
- timeout: How much time until an api call times out
- use_... | 38.447368 | 89 | 0.712526 |
ac9eaaab65f19e5b0375a08491bb35fc436e45b2 | 84 | ex | Elixir | lib/team_health/person.ex | benstafford/team_health | a9a3f637769487733e1dee5d2fc60e999c173f3a | [
"MIT"
] | null | null | null | lib/team_health/person.ex | benstafford/team_health | a9a3f637769487733e1dee5d2fc60e999c173f3a | [
"MIT"
] | null | null | null | lib/team_health/person.ex | benstafford/team_health | a9a3f637769487733e1dee5d2fc60e999c173f3a | [
"MIT"
] | null | null | null | defmodule TeamHealth.Person do
defstruct [:first_name, :last_name, :username]
end
| 21 | 48 | 0.785714 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.