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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
1cfa851748bc49f74a80b476c9d86ba6c8eb286a | 852 | exs | Elixir | test/mix/tasks/expected.mnesia.clear_test.exs | ejpcmac/expected | c2b03bfa9bcb7efd52cf4003fb46f1309e8aa3c4 | [
"MIT"
] | 33 | 2018-01-18T12:16:19.000Z | 2021-07-30T00:33:26.000Z | test/mix/tasks/expected.mnesia.clear_test.exs | ejpcmac/expected | c2b03bfa9bcb7efd52cf4003fb46f1309e8aa3c4 | [
"MIT"
] | 5 | 2018-01-18T12:56:28.000Z | 2019-09-30T07:16:00.000Z | test/mix/tasks/expected.mnesia.clear_test.exs | ejpcmac/expected | c2b03bfa9bcb7efd52cf4003fb46f1309e8aa3c4 | [
"MIT"
] | 1 | 2018-08-08T12:02:44.000Z | 2018-08-08T12:02:44.000Z | Mix.shell(Mix.Shell.Process)
defmodule Mix.Tasks.Expected.Mnesia.ClearTest do
use Expected.MnesiaCase
import Mix.Tasks.Expected.Mnesia.Clear
describe "run/1" do
test "clears all logins from the store accorting to the configuration" do
:mnesia.create_table(@table, attributes: [:key, :value])
re... | 28.4 | 77 | 0.664319 |
1cfa8b8a897dd7c7b5f587d017a5ef8a57797314 | 1,899 | exs | Elixir | mix.exs | blvdgroup/crater | 78d03de2eac73d90148df6c5d2d03e99b9b5ccb7 | [
"Apache-2.0"
] | 1 | 2018-03-13T08:15:50.000Z | 2018-03-13T08:15:50.000Z | mix.exs | blvdgroup/crater | 78d03de2eac73d90148df6c5d2d03e99b9b5ccb7 | [
"Apache-2.0"
] | 1 | 2018-03-17T15:45:26.000Z | 2018-03-17T15:45:26.000Z | mix.exs | blvdgroup/crater | 78d03de2eac73d90148df6c5d2d03e99b9b5ccb7 | [
"Apache-2.0"
] | 1 | 2017-08-30T16:13:09.000Z | 2017-08-30T16:13:09.000Z | defmodule Crater.Mixfile do
use Mix.Project
def project do
[
app: :crater,
version: "0.0.1",
elixir: "~> 1.4",
elixirc_paths: elixirc_paths(Mix.env()),
compilers: [:phoenix, :gettext] ++ Mix.compilers(),
start_permanent: Mix.env() == :prod,
aliases: aliases(),
de... | 27.521739 | 79 | 0.562928 |
1cfa90885c1958b3d3506dd91a8591af6298a98a | 2,290 | exs | Elixir | mix.exs | mmacai/cloudevents-ex | ef7ab9e39019112e0bec2058c3611ebcd04db605 | [
"Apache-2.0"
] | null | null | null | mix.exs | mmacai/cloudevents-ex | ef7ab9e39019112e0bec2058c3611ebcd04db605 | [
"Apache-2.0"
] | null | null | null | mix.exs | mmacai/cloudevents-ex | ef7ab9e39019112e0bec2058c3611ebcd04db605 | [
"Apache-2.0"
] | null | null | null | defmodule Cloudevents.MixProject do
@moduledoc false
use Mix.Project
def project do
[
app: :cloudevents,
description: description(),
version: "0.3.0",
elixir: "~> 1.10",
start_permanent: Mix.env() == :prod,
deps: deps(),
package: package(),
docs: docs(),
... | 23.608247 | 84 | 0.535371 |
1cfab3f39b73022b0ef6e50d0c18600ac1071c29 | 340 | exs | Elixir | test/solverlview_web/live/page_live_test.exs | bokner/solverlview | 52a527bc653619fd35977d951b36207ba0ebd9cc | [
"MIT"
] | 10 | 2020-09-18T19:26:51.000Z | 2021-07-08T19:26:00.000Z | test/solverlview_web/live/page_live_test.exs | bokner/solverview | 52a527bc653619fd35977d951b36207ba0ebd9cc | [
"MIT"
] | null | null | null | test/solverlview_web/live/page_live_test.exs | bokner/solverview | 52a527bc653619fd35977d951b36207ba0ebd9cc | [
"MIT"
] | null | null | null | defmodule SolverlviewWeb.PageLiveTest do
use SolverlviewWeb.ConnCase
import Phoenix.LiveViewTest
test "disconnected and connected render", %{conn: conn} do
{:ok, page_live, disconnected_html} = live(conn, "/")
assert disconnected_html =~ "Welcome to Phoenix!"
assert render(page_live) =~ "Welcome to ... | 28.333333 | 60 | 0.732353 |
1cfacbcad02973073151533c08c2f174630128a1 | 1,921 | ex | Elixir | clients/document_ai/lib/google_api/document_ai/v1beta2/model/google_cloud_documentai_v1beta1_document_page_detected_language.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2021-12-20T03:40:53.000Z | 2021-12-20T03:40:53.000Z | clients/document_ai/lib/google_api/document_ai/v1beta2/model/google_cloud_documentai_v1beta1_document_page_detected_language.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2020-08-18T00:11:23.000Z | 2020-08-18T00:44:16.000Z | clients/document_ai/lib/google_api/document_ai/v1beta2/model/google_cloud_documentai_v1beta1_document_page_detected_language.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... | 34.927273 | 207 | 0.743363 |
1cfae5d4fedd3f4b0ad1a90d4a98db4e19054d2f | 921 | exs | Elixir | test/frank_test.exs | triptec/frank | b3cdea238e99595b5e2d8bcc23b97a6572f77d3e | [
"MIT"
] | 1 | 2015-11-26T10:27:35.000Z | 2015-11-26T10:27:35.000Z | test/frank_test.exs | triptec/frank | b3cdea238e99595b5e2d8bcc23b97a6572f77d3e | [
"MIT"
] | null | null | null | test/frank_test.exs | triptec/frank | b3cdea238e99595b5e2d8bcc23b97a6572f77d3e | [
"MIT"
] | null | null | null | defmodule FrankTest do
use ExUnit.Case
import FrankTestUtil
doctest Frank
test "publish with uri, queue and payload" do
queue = "test"
msg = "uri, queue and payload"
fun = fn (payload, _meta) ->
send :frank_test, payload
end
Process.register(self, :frank_test)
{:ok, cmp} = Frank.s... | 28.78125 | 92 | 0.653637 |
1cfae66bff55a30ed4a9061957142b553d14eed6 | 6,920 | ex | Elixir | lib/game/environment.ex | shanesveller/ex_venture | 68507da11442a9e0423073fcd305e9021f649ca1 | [
"MIT"
] | null | null | null | lib/game/environment.ex | shanesveller/ex_venture | 68507da11442a9e0423073fcd305e9021f649ca1 | [
"MIT"
] | null | null | null | lib/game/environment.ex | shanesveller/ex_venture | 68507da11442a9e0423073fcd305e9021f649ca1 | [
"MIT"
] | null | null | null | defmodule Game.Environment do
@moduledoc """
Look at your surroundings, whether a room or an overworld
"""
alias Game.Room
alias Game.Overworld
alias Game.Overworld.Sector
@type state :: Data.Room.t()
defmacro __using__(_opts) do
quote do
@environment Application.get_env(:ex_venture, :game)... | 27.137255 | 94 | 0.660549 |
1cfb03ce56036833ca3a9e9c9d616f43a7ef46de | 904 | ex | Elixir | apps/general/lib/general/application.ex | bornmeyer/janus_signaling | cbab905aaa844a2762d4647f9363370cecd3db22 | [
"Apache-2.0"
] | null | null | null | apps/general/lib/general/application.ex | bornmeyer/janus_signaling | cbab905aaa844a2762d4647f9363370cecd3db22 | [
"Apache-2.0"
] | null | null | null | apps/general/lib/general/application.ex | bornmeyer/janus_signaling | cbab905aaa844a2762d4647f9363370cecd3db22 | [
"Apache-2.0"
] | null | null | null | defmodule General.Application do
# See https://hexdocs.pm/elixir/Application.html
# for more information on OTP Applications
@moduledoc false
use Application
require Logger
def start(_type, _args) do
children = [
Plug.Cowboy.child_spec(
scheme: :http,
plug: General.Router,
... | 20.545455 | 61 | 0.580752 |
1cfb16028538ea652dbd2605a84d21fae4b80578 | 1,120 | ex | Elixir | packages/templates/src/project/potionx/lib/{{ appName }}_web/channels/user_socket.ex | shuv1824/potionx | a5888413b13a520d8ddf79fb26b7483e441737c3 | [
"MIT"
] | 31 | 2021-02-16T20:50:46.000Z | 2022-02-03T10:38:07.000Z | packages/templates/src/project/potionx/lib/{{ appName }}_web/channels/user_socket.ex | shuv1824/potionx | a5888413b13a520d8ddf79fb26b7483e441737c3 | [
"MIT"
] | 6 | 2021-04-07T21:50:20.000Z | 2022-02-06T21:54:04.000Z | packages/templates/src/project/potionx/lib/{{ appName }}_web/channels/user_socket.ex | shuv1824/potionx | a5888413b13a520d8ddf79fb26b7483e441737c3 | [
"MIT"
] | 4 | 2021-03-25T17:59:44.000Z | 2021-04-25T16:28:22.000Z | defmodule <%= webNamespace %>.UserSocket do
use Phoenix.Socket
## Channels
# channel "room:*", <%= webNamespace %>.RoomChannel
# Socket params are passed from the client and can
# be used to verify and authenticate a user. After
# verification, you can put default assigns into
# the socket that will be ... | 31.111111 | 84 | 0.676786 |
1cfb2b5cd3d3a39afb59d167be072ac3e2d56f76 | 3,621 | exs | Elixir | mix.exs | randaalex/pow | 2a8c8db4652f7cb2c58d3a897e02b1d47e76f27b | [
"MIT"
] | null | null | null | mix.exs | randaalex/pow | 2a8c8db4652f7cb2c58d3a897e02b1d47e76f27b | [
"MIT"
] | null | null | null | mix.exs | randaalex/pow | 2a8c8db4652f7cb2c58d3a897e02b1d47e76f27b | [
"MIT"
] | null | null | null | defmodule Pow.MixProject do
use Mix.Project
@version "1.0.13"
def project do
[
app: :pow,
version: @version,
elixir: "~> 1.6",
elixirc_paths: elixirc_paths(Mix.env()),
start_permanent: Mix.env() == :prod,
compilers: [:phoenix] ++ Mix.compilers(),
deps: deps(),
... | 30.686441 | 92 | 0.564761 |
1cfb788ea193f439987c6d460198415472d3e3b3 | 235 | exs | Elixir | binary_data_over_phoenix_sockets/test/controllers/page_controller_test.exs | StoiximanServices/blog | b164ae5e8fb4701ee40925aca9aef2297b80be95 | [
"MIT"
] | 10 | 2016-11-28T03:38:36.000Z | 2021-08-24T10:38:38.000Z | binary_data_over_phoenix_sockets/test/controllers/page_controller_test.exs | StoiximanServices/blog | b164ae5e8fb4701ee40925aca9aef2297b80be95 | [
"MIT"
] | null | null | null | binary_data_over_phoenix_sockets/test/controllers/page_controller_test.exs | StoiximanServices/blog | b164ae5e8fb4701ee40925aca9aef2297b80be95 | [
"MIT"
] | 3 | 2018-07-11T08:31:41.000Z | 2019-01-24T18:16:44.000Z | defmodule BinaryDataOverPhoenixSockets.PageControllerTest do
use BinaryDataOverPhoenixSockets.ConnCase
test "GET /", %{conn: conn} do
conn = get conn, "/"
assert html_response(conn, 200) =~ "Welcome to Phoenix!"
end
end
| 26.111111 | 60 | 0.731915 |
1cfb81d17ac6eb4f08a0dff99774db7a7b67cbfa | 177 | exs | Elixir | config/test.exs | gregnar/ex_vmstats | 5cc048fc19ad1db3c24f2f70fb0555a181efc945 | [
"Apache-2.0"
] | null | null | null | config/test.exs | gregnar/ex_vmstats | 5cc048fc19ad1db3c24f2f70fb0555a181efc945 | [
"Apache-2.0"
] | null | null | null | config/test.exs | gregnar/ex_vmstats | 5cc048fc19ad1db3c24f2f70fb0555a181efc945 | [
"Apache-2.0"
] | null | null | null | use Mix.Config
# Print only warnings and errors during test
config :logger, :console,
format: "$metadata[$level] $message\n",
level: :warn
config :logger, :truncate, 99999 | 22.125 | 44 | 0.723164 |
1cfb820ee4858dc90b44303001c6b9f6db3e230d | 4,023 | ex | Elixir | lib/protobuf.ex | wojtekmach/protobuf | 3b251d286dc94745fc6a92fcbf9be03f44bb9b46 | [
"MIT"
] | null | null | null | lib/protobuf.ex | wojtekmach/protobuf | 3b251d286dc94745fc6a92fcbf9be03f44bb9b46 | [
"MIT"
] | null | null | null | lib/protobuf.ex | wojtekmach/protobuf | 3b251d286dc94745fc6a92fcbf9be03f44bb9b46 | [
"MIT"
] | null | null | null | defmodule Protobuf do
@moduledoc """
`protoc` should always be used to generate code instead of writing the code by hand.
By `use` this module, macros defined in `Protobuf.DSL` will be injected. Most of thee macros
are equal to definition in .proto files.
defmodule Foo do
use Protobuf, syntax: :... | 25.788462 | 104 | 0.664678 |
1cfba4409b5029fd3efbfd7c2417bd6bbaf53e4a | 7,876 | exs | Elixir | test/protobuf/encoder_test.exs | wojtekmach/protobuf | 3b251d286dc94745fc6a92fcbf9be03f44bb9b46 | [
"MIT"
] | null | null | null | test/protobuf/encoder_test.exs | wojtekmach/protobuf | 3b251d286dc94745fc6a92fcbf9be03f44bb9b46 | [
"MIT"
] | null | null | null | test/protobuf/encoder_test.exs | wojtekmach/protobuf | 3b251d286dc94745fc6a92fcbf9be03f44bb9b46 | [
"MIT"
] | null | null | null | defmodule Protobuf.EncoderTest do
use ExUnit.Case, async: true
alias Protobuf.Encoder
test "encodes one simple field" do
bin = Encoder.encode(TestMsg.Foo.new(a: 42))
assert bin == <<8, 42>>
end
test "encodes full fields" do
bin = <<8, 42, 17, 100, 0, 0, 0, 0, 0, 0, 0, 26, 3, 115, 116, 114, 45, ... | 33.514894 | 97 | 0.599035 |
1cfbd005e72d3f3cc0d6839149bc46f263ebe01e | 1,096 | ex | Elixir | lib/bson/utils.ex | hauleth/mongodb | d1be214cb38494bfd2cb861628526b853e7b776f | [
"Apache-2.0"
] | 286 | 2017-06-06T04:21:31.000Z | 2021-09-11T16:37:59.000Z | lib/bson/utils.ex | hauleth/mongodb | d1be214cb38494bfd2cb861628526b853e7b776f | [
"Apache-2.0"
] | 202 | 2017-05-28T13:22:01.000Z | 2020-05-15T20:15:51.000Z | lib/bson/utils.ex | hauleth/mongodb | d1be214cb38494bfd2cb861628526b853e7b776f | [
"Apache-2.0"
] | 120 | 2016-12-16T17:05:12.000Z | 2020-05-15T16:20:17.000Z | defmodule BSON.Utils do
@moduledoc false
defmacro __using__(_) do
quote do
import BSON.Utils
import Mongo.BinaryUtils
@type_float 0x01
@type_string 0x02
@type_document 0x03
@type_array 0x04
@type_binary 0x05
@type_undefined 0x06
@type_objectid 0x07
@... | 21.490196 | 66 | 0.667883 |
1cfc200a836509cb562baaae5e4214c909011b3d | 247 | exs | Elixir | server/.dialyzer_ignore.exs | BlueHotDog/buff | 0403f68867e950945a47cce2d7442974d12583b2 | [
"MIT"
] | 1 | 2020-03-18T17:29:32.000Z | 2020-03-18T17:29:32.000Z | server/.dialyzer_ignore.exs | BlueHotDog/buff | 0403f68867e950945a47cce2d7442974d12583b2 | [
"MIT"
] | 26 | 2019-06-09T18:35:45.000Z | 2020-07-30T17:05:58.000Z | server/.dialyzer_ignore.exs | BlueHotDog/buff | 0403f68867e950945a47cce2d7442974d12583b2 | [
"MIT"
] | null | null | null | [
{":0:unknown_function Function ExUnit.Callbacks.__merge__/3 does not exist."},
{":0:unknown_function Function ExUnit.Callbacks.on_exit/1 does not exist."},
{":0:unknown_function Function ExUnit.CaseTemplate.__proxy__/2 does not exist."}
]
| 41.166667 | 82 | 0.757085 |
1cfc5270aff8aa1a92f70b81c89731080ff2b0b2 | 2,491 | ex | Elixir | lib/nerves_livebook/mix_install.ex | djcarpe/nerves_livebook | 15da67d7b0dcb9e3b67696519ba671b2b477ae02 | [
"Apache-2.0"
] | null | null | null | lib/nerves_livebook/mix_install.ex | djcarpe/nerves_livebook | 15da67d7b0dcb9e3b67696519ba671b2b477ae02 | [
"Apache-2.0"
] | 16 | 2021-09-10T21:35:13.000Z | 2022-03-18T13:41:54.000Z | lib/nerves_livebook/mix_install.ex | djcarpe/nerves_livebook | 15da67d7b0dcb9e3b67696519ba671b2b477ae02 | [
"Apache-2.0"
] | null | null | null | defmodule NervesLivebook.MixInstall do
@moduledoc """
Simulate Mix.install for Nerves Livebook
Nerves Livebook currently doesn't support `Mix.install/1`, but hopefully it
will in the future. As a workaround, check whether dependencies that the user
specifies are available and give them a help message if not.... | 31.935897 | 97 | 0.646327 |
1cfc891e809dd8782ac928e535381cebcfd211db | 7,617 | ex | Elixir | lib/phoenix/endpoint/instrument.ex | angwoontiong/phoenix-ui | 03227b13f3c780b5626d56207bfa99c8a06525d8 | [
"MIT"
] | null | null | null | lib/phoenix/endpoint/instrument.ex | angwoontiong/phoenix-ui | 03227b13f3c780b5626d56207bfa99c8a06525d8 | [
"MIT"
] | null | null | null | lib/phoenix/endpoint/instrument.ex | angwoontiong/phoenix-ui | 03227b13f3c780b5626d56207bfa99c8a06525d8 | [
"MIT"
] | null | null | null | defmodule Phoenix.Endpoint.Instrument do
@moduledoc false
# This is the arity that event callbacks in the instrumenter modules must
# have.
@event_callback_arity 3
@doc false
def definstrument(otp_app, endpoint) do
app_instrumenters = app_instrumenters(otp_app, endpoint)
quote bind_quoted: [app_i... | 35.263889 | 111 | 0.635815 |
1cfcdcd3d57ebf4c951ed1e11fed1dcf2a1b04bf | 983 | ex | Elixir | Microsoft.Azure.Management.Resources/lib/microsoft/azure/management/resources/model/provider_resource_type.ex | chgeuer/ex_microsoft_azure_management | 99cd9f7f2ff1fdbe69ca5bac55b6e2af91ba3603 | [
"Apache-2.0"
] | 4 | 2018-09-29T03:43:15.000Z | 2021-04-01T18:30:46.000Z | Microsoft.Azure.Management.Resources/lib/microsoft/azure/management/resources/model/provider_resource_type.ex | chgeuer/ex_microsoft_azure_management | 99cd9f7f2ff1fdbe69ca5bac55b6e2af91ba3603 | [
"Apache-2.0"
] | null | null | null | Microsoft.Azure.Management.Resources/lib/microsoft/azure/management/resources/model/provider_resource_type.ex | chgeuer/ex_microsoft_azure_management | 99cd9f7f2ff1fdbe69ca5bac55b6e2af91ba3603 | [
"Apache-2.0"
] | null | null | null | # NOTE: This class is auto generated by the swagger code generator program.
# https://github.com/swagger-api/swagger-codegen.git
# Do not edit the class manually.
defmodule Microsoft.Azure.Management.Resources.Model.ProviderResourceType do
@moduledoc """
Resource type managed by the resource provider.
"""
@de... | 27.305556 | 100 | 0.695829 |
1cfd39f65c8e6460d7fe0292ff5b36939f7a07b9 | 1,487 | ex | Elixir | lib/ex_onixo/parser.ex | damjack/ex_onixo | 5b1f97bc65867dcf1710540264094d147722ee11 | [
"MIT"
] | 1 | 2021-12-11T06:44:18.000Z | 2021-12-11T06:44:18.000Z | lib/ex_onixo/parser.ex | damjack/ex_onixo | 5b1f97bc65867dcf1710540264094d147722ee11 | [
"MIT"
] | null | null | null | lib/ex_onixo/parser.ex | damjack/ex_onixo | 5b1f97bc65867dcf1710540264094d147722ee11 | [
"MIT"
] | null | null | null | defmodule ExOnixo.Parser do
import SweetXml
alias ExOnixo.Parser.{
Product,
Product21,
Sender,
Sender21
}
@moduledoc false
defdelegate raw_xml(xml_tree), to: ExOnixo.Raw
defp init_stream_parser(origin) do
init_stream(origin)
|> SweetXml.stream_tags([:Product], discard: [:Product])... | 27.036364 | 96 | 0.632145 |
1cfd3f2e11ddc6ed6a123debf55001f10d78669f | 1,547 | ex | Elixir | lib/linreg_web/endpoint.ex | Tmw/linreg | b4dd10006ec875da1250cd5d2d7d21b551ed15e5 | [
"MIT"
] | 9 | 2020-05-25T19:54:41.000Z | 2022-03-09T09:57:04.000Z | lib/linreg_web/endpoint.ex | Tmw/linreg | b4dd10006ec875da1250cd5d2d7d21b551ed15e5 | [
"MIT"
] | 2 | 2020-06-04T13:25:11.000Z | 2020-06-07T14:31:30.000Z | lib/linreg_web/endpoint.ex | Tmw/linreg | b4dd10006ec875da1250cd5d2d7d21b551ed15e5 | [
"MIT"
] | 2 | 2021-01-14T17:03:01.000Z | 2021-04-27T05:22:29.000Z | defmodule LinregWeb.Endpoint do
use Phoenix.Endpoint, otp_app: :linreg
# The session will be stored in the cookie and signed,
# this means its contents can be read but not tampered with.
# Set :encryption_salt if you would also like to encrypt it.
@session_options [
store: :cookie,
key: "_linreg_key"... | 28.648148 | 97 | 0.714932 |
1cfd4688565540338d9051f9b9cd8ec8fa96be13 | 1,647 | ex | Elixir | lib/yggdrasil/distributor/distributor.ex | jsangilve/yggdrasil | a2ee905e877b6a9d918d8858153a01aadf2d5d63 | [
"MIT"
] | null | null | null | lib/yggdrasil/distributor/distributor.ex | jsangilve/yggdrasil | a2ee905e877b6a9d918d8858153a01aadf2d5d63 | [
"MIT"
] | null | null | null | lib/yggdrasil/distributor/distributor.ex | jsangilve/yggdrasil | a2ee905e877b6a9d918d8858153a01aadf2d5d63 | [
"MIT"
] | null | null | null | defmodule Yggdrasil.Distributor do
@moduledoc """
Supervisor for `Yggdrasil.Distributor.Adapter` and
`Yggdrasil.Distributor.Publisher`.
"""
use Supervisor
alias Yggdrasil.Channel
alias Yggdrasil.Settings
@publisher Yggdrasil.Distributor.Publisher
@registry Settings.registry()
####################... | 25.338462 | 79 | 0.590771 |
1cfd497736e450d0e56e68a7f4b012f94418a9c3 | 954 | ex | Elixir | lib/phoenix/status.ex | brightroll/phoenix | b93022086322bcc1d797214a28e0c9710f537c22 | [
"MIT"
] | null | null | null | lib/phoenix/status.ex | brightroll/phoenix | b93022086322bcc1d797214a28e0c9710f537c22 | [
"MIT"
] | null | null | null | lib/phoenix/status.ex | brightroll/phoenix | b93022086322bcc1d797214a28e0c9710f537c22 | [
"MIT"
] | null | null | null | defmodule Phoenix.Status do
@moduledoc """
Conversion for transforming atoms to http status codes.
"""
defmodule InvalidStatus do
defexception [:message]
def exception(value) do
%InvalidStatus{message: "Invalid HTTP status #{inspect value}"}
end
end
for line <- File.stream!(Path.join([... | 23.268293 | 79 | 0.63522 |
1cfd5a7961a7924074ad8efb9523fe36d78991cd | 2,395 | ex | Elixir | lib/bongo/converter/out.ex | bombinatetech/typed_struct | dc07cb613e24fe9e6efffe1c36bed62eee764ee2 | [
"MIT"
] | 7 | 2019-01-31T04:45:11.000Z | 2020-02-22T15:37:51.000Z | lib/bongo/converter/out.ex | yatender-oktalk/bongo | bf68a4ffd67f850d6dd1c05fd3eb01f73d677812 | [
"MIT"
] | 1 | 2019-01-11T07:07:09.000Z | 2019-01-11T07:07:09.000Z | lib/bongo/converter/out.ex | yatender-oktalk/bongo | bf68a4ffd67f850d6dd1c05fd3eb01f73d677812 | [
"MIT"
] | 2 | 2019-01-31T04:45:16.000Z | 2019-10-25T18:42:46.000Z | defmodule Bongo.Converter.Out do
import Bongo.Utilities, only: [log_and_return: 2, debug_log: 2]
def convert_out(nil, _type, _lenient) do
nil
end
def convert_out(value, nil, _lenient) do
log_and_return(value, "This model contains an unknown field *out* type")
end
def convert_out(value, {:|, [], [... | 23.028846 | 76 | 0.616701 |
1cfd5ee99768112aca6e13ffc16657490b006d91 | 2,712 | exs | Elixir | template/$PROJECT_NAME$/config/prod.exs | infinitered/firebird | 679ca2f21eb0a5dc4bfc15c90f2c3c2abd2fe49b | [
"MIT"
] | 72 | 2017-04-30T05:45:22.000Z | 2021-05-20T21:00:31.000Z | template/$PROJECT_NAME$/config/prod.exs | infinitered/firebird | 679ca2f21eb0a5dc4bfc15c90f2c3c2abd2fe49b | [
"MIT"
] | 13 | 2017-04-30T07:03:59.000Z | 2017-12-15T08:19:16.000Z | template/$PROJECT_NAME$/config/prod.exs | infinitered/firebird | 679ca2f21eb0a5dc4bfc15c90f2c3c2abd2fe49b | [
"MIT"
] | 4 | 2017-09-05T14:21:29.000Z | 2018-09-30T11:11:38.000Z | use Mix.Config
# For production, we often load configuration from external
# sources, such as your system environment. For this reason,
# you won't find the :http configuration below, but set inside
# <%= @project_name_camel_case %>Web.Endpoint.load_from_system_env/1 dynamically.
# Any dynamic configuration should be ... | 36.16 | 93 | 0.70649 |
1cfd6b203a521072738711c6d76156f114419eec | 23,372 | ex | Elixir | lib/elixir/lib/access.ex | thomascchen/elixir | d19a92bbf4cb3743ce726a87e584a1741b59f5b0 | [
"Apache-2.0"
] | null | null | null | lib/elixir/lib/access.ex | thomascchen/elixir | d19a92bbf4cb3743ce726a87e584a1741b59f5b0 | [
"Apache-2.0"
] | null | null | null | lib/elixir/lib/access.ex | thomascchen/elixir | d19a92bbf4cb3743ce726a87e584a1741b59f5b0 | [
"Apache-2.0"
] | null | null | null | defmodule Access do
@moduledoc """
Key-based access to data structures using the `data[key]` syntax.
Elixir provides two syntaxes for accessing values. `user[:name]`
is used by dynamic structures, like maps and keywords, while
`user.name` is used by structs. The main difference is that
`user[:name]` won't ... | 33.198864 | 114 | 0.634349 |
1cfd743457a7add2f8d2a073b78227300267ab51 | 331 | exs | Elixir | mix.exs | KallDrexx/elixir-media-libs | 5115c390133696a01c1b24107fa1f51eca9ce7b4 | [
"MIT"
] | 75 | 2016-12-23T14:37:18.000Z | 2021-04-26T14:07:20.000Z | mix.exs | KallDrexx/elixir-media-libs | 5115c390133696a01c1b24107fa1f51eca9ce7b4 | [
"MIT"
] | 19 | 2016-12-22T03:20:43.000Z | 2020-06-11T12:10:37.000Z | mix.exs | KallDrexx/elixir-media-libs | 5115c390133696a01c1b24107fa1f51eca9ce7b4 | [
"MIT"
] | 3 | 2018-03-29T06:40:40.000Z | 2019-02-13T09:37:19.000Z | defmodule ElixirMediaLibs.Mixfile do
use Mix.Project
def project do
[apps_path: "apps",
build_embedded: Mix.env == :prod,
start_permanent: Mix.env == :prod,
deps: deps(),
dialyzer: [plt_add_deps: :transitive]
]
end
defp deps do
[{:dialyxir, "~> 0.4.3", only: [:dev, :umbrella]}]... | 19.470588 | 54 | 0.613293 |
1cfd9ac24633a24518c6ddded146c06685cfacfe | 1,308 | exs | Elixir | config/prod.secret.exs | PanyPy/foundation_phoenix | 571aaa0b274c1428b4cf8e370777ae82c9167eb2 | [
"MIT"
] | null | null | null | config/prod.secret.exs | PanyPy/foundation_phoenix | 571aaa0b274c1428b4cf8e370777ae82c9167eb2 | [
"MIT"
] | 2 | 2021-03-10T11:28:36.000Z | 2021-05-11T07:00:39.000Z | config/prod.secret.exs | PanyPy/foundation_phoenix | 571aaa0b274c1428b4cf8e370777ae82c9167eb2 | [
"MIT"
] | null | null | null | # In this file, we load production configuration and secrets
# from environment variables. You can also hardcode secrets,
# although such is generally not recommended and you have to
# remember to add this file to your .gitignore.
use Mix.Config
database_url =
System.get_env("DATABASE_URL") ||
raise """
envi... | 31.142857 | 77 | 0.732416 |
1cfdb971b05b8291d4ba90926800199a8b4bb296 | 693 | ex | Elixir | builds/installs/Debian/cards-500/debian/preinst.ex | bob-weber/cardGame-500 | 007ad6e1ad30f6e24ba3c5c29cfc16d42c0a9a51 | [
"Beerware"
] | null | null | null | builds/installs/Debian/cards-500/debian/preinst.ex | bob-weber/cardGame-500 | 007ad6e1ad30f6e24ba3c5c29cfc16d42c0a9a51 | [
"Beerware"
] | null | null | null | builds/installs/Debian/cards-500/debian/preinst.ex | bob-weber/cardGame-500 | 007ad6e1ad30f6e24ba3c5c29cfc16d42c0a9a51 | [
"Beerware"
] | null | null | null | #!/bin/sh
# preinst script for cards-500
#
# see: dh_installdeb(1)
set -e
# summary of how this script can be called:
# * <new-preinst> `install'
# * <new-preinst> `install' <old-version>
# * <new-preinst> `upgrade' <old-version>
# * <old-preinst> `abort-upgrade' <new-version>
# for detail... | 19.25 | 63 | 0.627706 |
1cfe0e755b6121f14ba037f89206a90f89f1da9e | 456 | exs | Elixir | config/prod.secret.exs | brianstorti/jan | e3e7172c672705b7d4e3912e16d5a69496a79e4a | [
"Apache-2.0"
] | 54 | 2016-02-07T21:44:14.000Z | 2022-01-06T04:10:59.000Z | config/prod.secret.exs | brianstorti/jan | e3e7172c672705b7d4e3912e16d5a69496a79e4a | [
"Apache-2.0"
] | 1 | 2016-02-13T15:52:55.000Z | 2016-02-13T15:52:55.000Z | config/prod.secret.exs | brianstorti/jan | e3e7172c672705b7d4e3912e16d5a69496a79e4a | [
"Apache-2.0"
] | 4 | 2016-02-13T11:54:00.000Z | 2022-01-06T04:19:26.000Z | use Mix.Config
# In this file, we keep production configuration that
# you likely want to automate and keep it away from
# your version control system.
config :jan, Jan.Endpoint,
secret_key_base: System.get_env("SECRET_KEY_BASE")
# Configure your database
config :jan, Jan.Repo,
adapter: Ecto.Adapters.Postgres,
... | 28.5 | 53 | 0.765351 |
1cfe786544fbca6a6ce419d8316405b34ac00c6b | 1,630 | ex | Elixir | elixir/epi_book/lib/chapter_8/max_stack.ex | wtfleming/data-structures-and-algorithms | f3d55b6642ee0219606c65ac6f1f8c5b402bdf70 | [
"MIT"
] | null | null | null | elixir/epi_book/lib/chapter_8/max_stack.ex | wtfleming/data-structures-and-algorithms | f3d55b6642ee0219606c65ac6f1f8c5b402bdf70 | [
"MIT"
] | null | null | null | elixir/epi_book/lib/chapter_8/max_stack.ex | wtfleming/data-structures-and-algorithms | f3d55b6642ee0219606c65ac6f1f8c5b402bdf70 | [
"MIT"
] | null | null | null | defmodule Chapter8.MaxStack do
defstruct head: []
@type t :: %Chapter8.MaxStack{head: [{integer, integer}]}
@moduledoc """
Stack that supports max() as an O(1) operation to determine the largest element on the stack
"""
@doc """
Construct an empty MaxStack
"""
@spec new() :: Chapter8.MaxStack.t
de... | 22.027027 | 94 | 0.598773 |
1cfe9734d17c2b0f8abf9be282a33b044a981de8 | 1,639 | ex | Elixir | clients/docs/lib/google_api/docs/v1/model/tab_stop.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/docs/lib/google_api/docs/v1/model/tab_stop.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | 1 | 2020-12-18T09:25:12.000Z | 2020-12-18T09:25:12.000Z | clients/docs/lib/google_api/docs/v1/model/tab_stop.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... | 32.78 | 137 | 0.718121 |
1cfea1a263f360bf215e9485a4dc61972fc75e76 | 378 | ex | Elixir | 9-elixir-phoenix/web/router.ex | smddzcy/learning-new-technologies | cf3645ff649f6dfe89c77e90ceaf089b66da2482 | [
"MIT"
] | 3 | 2017-02-22T08:45:53.000Z | 2017-04-29T13:40:23.000Z | 9-elixir-phoenix/web/router.ex | smddzcy/learning-new-technologies | cf3645ff649f6dfe89c77e90ceaf089b66da2482 | [
"MIT"
] | null | null | null | 9-elixir-phoenix/web/router.ex | smddzcy/learning-new-technologies | cf3645ff649f6dfe89c77e90ceaf089b66da2482 | [
"MIT"
] | null | null | null | defmodule AwesomeprojectBackend.Router do
use AwesomeprojectBackend.Web, :router
pipeline :api do
plug :accepts, ["json"]
end
scope "/", AwesomeprojectBackend do
pipe_through :api # Use the api
resources "/posts", PostController
end
# Other scopes may use custom stacks.
# scope "/api", Awe... | 19.894737 | 42 | 0.703704 |
1cfeab1000ebf9b91d32513dd4918479f895f9f8 | 1,556 | ex | Elixir | clients/dataflow/lib/google_api/dataflow/v1b3/model/list_snapshots_response.ex | matehat/elixir-google-api | c1b2523c2c4cdc9e6ca4653ac078c94796b393c3 | [
"Apache-2.0"
] | 1 | 2018-12-03T23:43:10.000Z | 2018-12-03T23:43:10.000Z | clients/dataflow/lib/google_api/dataflow/v1b3/model/list_snapshots_response.ex | matehat/elixir-google-api | c1b2523c2c4cdc9e6ca4653ac078c94796b393c3 | [
"Apache-2.0"
] | null | null | null | clients/dataflow/lib/google_api/dataflow/v1b3/model/list_snapshots_response.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 ... | 33.106383 | 116 | 0.747429 |
1cfec2ceb8063849c7d99a8e7913468f61f0c797 | 1,812 | ex | Elixir | web/controllers/page_controller.ex | jabaraster/elixir_wiki | e8197a1f48c4ebfdbb209e74b01e76abb6d9fe68 | [
"MIT"
] | null | null | null | web/controllers/page_controller.ex | jabaraster/elixir_wiki | e8197a1f48c4ebfdbb209e74b01e76abb6d9fe68 | [
"MIT"
] | null | null | null | web/controllers/page_controller.ex | jabaraster/elixir_wiki | e8197a1f48c4ebfdbb209e74b01e76abb6d9fe68 | [
"MIT"
] | null | null | null | defmodule Wiki.PageController do
use Wiki.Web, :controller
alias Wiki.Page
plug :scrub_params, "page" when action in [:create, :update]
def index(conn, _params) do
pages = Repo.all(Page)
render(conn, "index.html", pages: pages)
end
def new(conn, _params) do
changeset = Page.changeset(%Page{}... | 26.647059 | 67 | 0.610375 |
1cfec711c7cb5b8a740ef8a06051f2f9faca0bf3 | 229 | ex | Elixir | lib/operators/type_error.ex | carmaproject/towel | 471953af77efa675beaa5055e24e7ae645d565c8 | [
"MIT"
] | 3 | 2018-01-03T12:28:22.000Z | 2021-02-04T14:17:48.000Z | lib/operators/type_error.ex | carmaproject/towel | 471953af77efa675beaa5055e24e7ae645d565c8 | [
"MIT"
] | 4 | 2017-09-27T09:04:07.000Z | 2021-10-16T14:37:52.000Z | lib/operators/type_error.ex | carmaproject/towel | 471953af77efa675beaa5055e24e7ae645d565c8 | [
"MIT"
] | 3 | 2017-10-03T00:11:34.000Z | 2021-01-10T23:33:19.000Z | defmodule Result.TypeError do
defexception [:message]
@impl true
def exception(value) do
msg = "is not in {:ok, value} or {:error, error} format, instead got: #{inspect(value)}"
%__MODULE__{message: msg}
end
end
| 22.9 | 92 | 0.676856 |
1cfefe487596c179737ec62562f366279fcc5d1e | 1,276 | exs | Elixir | test/web/plugs/burger_create_plug_test.exs | mbuhot/irateburgers | 3ea07805501c10ef9b04cee04c22c36582f26e1e | [
"MIT"
] | 1 | 2020-01-13T09:27:21.000Z | 2020-01-13T09:27:21.000Z | test/web/plugs/burger_create_plug_test.exs | mbuhot/irateburgers | 3ea07805501c10ef9b04cee04c22c36582f26e1e | [
"MIT"
] | null | null | null | test/web/plugs/burger_create_plug_test.exs | mbuhot/irateburgers | 3ea07805501c10ef9b04cee04c22c36582f26e1e | [
"MIT"
] | null | null | null | defmodule Irateburgers.Web.BurgerCreatePlugTest do
use Irateburgers.Web.ConnCase
alias Plug.Conn
def big_mac_params do
%{
name: "Big Mac",
price: "$6.50",
description: "Beef, Cheese, Lettuce, Pickles, Special Sauce",
images: ["http://imgur.com/foo/bar"]
}
end
describe "Creati... | 25.52 | 77 | 0.548589 |
1cff0328f0c28e8252a087b092dc4c79d7cbacc5 | 591 | exs | Elixir | elixir/prime-factors/prime_factors.exs | macborowy/exercism | c5d45e074e81b946a82a340b2730e0d2732b7e0a | [
"MIT"
] | null | null | null | elixir/prime-factors/prime_factors.exs | macborowy/exercism | c5d45e074e81b946a82a340b2730e0d2732b7e0a | [
"MIT"
] | null | null | null | elixir/prime-factors/prime_factors.exs | macborowy/exercism | c5d45e074e81b946a82a340b2730e0d2732b7e0a | [
"MIT"
] | null | null | null | defmodule PrimeFactors do
@doc """
Compute the prime factors for 'number'.
The prime factors are prime numbers that when multiplied give the desired
number.
The prime factors of 'number' will be ordered lowest to highest.
"""
@spec factors_for(pos_integer) :: [pos_integer]
def factors_for(number), do:... | 29.55 | 75 | 0.681895 |
1cff04dec32ba9f4e0ced573413bcc0f56749e0f | 2,010 | exs | Elixir | implementations/elixir/ockam/ockam_hub/mix.exs | illaz/ockam | d1073799a140f5f7e3312ea2d5d8b86b4e94154c | [
"Apache-2.0"
] | null | null | null | implementations/elixir/ockam/ockam_hub/mix.exs | illaz/ockam | d1073799a140f5f7e3312ea2d5d8b86b4e94154c | [
"Apache-2.0"
] | null | null | null | implementations/elixir/ockam/ockam_hub/mix.exs | illaz/ockam | d1073799a140f5f7e3312ea2d5d8b86b4e94154c | [
"Apache-2.0"
] | null | null | null | defmodule Ockam.Hub.MixProject do
use Mix.Project
@version "0.10.0-dev"
@elixir_requirement "~> 1.10"
@ockam_github_repo "https://github.com/ockam-network/ockam"
@ockam_github_repo_path "implementations/elixir/ockam/ockam_hub"
def project do
[
app: :ockam_hub,
version: @version,
el... | 23.647059 | 93 | 0.5801 |
1cff3dc6ac71be42730349f0d7e7bd112e004467 | 290 | ex | Elixir | lib/Database.ex | ArchaicArhcon/elmud | 85730e0dc4da80826c943c0229dd621801ce5a4c | [
"BSD-2-Clause"
] | 1 | 2015-09-12T00:43:20.000Z | 2015-09-12T00:43:20.000Z | lib/Database.ex | ArchaicArhcon/elmud | 85730e0dc4da80826c943c0229dd621801ce5a4c | [
"BSD-2-Clause"
] | null | null | null | lib/Database.ex | ArchaicArhcon/elmud | 85730e0dc4da80826c943c0229dd621801ce5a4c | [
"BSD-2-Clause"
] | 1 | 2017-11-19T13:36:48.000Z | 2017-11-19T13:36:48.000Z | require Amnesia
use Amnesia
defdatabase Database do
deftable Item, [:key, :value], type: :ordered_set do
@type t :: %Item{key: String.t, value: String.t}
end
deftable Color, [:name, :color], type: :ordered_set do
@type t :: %Color{name: String.t, color: String.t}
end
end
| 22.307692 | 56 | 0.668966 |
1cff485a3a3d27f0c51ca4608268f0259188b073 | 2,402 | ex | Elixir | clients/you_tube/lib/google_api/you_tube/v3/model/live_chat_message.ex | leandrocp/elixir-google-api | a86e46907f396d40aeff8668c3bd81662f44c71e | [
"Apache-2.0"
] | null | null | null | clients/you_tube/lib/google_api/you_tube/v3/model/live_chat_message.ex | leandrocp/elixir-google-api | a86e46907f396d40aeff8668c3bd81662f44c71e | [
"Apache-2.0"
] | null | null | null | clients/you_tube/lib/google_api/you_tube/v3/model/live_chat_message.ex | leandrocp/elixir-google-api | a86e46907f396d40aeff8668c3bd81662f44c71e | [
"Apache-2.0"
] | 1 | 2020-11-10T16:58:27.000Z | 2020-11-10T16:58:27.000Z | # Copyright 2017 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in... | 40.033333 | 159 | 0.738551 |
1cff749f4413c9f3c892ee652eb24ae426564d44 | 6,524 | ex | Elixir | lib/oban/config.ex | superhawk610/oban | 9e87ca0e45451efee05db1d430739d348c67acdb | [
"Apache-2.0"
] | null | null | null | lib/oban/config.ex | superhawk610/oban | 9e87ca0e45451efee05db1d430739d348c67acdb | [
"Apache-2.0"
] | null | null | null | lib/oban/config.ex | superhawk610/oban | 9e87ca0e45451efee05db1d430739d348c67acdb | [
"Apache-2.0"
] | null | null | null | defmodule Oban.Config do
@moduledoc false
alias Oban.Crontab.Cron
use Agent
@type cronjob :: {Cron.t(), module(), Keyword.t()}
@type t :: %__MODULE__{
circuit_backoff: timeout(),
crontab: [cronjob()],
dispatch_cooldown: pos_integer(),
name: atom(),
node: b... | 28.365217 | 91 | 0.624617 |
1cff84215820e90bf80cf78cba1704b62f27b216 | 4,678 | exs | Elixir | test/phoenix/tracker/pool_test.exs | grindrlabs/phoenix_pubsub | 27a9113dfa8a2e125ae74cfff36e6a322c8b97f4 | [
"MIT"
] | 3 | 2020-06-08T03:47:03.000Z | 2021-09-17T21:48:37.000Z | test/phoenix/tracker/pool_test.exs | grindrlabs/phoenix_pubsub | 27a9113dfa8a2e125ae74cfff36e6a322c8b97f4 | [
"MIT"
] | null | null | null | test/phoenix/tracker/pool_test.exs | grindrlabs/phoenix_pubsub | 27a9113dfa8a2e125ae74cfff36e6a322c8b97f4 | [
"MIT"
] | null | null | null | defmodule Phoenix.Tracker.PoolTest do
use Phoenix.PubSub.NodeCase
alias Phoenix.Tracker
setup config do
server = config.test
{:ok, _pid} = start_pool(name: server, pool_size: config.pool_size)
{:ok, server: server}
end
for n <- [1,2,8,512] do
@tag pool_size: n
test "pool #{n}: A track/5... | 31.395973 | 81 | 0.543395 |
1cffa24b68772cf5db1b3c28ecd60ee618bed5bf | 1,924 | ex | Elixir | clients/sheets/lib/google_api/sheets/v4/model/update_sheet_properties_request.ex | matehat/elixir-google-api | c1b2523c2c4cdc9e6ca4653ac078c94796b393c3 | [
"Apache-2.0"
] | 1 | 2018-12-03T23:43:10.000Z | 2018-12-03T23:43:10.000Z | clients/sheets/lib/google_api/sheets/v4/model/update_sheet_properties_request.ex | matehat/elixir-google-api | c1b2523c2c4cdc9e6ca4653ac078c94796b393c3 | [
"Apache-2.0"
] | null | null | null | clients/sheets/lib/google_api/sheets/v4/model/update_sheet_properties_request.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 ... | 36.301887 | 129 | 0.735447 |
1cffb4241ffc984682762a32b26dfa2763699f52 | 1,074 | exs | Elixir | exercises/grains/grains_test.exs | martinsvalin/xelixir | 9469d92e7eecb528a05a8da923d8271ed303c058 | [
"MIT"
] | null | null | null | exercises/grains/grains_test.exs | martinsvalin/xelixir | 9469d92e7eecb528a05a8da923d8271ed303c058 | [
"MIT"
] | null | null | null | exercises/grains/grains_test.exs | martinsvalin/xelixir | 9469d92e7eecb528a05a8da923d8271ed303c058 | [
"MIT"
] | null | null | null | if !System.get_env("EXERCISM_TEST_EXAMPLES") do
Code.load_file("grains.exs")
end
ExUnit.start
ExUnit.configure exclude: :pending, trace: true
# NOTE: :math.pow/2 doesn't do what you'd expect:
# `:math.pow(2, 64) == :math.pow(2, 64) - 1` is true.
#
# It's best to avoid functions operating on floating point numbers f... | 18.842105 | 75 | 0.66108 |
1cffbc3068495dceb32d568d4d16566ae462e5cb | 1,977 | ex | Elixir | clients/street_view_publish/lib/google_api/street_view_publish/v1/model/photo_response.ex | matehat/elixir-google-api | c1b2523c2c4cdc9e6ca4653ac078c94796b393c3 | [
"Apache-2.0"
] | 1 | 2018-12-03T23:43:10.000Z | 2018-12-03T23:43:10.000Z | clients/street_view_publish/lib/google_api/street_view_publish/v1/model/photo_response.ex | matehat/elixir-google-api | c1b2523c2c4cdc9e6ca4653ac078c94796b393c3 | [
"Apache-2.0"
] | null | null | null | clients/street_view_publish/lib/google_api/street_view_publish/v1/model/photo_response.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 ... | 34.684211 | 166 | 0.741528 |
1cffcc46f53e181fcbfeec12fca7e0da4e3f4a28 | 1,464 | exs | Elixir | test/fixtures/umbrella_app/rel/config.exs | arikai/distillery | 65ddbcc143f2849a6ed5574e8c397a68ca92eb81 | [
"MIT"
] | 3,097 | 2016-07-18T13:59:00.000Z | 2022-03-29T00:27:23.000Z | test/fixtures/umbrella_app/rel/config.exs | arikai/distillery | 65ddbcc143f2849a6ed5574e8c397a68ca92eb81 | [
"MIT"
] | 672 | 2016-07-18T18:25:29.000Z | 2022-02-24T17:39:30.000Z | test/fixtures/umbrella_app/rel/config.exs | arikai/distillery | 65ddbcc143f2849a6ed5574e8c397a68ca92eb81 | [
"MIT"
] | 483 | 2016-07-22T14:08:49.000Z | 2022-03-21T09:35:23.000Z | # Import all plugins from `rel/plugins`
# They can then be used by adding `plugin MyPlugin` to
# either an environment, or release definition, where
# `MyPlugin` is the name of the plugin module.
~w(rel plugins *.exs)
|> Path.join()
|> Path.wildcard()
|> Enum.map(&Code.eval_file(&1))
use Distillery.Releases.Config,
... | 28.153846 | 89 | 0.705601 |
1cffe0079da226378ab4e70d7675bde69338724d | 938 | exs | Elixir | test/credo/check/readability/module_names_test.exs | kanmaniselvan/credo | 276e0fc24d1bf56c8fc2902a9e933c8f208ce391 | [
"MIT"
] | 1 | 2021-12-01T13:37:43.000Z | 2021-12-01T13:37:43.000Z | test/credo/check/readability/module_names_test.exs | kanmaniselvan/credo | 276e0fc24d1bf56c8fc2902a9e933c8f208ce391 | [
"MIT"
] | null | null | null | test/credo/check/readability/module_names_test.exs | kanmaniselvan/credo | 276e0fc24d1bf56c8fc2902a9e933c8f208ce391 | [
"MIT"
] | 1 | 2019-10-08T16:42:40.000Z | 2019-10-08T16:42:40.000Z | defmodule Credo.Check.Readability.ModuleNamesTest do
use Credo.Test.Case
@described_check Credo.Check.Readability.ModuleNames
#
# cases NOT raising issues
#
test "it should NOT report expected code" do
"""
defmodule CredoSampleModule do
end
"""
|> to_source_file
|> run_check(@desc... | 19.142857 | 70 | 0.639659 |
1cffe05f773aa1b89b4a10ac404d8d88477f4702 | 2,435 | ex | Elixir | lib/songmate_web/controllers/page_controller.ex | jimytc/music-dating-app | ec46ef2ffa4fb263a8b283a96495b0643467697c | [
"MIT"
] | null | null | null | lib/songmate_web/controllers/page_controller.ex | jimytc/music-dating-app | ec46ef2ffa4fb263a8b283a96495b0643467697c | [
"MIT"
] | null | null | null | lib/songmate_web/controllers/page_controller.ex | jimytc/music-dating-app | ec46ef2ffa4fb263a8b283a96495b0643467697c | [
"MIT"
] | null | null | null | defmodule SongmateWeb.PageController do
use SongmateWeb, :controller
alias Songmate.Repo
alias Songmate.Accounts
alias Songmate.MusicProfile
plug :check_tokens
def check_tokens(conn, _params) do
if Spotify.Authentication.tokens_present?(conn) do
{:ok, conn} = Spotify.Authentication.refresh(conn)... | 26.182796 | 120 | 0.595483 |
e800009b80634f7ac769e1e4ec5f6956e7118c42 | 244 | ex | Elixir | lib/gps/last_known_location.ex | JesseHerrick/phoenix_liveview_gps | 711b0cd3eb7277e12be3bac26aa950914c4cf8e7 | [
"MIT"
] | 1 | 2021-03-28T08:22:40.000Z | 2021-03-28T08:22:40.000Z | lib/gps/last_known_location.ex | JesseHerrick/phoenix_liveview_gps | 711b0cd3eb7277e12be3bac26aa950914c4cf8e7 | [
"MIT"
] | null | null | null | lib/gps/last_known_location.ex | JesseHerrick/phoenix_liveview_gps | 711b0cd3eb7277e12be3bac26aa950914c4cf8e7 | [
"MIT"
] | 1 | 2021-01-15T12:40:12.000Z | 2021-01-15T12:40:12.000Z | defmodule Gps.LastKnownLocation do
use GenServer
def start_link(_) do
GenServer.start_link(__MODULE__, [])
end
@impl true
def init(_) do
:ets.new(:last_known_location, [:set, :public, :named_table])
{:ok, []}
end
end
| 16.266667 | 65 | 0.663934 |
e8002785ce759d88a179a41f35cdf2d7b9a33653 | 366 | exs | Elixir | config/dev.secret.example.exs | savekirk/elixir_jobs | d7ec0f088a1365f3ae5cbbd6c07c2b3fdde9a946 | [
"MIT"
] | null | null | null | config/dev.secret.example.exs | savekirk/elixir_jobs | d7ec0f088a1365f3ae5cbbd6c07c2b3fdde9a946 | [
"MIT"
] | null | null | null | config/dev.secret.example.exs | savekirk/elixir_jobs | d7ec0f088a1365f3ae5cbbd6c07c2b3fdde9a946 | [
"MIT"
] | null | null | null | use Mix.Config
# Configure your database
config :elixir_jobs, ElixirJobs.Repo,
adapter: Ecto.Adapters.Postgres,
username: "DB_USERNAME",
password: "DB_PASSWORD",
database: "elixir_jobs_dev",
hostname: "localhost",
pool_size: 10
config :extwitter, :oauth, [
consumer_key: "",
consumer_secret: "",
a... | 20.333333 | 37 | 0.704918 |
e800423ccd4d23ee7648156d38d4343d88088feb | 62,550 | ex | Elixir | clients/secret_manager/lib/google_api/secret_manager/v1/api/projects.ex | yoshi-code-bot/elixir-google-api | cdb6032f01fac5ab704803113c39f2207e9e019d | [
"Apache-2.0"
] | null | null | null | clients/secret_manager/lib/google_api/secret_manager/v1/api/projects.ex | yoshi-code-bot/elixir-google-api | cdb6032f01fac5ab704803113c39f2207e9e019d | [
"Apache-2.0"
] | null | null | null | clients/secret_manager/lib/google_api/secret_manager/v1/api/projects.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... | 46.299038 | 802 | 0.615316 |
e8005b4ba7d492aee12cbaccbb471d05519a5536 | 1,054 | exs | Elixir | test/time_zone_info/downloader_test.exs | hrzndhrn/time_zone_info | 18fa4e7aefd68d256202de8e0f96b69b8a9dc618 | [
"MIT"
] | 5 | 2020-04-05T16:03:03.000Z | 2022-02-07T22:11:04.000Z | test/time_zone_info/downloader_test.exs | hrzndhrn/time_zone_info | 18fa4e7aefd68d256202de8e0f96b69b8a9dc618 | [
"MIT"
] | 16 | 2020-03-28T17:46:13.000Z | 2021-08-25T08:35:48.000Z | test/time_zone_info/downloader_test.exs | hrzndhrn/time_zone_info | 18fa4e7aefd68d256202de8e0f96b69b8a9dc618 | [
"MIT"
] | null | null | null | defmodule TimeZoneInfo.DownloaderTest do
use ExUnit.Case
import Mox
import TimeZoneInfo.TestUtils
alias TimeZoneInfo.{Downloader, DownloaderMock}
setup do
on_exit(&delete_env/0)
end
setup :verify_on_exit!
test "download/1" do
env =
put_env(
downloader: [
module: Down... | 22.425532 | 78 | 0.580645 |
e80082ae930d2bfe572e1becd1c73f7377e29776 | 637 | ex | Elixir | lib/docusign/model/envelope_attachments_result.ex | gaslight/docusign_elixir | d9d88d53dd85d32a39d537bade9db28d779414e6 | [
"MIT"
] | 4 | 2020-12-21T12:50:13.000Z | 2022-01-12T16:50:43.000Z | lib/docusign/model/envelope_attachments_result.ex | gaslight/docusign_elixir | d9d88d53dd85d32a39d537bade9db28d779414e6 | [
"MIT"
] | 12 | 2018-09-18T15:26:34.000Z | 2019-09-28T15:29:39.000Z | lib/docusign/model/envelope_attachments_result.ex | gaslight/docusign_elixir | d9d88d53dd85d32a39d537bade9db28d779414e6 | [
"MIT"
] | 15 | 2020-04-29T21:50:16.000Z | 2022-02-11T18:01:51.000Z | # NOTE: This class is auto generated by the swagger code generator program.
# https://github.com/swagger-api/swagger-codegen.git
# Do not edit the class manually.
defmodule DocuSign.Model.EnvelopeAttachmentsResult do
@moduledoc """
"""
@derive [Poison.Encoder]
defstruct [
:attachments
]
@type t :: %... | 22.75 | 84 | 0.720565 |
e8008e2165c7db2a40f6c5acb57f71af9b3e1f59 | 8,122 | ex | Elixir | lib/nerves_time/ntpd.ex | LostKobrakai/nerves_time | c7e49f436c40a571d9213e5c19f41ee1b71062cf | [
"Apache-2.0"
] | 17 | 2018-08-12T03:50:39.000Z | 2020-01-05T06:47:04.000Z | lib/nerves_time/ntpd.ex | LostKobrakai/nerves_time | c7e49f436c40a571d9213e5c19f41ee1b71062cf | [
"Apache-2.0"
] | 38 | 2018-08-12T12:07:46.000Z | 2020-02-11T10:11:48.000Z | lib/nerves_time/ntpd.ex | LostKobrakai/nerves_time | c7e49f436c40a571d9213e5c19f41ee1b71062cf | [
"Apache-2.0"
] | 6 | 2018-08-12T03:52:35.000Z | 2019-10-28T21:19:39.000Z | defmodule NervesTime.Ntpd do
use GenServer
require Logger
@moduledoc false
# If restarting ntpd due to a crash, delay its start to avoid pegging
# ntp servers. This delay can be long since the clock has either been
# set (i.e., it's not far off from the actual time) or there is a problem
# setting the t... | 28.903915 | 100 | 0.667939 |
e800c23d49aedaa810e7afdd2e493cb4af0fcf1d | 41,272 | ex | Elixir | lib/ecto/query/builder.ex | revati/ecto | 75b4c4179724af8ae2582aa8adae21eeb111ec78 | [
"Apache-2.0"
] | null | null | null | lib/ecto/query/builder.ex | revati/ecto | 75b4c4179724af8ae2582aa8adae21eeb111ec78 | [
"Apache-2.0"
] | null | null | null | lib/ecto/query/builder.ex | revati/ecto | 75b4c4179724af8ae2582aa8adae21eeb111ec78 | [
"Apache-2.0"
] | null | null | null | defmodule Ecto.Query.Builder do
@moduledoc false
alias Ecto.Query
@comparisons [
is_nil: 1,
==: 2,
!=: 2,
<: 2,
>: 2,
<=: 2,
>=: 2
]
@dynamic_aggregates [
max: 1,
min: 1,
first_value: 1,
last_value: 1,
nth_value: 2,
lag: 3,
lead: 3,
lag: 2,
le... | 34.946655 | 117 | 0.627496 |
e800fbd6829f7763665d80a35cad4a7d007fa1a7 | 2,127 | exs | Elixir | test/controllers/task_controller_test.exs | wsmoak/my_app_802337 | a863bdd16c909b12a598bf06b8901e1c8c0d3f7c | [
"MIT"
] | null | null | null | test/controllers/task_controller_test.exs | wsmoak/my_app_802337 | a863bdd16c909b12a598bf06b8901e1c8c0d3f7c | [
"MIT"
] | null | null | null | test/controllers/task_controller_test.exs | wsmoak/my_app_802337 | a863bdd16c909b12a598bf06b8901e1c8c0d3f7c | [
"MIT"
] | null | null | null | defmodule MyApp_802337.TaskControllerTest do
use MyApp_802337.ConnCase
alias MyApp_802337.Task
@valid_attrs %{due_at: %{day: 17, hour: 14, min: 0, month: 4, year: 2010}, title: "some content"}
@invalid_attrs %{}
setup do
conn = conn() |> put_req_header("accept", "application/json")
{:ok, conn: conn}... | 33.761905 | 99 | 0.661965 |
e800fc2fdaf793f419fdaebaf7808bc6ce42e0a3 | 4,018 | exs | Elixir | test/mustache_feature_test.exs | newaperio/Mustache.ex | a1314b202c59ab7c3c48113431a982fbee6fe50c | [
"MIT"
] | null | null | null | test/mustache_feature_test.exs | newaperio/Mustache.ex | a1314b202c59ab7c3c48113431a982fbee6fe50c | [
"MIT"
] | null | null | null | test/mustache_feature_test.exs | newaperio/Mustache.ex | a1314b202c59ab7c3c48113431a982fbee6fe50c | [
"MIT"
] | null | null | null | defmodule MustacheFeatureTest do
use ExUnit.Case
test "No Interpolation" do
assert Mustache.render("Hello from {Mustache}!\n") == "Hello from {Mustache}!\n"
end
test "Basic Interpolation" do
assert Mustache.render("Hello, {{subject}}!\n", %{subject: "world"}) == "Hello, world!\n"
end
test "HTML ... | 34.637931 | 183 | 0.582379 |
e80111c8155ddce52802927f2cb866af4403c932 | 10,608 | ex | Elixir | lib/ecto/migration/runner.ex | arcz/ecto_sql | 22ecbe3782af32f50c36387c861db77041247de8 | [
"Apache-2.0"
] | null | null | null | lib/ecto/migration/runner.ex | arcz/ecto_sql | 22ecbe3782af32f50c36387c861db77041247de8 | [
"Apache-2.0"
] | null | null | null | lib/ecto/migration/runner.ex | arcz/ecto_sql | 22ecbe3782af32f50c36387c861db77041247de8 | [
"Apache-2.0"
] | null | null | null | defmodule Ecto.Migration.Runner do
# A GenServer responsible for running migrations
# in either `:forward` or `:backward` directions.
@moduledoc false
require Logger
alias Ecto.Migration.Table
alias Ecto.Migration.Index
alias Ecto.Migration.Constraint
alias Ecto.Migration.Command
@doc """
Runs th... | 32.440367 | 129 | 0.65083 |
e80125279f2af7326205c6f7df7be5d0e4f60771 | 1,317 | ex | Elixir | test/helper/check_case.ex | acac99/credo-module-function-order-rule | a60a8641e682dde1517bc38df37c91bb23359b2b | [
"MIT"
] | 1 | 2019-09-19T10:29:24.000Z | 2019-09-19T10:29:24.000Z | test/helper/check_case.ex | acac99/credo-module-function-ordering | a60a8641e682dde1517bc38df37c91bb23359b2b | [
"MIT"
] | null | null | null | test/helper/check_case.ex | acac99/credo-module-function-ordering | a60a8641e682dde1517bc38df37c91bb23359b2b | [
"MIT"
] | null | null | null | defmodule Test.Helper.CredoModuleFunctionOrdering.CheckCase do
import ExUnit.Assertions
alias Credo.Execution
alias Credo.SourceFile
def refute_issues(source_file, check, params \\ []) do
issues = issues_for(source_file, check, create_config(), params)
assert [] == issues,
"There should be ... | 27.4375 | 93 | 0.678815 |
e80133696d096413fe76a5785a9069adbf6eaa0a | 128 | ex | Elixir | debian/cron.d.ex | winjer/squeal | 20401986e0d1698776f5b482b28e14c57b11833c | [
"Apache-2.0"
] | 2 | 2015-01-30T10:22:12.000Z | 2015-11-05T15:37:23.000Z | debian/cron.d.ex | winjer/squeal | 20401986e0d1698776f5b482b28e14c57b11833c | [
"Apache-2.0"
] | null | null | null | debian/cron.d.ex | winjer/squeal | 20401986e0d1698776f5b482b28e14c57b11833c | [
"Apache-2.0"
] | null | null | null | #
# Regular cron jobs for the squeal package
#
0 4 * * * root [ -x /usr/bin/squeal_maintenance ] && /usr/bin/squeal_maintenance
| 25.6 | 80 | 0.695313 |
e8018aa0020fddf5f164508fbb1b7acd81b2dbdd | 221 | exs | Elixir | test/distributed_elixir/web/controllers/page_controller_test.exs | odarriba/distributed-elixir-example | ef3075d8d14ff3c0f3cd6c06145659129d80f6d1 | [
"MIT"
] | 11 | 2017-08-08T08:38:28.000Z | 2019-09-16T09:20:06.000Z | test/distributed_elixir/web/controllers/page_controller_test.exs | odarriba/distributed-elixir-example | ef3075d8d14ff3c0f3cd6c06145659129d80f6d1 | [
"MIT"
] | null | null | null | test/distributed_elixir/web/controllers/page_controller_test.exs | odarriba/distributed-elixir-example | ef3075d8d14ff3c0f3cd6c06145659129d80f6d1 | [
"MIT"
] | null | null | null | defmodule DistributedElixir.Web.PageControllerTest do
use DistributedElixir.Web.ConnCase
test "GET /", %{conn: conn} do
conn = get conn, "/"
assert html_response(conn, 200) =~ "Welcome to Phoenix!"
end
end
| 24.555556 | 60 | 0.705882 |
e801c1b41e0bc70e140f2f37cd14a037048b7bc2 | 567 | ex | Elixir | lib/phoenix/transports/serializer.ex | raspo/phoenix | 438b74255e7a4d68b4eaf1a295d0fcd201c71421 | [
"MIT"
] | 2 | 2017-06-08T23:28:13.000Z | 2017-06-08T23:28:16.000Z | lib/phoenix/transports/serializer.ex | raspo/phoenix | 438b74255e7a4d68b4eaf1a295d0fcd201c71421 | [
"MIT"
] | null | null | null | lib/phoenix/transports/serializer.ex | raspo/phoenix | 438b74255e7a4d68b4eaf1a295d0fcd201c71421 | [
"MIT"
] | null | null | null | defmodule Phoenix.Transports.Serializer do
@moduledoc """
Defines a behaviour for `Phoenix.Socket.Message` serialization.
"""
@doc "Translates a `Phoenix.Socket.Broadcast` struct to fastlane format"
@callback fastlane!(Phoenix.Socket.Broadcast.t) :: term
@doc "Encodes `Phoenix.Socket.Message` struct to tr... | 37.8 | 78 | 0.749559 |
e801d81d12e3d69e1529f0f613d753945ad00d91 | 1,526 | ex | Elixir | test/support/data_case.ex | ATechnoHazard/katbin | 20a0b45954cf7819cd9d51c401db06be0f47666b | [
"MIT"
] | 4 | 2020-08-05T20:05:34.000Z | 2020-10-01T10:01:56.000Z | test/support/data_case.ex | ATechnoHazard/katbin | 20a0b45954cf7819cd9d51c401db06be0f47666b | [
"MIT"
] | 1 | 2020-07-08T05:02:12.000Z | 2020-09-25T10:05:11.000Z | test/support/data_case.ex | ATechnoHazard/katbin | 20a0b45954cf7819cd9d51c401db06be0f47666b | [
"MIT"
] | 1 | 2020-08-30T12:59:49.000Z | 2020-08-30T12:59:49.000Z | defmodule Ketbin.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 th... | 27.25 | 77 | 0.687418 |
e801ea36eac431d2387e0f374e604eb037bc5caa | 98 | exs | Elixir | test/notifications_test.exs | rogaz/thesis-phoenix | 8ad24cdc7e24bf312139a527db5a3bf07e05820f | [
"MIT"
] | 681 | 2016-06-21T20:49:21.000Z | 2022-02-19T04:08:38.000Z | test/notifications_test.exs | rogaz/thesis-phoenix | 8ad24cdc7e24bf312139a527db5a3bf07e05820f | [
"MIT"
] | 125 | 2016-06-21T21:14:49.000Z | 2020-12-12T20:15:48.000Z | test/notifications_test.exs | rogaz/thesis-phoenix | 8ad24cdc7e24bf312139a527db5a3bf07e05820f | [
"MIT"
] | 76 | 2016-09-06T03:40:55.000Z | 2022-01-20T21:29:22.000Z | defmodule NotificationsTest do
use ExUnit.Case
doctest Thesis.Notifications, import: true
end
| 19.6 | 44 | 0.816327 |
e801f810973afe2bf6946934d1bc6ccf11bac74d | 141 | ex | Elixir | test_projects/phx_1.6/lib/phx_proj_web/controllers/page_controller.ex | qhwa/dockerize | d930f06da89a686961da7a5b5bdadb4c9b01ec32 | [
"MIT"
] | 47 | 2020-03-04T00:24:26.000Z | 2022-01-14T23:34:52.000Z | test_projects/phx_1.6/lib/phx_proj_web/controllers/page_controller.ex | qhwa/dockerize | d930f06da89a686961da7a5b5bdadb4c9b01ec32 | [
"MIT"
] | 2 | 2020-06-09T22:25:06.000Z | 2020-06-30T21:18:37.000Z | test_projects/phx_1.6/lib/phx_proj_web/controllers/page_controller.ex | qhwa/dockerize | d930f06da89a686961da7a5b5bdadb4c9b01ec32 | [
"MIT"
] | null | null | null | defmodule PhxProjWeb.PageController do
use PhxProjWeb, :controller
def index(conn, _params) do
render(conn, "index.html")
end
end
| 17.625 | 38 | 0.737589 |
e801f99c2d00210bbce290bebb66783eeb293a38 | 2,471 | ex | Elixir | clients/proximity_beacon/lib/google_api/proximity_beacon/v1beta1/model/ephemeral_id_registration_params.ex | matehat/elixir-google-api | c1b2523c2c4cdc9e6ca4653ac078c94796b393c3 | [
"Apache-2.0"
] | 1 | 2018-12-03T23:43:10.000Z | 2018-12-03T23:43:10.000Z | clients/proximity_beacon/lib/google_api/proximity_beacon/v1beta1/model/ephemeral_id_registration_params.ex | matehat/elixir-google-api | c1b2523c2c4cdc9e6ca4653ac078c94796b393c3 | [
"Apache-2.0"
] | null | null | null | clients/proximity_beacon/lib/google_api/proximity_beacon/v1beta1/model/ephemeral_id_registration_params.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.881356 | 139 | 0.760826 |
e802064203619a1d8a5554d8fda73a8bf7a1ddc1 | 1,144 | ex | Elixir | lib/rocketpay_web/router.ex | Pliavi/NLW-4-Rocketpay | fc146eb534e8dac634d618c7779b928b6172cbb2 | [
"MIT"
] | null | null | null | lib/rocketpay_web/router.ex | Pliavi/NLW-4-Rocketpay | fc146eb534e8dac634d618c7779b928b6172cbb2 | [
"MIT"
] | 1 | 2021-03-05T12:39:11.000Z | 2021-03-05T12:39:11.000Z | lib/rocketpay_web/router.ex | Pliavi/NLW-4-Rocketpay | fc146eb534e8dac634d618c7779b928b6172cbb2 | [
"MIT"
] | null | null | null | defmodule RocketpayWeb.Router do
use RocketpayWeb, :router
pipeline :api do
plug :accepts, ["json"]
end
scope "/api", RocketpayWeb do
pipe_through :api
post "/user", UserController, :create
post "/user/close_account", UserController, :delete
post "/operation/withdraw", OperationControlle... | 30.918919 | 70 | 0.722902 |
e802199440c3bcea07b21a1a9e7e660ecc662d26 | 1,697 | ex | Elixir | clients/sql_admin/lib/google_api/sql_admin/v1beta4/model/ssl_certs_create_ephemeral_request.ex | mcrumm/elixir-google-api | 544f22797cec52b3a23dfb6e39117f0018448610 | [
"Apache-2.0"
] | null | null | null | clients/sql_admin/lib/google_api/sql_admin/v1beta4/model/ssl_certs_create_ephemeral_request.ex | mcrumm/elixir-google-api | 544f22797cec52b3a23dfb6e39117f0018448610 | [
"Apache-2.0"
] | null | null | null | clients/sql_admin/lib/google_api/sql_admin/v1beta4/model/ssl_certs_create_ephemeral_request.ex | 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... | 33.94 | 120 | 0.741897 |
e8021e7bdcd1bc2e071076b2e52796f8293b5677 | 4,783 | ex | Elixir | clients/sheets/lib/google_api/sheets/v4/model/bubble_chart_spec.ex | MasashiYokota/elixir-google-api | 975dccbff395c16afcb62e7a8e411fbb58e9ab01 | [
"Apache-2.0"
] | null | null | null | clients/sheets/lib/google_api/sheets/v4/model/bubble_chart_spec.ex | MasashiYokota/elixir-google-api | 975dccbff395c16afcb62e7a8e411fbb58e9ab01 | [
"Apache-2.0"
] | null | null | null | clients/sheets/lib/google_api/sheets/v4/model/bubble_chart_spec.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... | 59.7875 | 314 | 0.720259 |
e8023343b5e382b1249321acaf3ef5b76bd807a3 | 4,290 | ex | Elixir | lib/game/world/master.ex | stevegrossi/ex_venture | e02d5a63fdb882d92cfb4af3e15f7b48ad7054aa | [
"MIT"
] | 2 | 2019-05-14T11:36:44.000Z | 2020-07-01T08:54:04.000Z | lib/game/world/master.ex | nickwalton/ex_venture | d8ff1b0181db03f9ddcb7610ae7ab533feecbfbb | [
"MIT"
] | null | null | null | lib/game/world/master.ex | nickwalton/ex_venture | d8ff1b0181db03f9ddcb7610ae7ab533feecbfbb | [
"MIT"
] | 1 | 2021-01-29T14:12:40.000Z | 2021-01-29T14:12:40.000Z | defmodule Game.World.Master do
@moduledoc """
Master process for the world
Help orchestrate startup of zones
"""
use GenServer
alias Game.World.ZoneController
alias Game.Zone
require Logger
@behaviour Squabble.Leader
@group :world_leaders
@table :world_leader
# rebalance every 15 minutes
... | 23.189189 | 98 | 0.653147 |
e8027a99a5ef6419580de839f92e594ca3c26bb0 | 1,605 | exs | Elixir | apps/snitch_api/mix.exs | Acrecio/avia | 54d264fc179b5b5f17d174854bdca063e1d935e9 | [
"MIT"
] | 456 | 2018-09-20T02:40:59.000Z | 2022-03-07T08:53:48.000Z | apps/snitch_api/mix.exs | Acrecio/avia | 54d264fc179b5b5f17d174854bdca063e1d935e9 | [
"MIT"
] | 273 | 2018-09-19T06:43:43.000Z | 2021-08-07T12:58:26.000Z | apps/snitch_api/mix.exs | Acrecio/avia | 54d264fc179b5b5f17d174854bdca063e1d935e9 | [
"MIT"
] | 122 | 2018-09-26T16:32:46.000Z | 2022-03-13T11:44:19.000Z | defmodule SnitchApi.Mixfile do
use Mix.Project
def project do
[
app: :snitch_api,
version: "0.0.1",
build_path: "../../_build",
config_path: "../../config/config.exs",
deps_path: "../../deps",
lockfile: "../../mix.lock",
elixir: "~> 1.7.2",
elixirc_paths: elixirc... | 25.078125 | 82 | 0.535826 |
e8027b540652bb74cb66d479c828d4d10e7e8924 | 1,016 | exs | Elixir | nashelixir+elixir/apps/cqrs_bank/mix.exs | NashFP/cqrs-bank | 6071db4a0c5ec681554aea8bebe783310c5d1525 | [
"MIT"
] | 7 | 2017-05-17T00:36:50.000Z | 2021-11-02T03:02:03.000Z | nashelixir+elixir/apps/cqrs_bank/mix.exs | NashFP/cqrs-bank | 6071db4a0c5ec681554aea8bebe783310c5d1525 | [
"MIT"
] | 3 | 2017-05-17T00:31:28.000Z | 2017-05-18T04:50:37.000Z | joshcrews+elixir/apps/cqrs_bank/mix.exs | NashFP/cqrs-bank | 6071db4a0c5ec681554aea8bebe783310c5d1525 | [
"MIT"
] | 5 | 2017-05-16T23:13:19.000Z | 2021-12-02T06:45:25.000Z | defmodule CqrsBank.Mixfile do
use Mix.Project
def project do
[app: :cqrs_bank,
version: "0.1.0",
build_path: "../../_build",
config_path: "../../config/config.exs",
deps_path: "../../deps",
lockfile: "../../mix.lock",
elixir: "~> 1.4",
build_embedded: Mix.env == :prod,
s... | 23.627907 | 79 | 0.606299 |
e802d90a2f0d2288bba2957a2faf640f70f9e13a | 3,071 | ex | Elixir | lib/join_maker.ex | m0rt3nlund/query_builder | 68bfdf7b642ded1a9056a85776c3fc5296b2b7b7 | [
"Apache-2.0"
] | 47 | 2019-12-20T08:35:20.000Z | 2022-03-23T15:11:45.000Z | lib/join_maker.ex | m0rt3nlund/query_builder | 68bfdf7b642ded1a9056a85776c3fc5296b2b7b7 | [
"Apache-2.0"
] | 7 | 2020-05-14T09:25:53.000Z | 2021-10-01T04:58:22.000Z | lib/join_maker.ex | m0rt3nlund/query_builder | 68bfdf7b642ded1a9056a85776c3fc5296b2b7b7 | [
"Apache-2.0"
] | 4 | 2020-04-21T13:54:46.000Z | 2021-08-12T22:15:22.000Z | defmodule QueryBuilder.JoinMaker do
@moduledoc false
require Ecto.Query
@doc ~S"""
Options may be:
* `:mode`: if set to `:if_preferable`, schemas are joined only if it is better
performance-wise; this happens only for one case: when the association has a
one-to-one cardinality, it is better to join and ... | 34.505618 | 139 | 0.694236 |
e802ef3a1922b65643aa51ab3dbbe6d8d3d22126 | 23,792 | exs | Elixir | installer/test/phx_new_umbrella_test.exs | TheMushrr00m/phoenix | 5f15107d6e102d5ceafc92b1ec1c397b601b9b66 | [
"MIT"
] | null | null | null | installer/test/phx_new_umbrella_test.exs | TheMushrr00m/phoenix | 5f15107d6e102d5ceafc92b1ec1c397b601b9b66 | [
"MIT"
] | null | null | null | installer/test/phx_new_umbrella_test.exs | TheMushrr00m/phoenix | 5f15107d6e102d5ceafc92b1ec1c397b601b9b66 | [
"MIT"
] | null | null | null | Code.require_file "mix_helper.exs", __DIR__
defmodule Mix.Tasks.Phx.New.UmbrellaTest do
use ExUnit.Case, async: false
import MixHelper
@app "phx_umb"
setup config do
# The shell asks to install deps.
# We will politely say not.
decline_prompt()
{:ok, tmp_dir: to_string(config.test)}
end
... | 42.259325 | 132 | 0.628867 |
e802f18334b242f12aab36b7b2bfea38e986714e | 421 | exs | Elixir | apps/cronitex_web/test/cronitex_web/views/error_view_test.exs | alayers2/cronitex | cf8da9553b8e93b9171f5e9a0f0a08a24a324689 | [
"MIT"
] | 1 | 2020-11-05T15:38:53.000Z | 2020-11-05T15:38:53.000Z | apps/cronitex_web/test/cronitex_web/views/error_view_test.exs | alayers2/cronitex | cf8da9553b8e93b9171f5e9a0f0a08a24a324689 | [
"MIT"
] | 36 | 2020-10-24T01:28:42.000Z | 2022-02-07T11:11:37.000Z | apps/cronitex_web/test/cronitex_web/views/error_view_test.exs | alayers2/cronitex | cf8da9553b8e93b9171f5e9a0f0a08a24a324689 | [
"MIT"
] | null | null | null | defmodule CronitexWeb.ErrorViewTest do
use CronitexWeb.ConnCase, async: true
# Bring render/3 and render_to_string/3 for testing custom views
import Phoenix.View
test "renders 404.html" do
assert render_to_string(CronitexWeb.ErrorView, "404.html", []) == "Not Found"
end
test "renders 500.html" do
... | 28.066667 | 93 | 0.736342 |
e803116279acd9973f80e4975dc7110e70da4301 | 123 | exs | Elixir | elixir/47.exs | merxer/kata | 5dbbca8b4173029f9311398148de9437a329cf9a | [
"MIT"
] | null | null | null | elixir/47.exs | merxer/kata | 5dbbca8b4173029f9311398148de9437a329cf9a | [
"MIT"
] | null | null | null | elixir/47.exs | merxer/kata | 5dbbca8b4173029f9311398148de9437a329cf9a | [
"MIT"
] | null | null | null | plusTwo = Enum.map [1,2,3,4], &(&1 + 2)
plusTwo
|> IO.inspect
eInspect = Enum.each [1,2,3,4], &(IO.inspect(&1))
eInspect
| 15.375 | 49 | 0.601626 |
e8033a4102a4763163ee77e7b87bb2a3000e6659 | 295 | ex | Elixir | lib/earmark/alt_parser.ex | aforward-oss/earmark | b44d4817aa2b4047b07f91d633ae83ed27c695ed | [
"Apache-2.0"
] | null | null | null | lib/earmark/alt_parser.ex | aforward-oss/earmark | b44d4817aa2b4047b07f91d633ae83ed27c695ed | [
"Apache-2.0"
] | null | null | null | lib/earmark/alt_parser.ex | aforward-oss/earmark | b44d4817aa2b4047b07f91d633ae83ed27c695ed | [
"Apache-2.0"
] | 1 | 2019-11-23T12:09:14.000Z | 2019-11-23T12:09:14.000Z | # # Inspired by https://github.com/MFP/OcsiBlog/blob/master/simple_markup.ml
# # Trying to port it to Elixir and later adapt it maybe to line oriented
# # parsing (lines being pre processed in parallel and then _unified_ ino tokens
# # by the parser.
# defmodule Earmark.AltParser do
# end
| 32.777778 | 80 | 0.749153 |
e8036c4a995f50f5c4fd32a266835e5ae3420186 | 13,589 | ex | Elixir | lib/surface/translator/component_translator_helper.ex | alexandrubagu/surface | b8ef74444e53f8325fb793fa1399966c2a4b1e7a | [
"MIT"
] | null | null | null | lib/surface/translator/component_translator_helper.ex | alexandrubagu/surface | b8ef74444e53f8325fb793fa1399966c2a4b1e7a | [
"MIT"
] | null | null | null | lib/surface/translator/component_translator_helper.ex | alexandrubagu/surface | b8ef74444e53f8325fb793fa1399966c2a4b1e7a | [
"MIT"
] | null | null | null | defmodule Surface.Translator.ComponentTranslatorHelper do
@moduledoc false
alias Surface.Translator.SlotableTranslator
alias Surface.Translator.IOHelper
def add_render_call(renderer, args, has_children? \\ false) do
["<%= ", renderer, "(", Enum.join(args, ", "), ") ", maybe_add("do ", has_children?), "%>"... | 28.912766 | 112 | 0.588932 |
e803b3a31308238849c7f1e0b600253ace542ede | 1,774 | exs | Elixir | test/api_test.exs | Voronchuk/kraken | 4b5d310ebeab5ddd97039773dc0acd8b566a1236 | [
"MIT"
] | 2 | 2019-02-07T18:36:04.000Z | 2020-07-18T13:53:02.000Z | test/api_test.exs | Voronchuk/kraken | 4b5d310ebeab5ddd97039773dc0acd8b566a1236 | [
"MIT"
] | null | null | null | test/api_test.exs | Voronchuk/kraken | 4b5d310ebeab5ddd97039773dc0acd8b566a1236 | [
"MIT"
] | null | null | null | defmodule Kraken.ApiTest do
use ExUnit.Case
setup do
api_key = System.get_env("KRAKEN_API_KEY")
private_key = System.get_env("KRAKEN_PRIVATE_KEY")
{:ok, %{api_key: api_key, private_key: private_key}}
end
test "fetching balance for some account", %{api_key: api_key, private_key: private_key} do
... | 30.067797 | 98 | 0.629087 |
e803c93720b8149287198591c4599661e4738f7e | 1,997 | ex | Elixir | clients/data_migration/lib/google_api/data_migration/v1beta1/model/audit_log_config.ex | mcrumm/elixir-google-api | 544f22797cec52b3a23dfb6e39117f0018448610 | [
"Apache-2.0"
] | null | null | null | clients/data_migration/lib/google_api/data_migration/v1beta1/model/audit_log_config.ex | mcrumm/elixir-google-api | 544f22797cec52b3a23dfb6e39117f0018448610 | [
"Apache-2.0"
] | 1 | 2020-12-18T09:25:12.000Z | 2020-12-18T09:25:12.000Z | clients/data_migration/lib/google_api/data_migration/v1beta1/model/audit_log_config.ex | 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... | 39.94 | 316 | 0.7331 |
e803f17aebe79e47145d634a3e23d6c5337b60af | 3,112 | ex | Elixir | lib/stripe/connect/transfer_reversal.ex | Rutaba/stripity_stripe | 12c525301c781f9c8c7e578cc0d933f5d35183d5 | [
"BSD-3-Clause"
] | 555 | 2016-11-29T05:02:27.000Z | 2022-03-30T00:47:59.000Z | lib/stripe/connect/transfer_reversal.ex | Rutaba/stripity_stripe | 12c525301c781f9c8c7e578cc0d933f5d35183d5 | [
"BSD-3-Clause"
] | 532 | 2016-11-28T18:22:25.000Z | 2022-03-30T17:04:32.000Z | lib/stripe/connect/transfer_reversal.ex | Rutaba/stripity_stripe | 12c525301c781f9c8c7e578cc0d933f5d35183d5 | [
"BSD-3-Clause"
] | 296 | 2016-12-05T14:04:09.000Z | 2022-03-28T20:39:37.000Z | defmodule Stripe.TransferReversal do
@moduledoc """
Work with Stripe transfer_reversal objects.
Stripe API reference: https://stripe.com/docs/api#transfer_reversal_object
"""
use Stripe.Entity
import Stripe.Request
@type t :: %__MODULE__{
id: Stripe.id(),
object: String.t(),
... | 28.814815 | 98 | 0.56973 |
e803f8ac9364d822b45ba3410cb8b26261c1e233 | 5,202 | ex | Elixir | apps/omg_db/lib/omg_db/level_db.ex | PinkDiamond1/elixir-omg | 70dfd24a0a1ddf5d1d9d71aab61ea25300f889f7 | [
"Apache-2.0"
] | null | null | null | apps/omg_db/lib/omg_db/level_db.ex | PinkDiamond1/elixir-omg | 70dfd24a0a1ddf5d1d9d71aab61ea25300f889f7 | [
"Apache-2.0"
] | null | null | null | apps/omg_db/lib/omg_db/level_db.ex | PinkDiamond1/elixir-omg | 70dfd24a0a1ddf5d1d9d71aab61ea25300f889f7 | [
"Apache-2.0"
] | 1 | 2021-12-04T00:37:46.000Z | 2021-12-04T00:37:46.000Z | # 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... | 34.450331 | 114 | 0.713379 |
e8042098a03373530c53d83f94e394e89a536c29 | 10,502 | ex | Elixir | lib/imagine/cms_pages/cms_page.ex | nacengineer/imagine_cms | 00a73790f9de6c409bb87e1fdfb3b41010a9d222 | [
"Apache-2.0"
] | 25 | 2020-09-08T05:13:40.000Z | 2022-03-15T13:35:59.000Z | lib/imagine/cms_pages/cms_page.ex | nacengineer/imagine_cms | 00a73790f9de6c409bb87e1fdfb3b41010a9d222 | [
"Apache-2.0"
] | null | null | null | lib/imagine/cms_pages/cms_page.ex | nacengineer/imagine_cms | 00a73790f9de6c409bb87e1fdfb3b41010a9d222 | [
"Apache-2.0"
] | 3 | 2021-08-11T03:48:54.000Z | 2022-02-09T20:11:06.000Z | defmodule Imagine.CmsPages.CmsPage do
@moduledoc """
CMS Page (versioned, parent-child tree)
has_many objects, tags, sub_pages
belongs_to cms_template, parent
"""
use Ecto.Schema
import Ecto.Changeset
import Ecto.Query, warn: false
alias Imagine.Repo
alias Imagine.CmsPages
alias Imagine.CmsPage... | 29.335196 | 97 | 0.67549 |
e804231135851df016af4ef76d1975e6b18da57e | 459 | ex | Elixir | Elixr/euler.ex | Nebopolis/project_euler | a1493c7fc6b6ee33ec6c584da5ffaf10032b4fbf | [
"MIT"
] | null | null | null | Elixr/euler.ex | Nebopolis/project_euler | a1493c7fc6b6ee33ec6c584da5ffaf10032b4fbf | [
"MIT"
] | null | null | null | Elixr/euler.ex | Nebopolis/project_euler | a1493c7fc6b6ee33ec6c584da5ffaf10032b4fbf | [
"MIT"
] | null | null | null | defmodule Fib do
def fib do
Stream.unfold({0, 1}, fn {a, b} -> {a, {b, a + b}} end)
end
end
defmodule Euler do
def euler1 max do
1..max-1
|> Stream.filter(&(rem(&1, 3) == 0 || rem(&1, 5) == 0))
|> Enum.sum
end
def euler2 max do
Fib.fib
|> Stream.take_while(&(&1 < max))
|> Stream.... | 17 | 59 | 0.56427 |
e80426c61ef6195564fae1b0dcdc29e740959b85 | 3,884 | exs | Elixir | apps/ewallet/test/ewallet/web/v1/serializers/export_serializer_test.exs | jimpeebles/ewallet | ad4a9750ec8dc5adc4c0dfe6c22f0ef760825405 | [
"Apache-2.0"
] | null | null | null | apps/ewallet/test/ewallet/web/v1/serializers/export_serializer_test.exs | jimpeebles/ewallet | ad4a9750ec8dc5adc4c0dfe6c22f0ef760825405 | [
"Apache-2.0"
] | null | null | null | apps/ewallet/test/ewallet/web/v1/serializers/export_serializer_test.exs | jimpeebles/ewallet | ad4a9750ec8dc5adc4c0dfe6c22f0ef760825405 | [
"Apache-2.0"
] | null | null | null | # Copyright 2018 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... | 32.099174 | 74 | 0.613543 |
e8042a0e1f8548b5bb6472b055df556ad7ffe552 | 1,986 | ex | Elixir | lib/redix/exceptions.ex | duksis/redix | 2bda17516b6a702b4054dbd101ad3ba00464c707 | [
"MIT"
] | null | null | null | lib/redix/exceptions.ex | duksis/redix | 2bda17516b6a702b4054dbd101ad3ba00464c707 | [
"MIT"
] | null | null | null | lib/redix/exceptions.ex | duksis/redix | 2bda17516b6a702b4054dbd101ad3ba00464c707 | [
"MIT"
] | 1 | 2020-11-23T17:32:40.000Z | 2020-11-23T17:32:40.000Z | defmodule Redix.Error do
@moduledoc """
Error returned by Redis.
This exception represents semantic errors returned by Redis: for example,
non-existing commands or operations on keys with the wrong type (`INCR
not_an_integer`).
"""
defexception [:message]
@type t :: %__MODULE__{message: binary}
end
... | 26.131579 | 80 | 0.70292 |
e8043edf9688eaddba177dd973bbb34166708dcd | 1,006 | ex | Elixir | web/views/error_helpers.ex | raincrash/pasteboard | e6b6f027bd18e1e4494c62c8127b89363b7466f5 | [
"MIT"
] | null | null | null | web/views/error_helpers.ex | raincrash/pasteboard | e6b6f027bd18e1e4494c62c8127b89363b7466f5 | [
"MIT"
] | null | null | null | web/views/error_helpers.ex | raincrash/pasteboard | e6b6f027bd18e1e4494c62c8127b89363b7466f5 | [
"MIT"
] | null | null | null | defmodule Pasteboard.ErrorHelpers do
@moduledoc """
Conveniences for translating and building error messages.
"""
use Phoenix.HTML
@doc """
Generates tag for inlined form input errors.
"""
def error_tag(form, field) do
if error = form.errors[field] do
content_tag :span, translate_error(error... | 27.944444 | 81 | 0.681909 |
e8045d85b9fae71cf199c972f00e70997943fc57 | 647 | exs | Elixir | test/slacker/parsers/prefix_test.exs | mikfreedman/slacker | 9e13b2ab232828ae7050f1c460233e572984d508 | [
"MIT"
] | 1 | 2016-05-19T05:10:16.000Z | 2016-05-19T05:10:16.000Z | test/slacker/parsers/prefix_test.exs | pivotal-sydney/slacker | 9e13b2ab232828ae7050f1c460233e572984d508 | [
"MIT"
] | 3 | 2016-01-17T09:07:17.000Z | 2016-01-19T21:55:21.000Z | test/slacker/parsers/prefix_test.exs | mikfreedman/slacker | 9e13b2ab232828ae7050f1c460233e572984d508 | [
"MIT"
] | null | null | null | defmodule Slacker.Parsers.PrefixTest do
use ExUnit.Case
test "#try_parse parses out echo command" do
assert Slacker.Parsers.Prefix.try_parse("echo hello world") == {:command, "echo", "hello world"}
end
test "#try_parse supports commands with hyphens" do
assert Slacker.Parsers.Prefix.try_parse("foo-bar... | 32.35 | 106 | 0.712519 |
e8048e7eb18f18c399dee1f3b63c9376efafcf2f | 12,840 | ex | Elixir | lib/aws/kinesis_analytics_v2.ex | ahsandar/aws-elixir | 25de8b6c3a1401bde737cfc26b0679b14b058f23 | [
"Apache-2.0"
] | null | null | null | lib/aws/kinesis_analytics_v2.ex | ahsandar/aws-elixir | 25de8b6c3a1401bde737cfc26b0679b14b058f23 | [
"Apache-2.0"
] | null | null | null | lib/aws/kinesis_analytics_v2.ex | ahsandar/aws-elixir | 25de8b6c3a1401bde737cfc26b0679b14b058f23 | [
"Apache-2.0"
] | null | null | null | # WARNING: DO NOT EDIT, AUTO-GENERATED CODE!
# See https://github.com/aws-beam/aws-codegen for more details.
defmodule AWS.KinesisAnalyticsV2 do
@moduledoc """
Amazon Kinesis Data Analytics is a fully managed service that you can use
to process and analyze streaming data using SQL or Java. The service
enables ... | 37.988166 | 94 | 0.735514 |
e8049e152e1b25f0be9c1e53aa93153d920e6c9c | 14,960 | ex | Elixir | deps/phoenix/lib/phoenix/test/channel_test.ex | Hajto/hangmanelixir | a05cc0b73e0a5d464405f63d274ae622565728ca | [
"MIT"
] | null | null | null | deps/phoenix/lib/phoenix/test/channel_test.ex | Hajto/hangmanelixir | a05cc0b73e0a5d464405f63d274ae622565728ca | [
"MIT"
] | null | null | null | deps/phoenix/lib/phoenix/test/channel_test.ex | Hajto/hangmanelixir | a05cc0b73e0a5d464405f63d274ae622565728ca | [
"MIT"
] | null | null | null | defmodule Phoenix.ChannelTest do
@moduledoc """
Conveniences for testing Phoenix channels.
In channel tests, we interact with channels via process
communication, sending and receiving messages. It is also
common to subscribe to the same topic the channel subscribes
to, allowing us to assert if a given mess... | 31.965812 | 91 | 0.673529 |
e804a4f6578282812fd9665cd8c960e92a3ffadb | 1,561 | ex | Elixir | apps/maintenance_web/lib/maintenance_web/views/error_helpers.ex | eksperimental/maintenance | 5d332f4886b59510e37d32ad89c724840989ada0 | [
"CC0-1.0",
"MIT-0"
] | 3 | 2021-11-13T04:50:40.000Z | 2022-01-09T21:27:33.000Z | apps/maintenance_web/lib/maintenance_web/views/error_helpers.ex | eksperimental/maintenance | 5d332f4886b59510e37d32ad89c724840989ada0 | [
"CC0-1.0",
"MIT-0"
] | null | null | null | apps/maintenance_web/lib/maintenance_web/views/error_helpers.ex | eksperimental/maintenance | 5d332f4886b59510e37d32ad89c724840989ada0 | [
"CC0-1.0",
"MIT-0"
] | null | null | null | defmodule MaintenanceWeb.ErrorHelpers do
@moduledoc """
Conveniences for translating and building error messages.
"""
use Phoenix.HTML
@doc """
Generates tag for inlined form input errors.
"""
def error_tag(form, field) do
Enum.map(Keyword.get_values(form.errors, field), fn error ->
content_... | 32.520833 | 80 | 0.668161 |
e804ec08353a1bdafe3a32178d2a9ac28b583240 | 1,894 | ex | Elixir | clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_publish_to_pub_sub.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2021-12-20T03:40:53.000Z | 2021-12-20T03:40:53.000Z | clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_publish_to_pub_sub.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2020-08-18T00:11:23.000Z | 2020-08-18T00:44:16.000Z | clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_publish_to_pub_sub.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | null | null | null | # Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, s... | 40.297872 | 288 | 0.755544 |
e804f91e18139fc3d50e2c19fca5d1038d33f297 | 50 | exs | Elixir | .medic/update.exs | dbrody/playwright-elixir | 48611c08dbdb8e36aa4dd8aa2d97a4014b753815 | [
"MIT"
] | 30 | 2021-06-01T16:59:35.000Z | 2022-03-25T16:56:19.000Z | .medic/update.exs | dbrody/playwright-elixir | 48611c08dbdb8e36aa4dd8aa2d97a4014b753815 | [
"MIT"
] | 35 | 2021-06-10T17:05:31.000Z | 2022-02-11T22:30:36.000Z | .medic/update.exs | dbrody/playwright-elixir | 48611c08dbdb8e36aa4dd8aa2d97a4014b753815 | [
"MIT"
] | 4 | 2021-08-13T20:38:18.000Z | 2022-01-31T04:32:35.000Z | [:update_code, :update_mix, :update_npm, :doctor]
| 25 | 49 | 0.74 |
e80520035d1c43992f19bb87bdb53831d8d8bed7 | 3,239 | exs | Elixir | test/support/testverifier.exs | axelson/inky | f9112e239040010b5336f144d407bd1492cae387 | [
"Apache-2.0"
] | 51 | 2019-06-23T21:03:59.000Z | 2022-03-17T04:57:57.000Z | test/support/testverifier.exs | axelson/inky | f9112e239040010b5336f144d407bd1492cae387 | [
"Apache-2.0"
] | 24 | 2019-06-17T05:56:34.000Z | 2021-12-05T15:06:37.000Z | test/support/testverifier.exs | axelson/inky | f9112e239040010b5336f144d407bd1492cae387 | [
"Apache-2.0"
] | 9 | 2019-07-26T13:06:13.000Z | 2021-11-27T13:12:24.000Z | defmodule Inky.TestVerifier do
@moduledoc false
defmodule MockInteractionException do
@moduledoc false
defexception message: "Interaction with mock did not match expectation.",
description: nil,
issue: nil,
item: -1
def unmet(reason, item) do
%... | 27.922414 | 89 | 0.62581 |
e80546a6e53e66d40b1aaed12c87e4c783b0a360 | 912 | ex | Elixir | lib/fake/headway/request.ex | mbta/realtime_signs | 3fd8cbc26ce2b0820e608e60fe12135dab5def69 | [
"MIT"
] | 1 | 2022-01-24T12:39:05.000Z | 2022-01-24T12:39:05.000Z | lib/fake/headway/request.ex | mbta/realtime_signs | 3fd8cbc26ce2b0820e608e60fe12135dab5def69 | [
"MIT"
] | 40 | 2021-05-05T10:14:25.000Z | 2022-03-31T18:34:15.000Z | lib/fake/headway/request.ex | mbta/realtime_signs | 3fd8cbc26ce2b0820e608e60fe12135dab5def69 | [
"MIT"
] | 1 | 2022-03-20T21:08:12.000Z | 2022-03-20T21:08:12.000Z | defmodule Fake.Headway.Request do
@times [
~N[2017-07-04 09:05:00],
~N[2017-07-04 08:55:00],
~N[2017-07-04 08:45:00],
~N[2017-07-04 09:20:00]
]
def get_schedules(stop_list) do
Enum.flat_map(stop_list, fn stop_id ->
Enum.map(@times, fn time ->
%{
"relationships" => %{
... | 30.4 | 91 | 0.469298 |
e805947b26765d72280ce45f36e803664b1f5df3 | 254 | exs | Elixir | config/test.exs | 03juan/ecto_cellar | 0adbf48207947927ab133754a7cfdb4a45d4da61 | [
"Apache-2.0"
] | null | null | null | config/test.exs | 03juan/ecto_cellar | 0adbf48207947927ab133754a7cfdb4a45d4da61 | [
"Apache-2.0"
] | null | null | null | config/test.exs | 03juan/ecto_cellar | 0adbf48207947927ab133754a7cfdb4a45d4da61 | [
"Apache-2.0"
] | null | null | null | import Config
if System.get_env("DB_ADAPTER") == "mysql" do
config :ecto_cellar, :repo, MyXQL.Repo
config :ecto_cellar, ecto_repos: [MyXQL.Repo]
else
config :ecto_cellar, :repo, Postgres.Repo
config :ecto_cellar, ecto_repos: [Postgres.Repo]
end
| 25.4 | 50 | 0.744094 |
e80596ae37bc5521da5500b789bc716c0a257d64 | 395 | ex | Elixir | lib/rocketseat_nlw_heat_impulse_elixir/messages/create.ex | jobsonita/rocketseat_nlw_heat_impulse_elixir | 13b5dc0fe2137c1acbc42afee1d40c43e7f9883f | [
"MIT"
] | null | null | null | lib/rocketseat_nlw_heat_impulse_elixir/messages/create.ex | jobsonita/rocketseat_nlw_heat_impulse_elixir | 13b5dc0fe2137c1acbc42afee1d40c43e7f9883f | [
"MIT"
] | null | null | null | lib/rocketseat_nlw_heat_impulse_elixir/messages/create.ex | jobsonita/rocketseat_nlw_heat_impulse_elixir | 13b5dc0fe2137c1acbc42afee1d40c43e7f9883f | [
"MIT"
] | null | null | null | defmodule RocketseatNlwHeatImpulseElixir.Messages.Create do
alias RocketseatNlwHeatImpulseElixir.{Message, Repo}
def call(params) do
params
|> Message.changeset()
|> Repo.insert()
|> handle_insert()
end
defp handle_insert({:ok, %Message{}} = result), do: result
defp handle_insert({:error, r... | 23.235294 | 60 | 0.693671 |
e8059ef91761cf48c86aa0fca87efef79a1d1ee4 | 3,233 | exs | Elixir | elixir/triangle/triangle_test.exs | macborowy/exercism | c5d45e074e81b946a82a340b2730e0d2732b7e0a | [
"MIT"
] | null | null | null | elixir/triangle/triangle_test.exs | macborowy/exercism | c5d45e074e81b946a82a340b2730e0d2732b7e0a | [
"MIT"
] | null | null | null | elixir/triangle/triangle_test.exs | macborowy/exercism | c5d45e074e81b946a82a340b2730e0d2732b7e0a | [
"MIT"
] | null | null | null | if !System.get_env("EXERCISM_TEST_EXAMPLES") do
Code.load_file("triangle.exs")
end
ExUnit.start
ExUnit.configure exclude: :pending, trace: true
# defmodule IsTriangleTests do
# use ExUnit.Case
#
# test "triangle (4,5,6) is valid triangle" do
# assert Triangle.is_inequal?(4, 5, 6) == :ok
# end
#
# test "... | 29.390909 | 100 | 0.668419 |
e805b5e259a0e690ee523a04c2f7e5ac8f310dfa | 1,469 | exs | Elixir | lib/iex/test/iex/server_test.exs | guilleiguaran/elixir | 952052869ff7af0e293d2a7160b1aebc68fc46be | [
"Apache-2.0"
] | null | null | null | lib/iex/test/iex/server_test.exs | guilleiguaran/elixir | 952052869ff7af0e293d2a7160b1aebc68fc46be | [
"Apache-2.0"
] | null | null | null | lib/iex/test/iex/server_test.exs | guilleiguaran/elixir | 952052869ff7af0e293d2a7160b1aebc68fc46be | [
"Apache-2.0"
] | null | null | null | Code.require_file "../test_helper.exs", __DIR__
defmodule IEx.ServerTest do
use IEx.Case
setup do
IEx.Options.set :colors, enabled: false
:ok
end
# Options
test "prefix option" do
assert capture_io(fn ->
boot([prefix: "pry"])
end) =~ "pry(1)> "
end
test "delegate_locals_to optio... | 22.257576 | 72 | 0.596324 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.