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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
330a1d588976e4bb5b76e9e1e66c249be94fa76c | 3,205 | ex | Elixir | lib/erlef_web/views/page_view.ex | kianmeng/website | 1948f46eeeb1c1b598408bfb049bbe24189ace2e | [
"Apache-2.0"
] | 1 | 2019-10-31T19:59:41.000Z | 2019-10-31T19:59:41.000Z | lib/erlef_web/views/page_view.ex | kianmeng/website | 1948f46eeeb1c1b598408bfb049bbe24189ace2e | [
"Apache-2.0"
] | null | null | null | lib/erlef_web/views/page_view.ex | kianmeng/website | 1948f46eeeb1c1b598408bfb049bbe24189ace2e | [
"Apache-2.0"
] | null | null | null | defmodule ErlefWeb.PageView do
use ErlefWeb, :view
import ErlefWeb.ViewHelpers
def affiliate_card_wall(items) do
assigns = %{items: items}
~H"""
<div class="row">
<%= for i <- @items do %>
<div class="col-md-4 mb-5">
<div class="card affiliate-card h-100 shadow-sm">
... | 28.873874 | 91 | 0.426209 |
330a354f05cf41d1690b7c3cbbac0a125ebab028 | 547 | ex | Elixir | web/controllers/api/user_controller.ex | travisboettcher/futurecyborg-blog | 927c26ee9e94f0739847aa649050b5263ece9239 | [
"MIT"
] | null | null | null | web/controllers/api/user_controller.ex | travisboettcher/futurecyborg-blog | 927c26ee9e94f0739847aa649050b5263ece9239 | [
"MIT"
] | null | null | null | web/controllers/api/user_controller.ex | travisboettcher/futurecyborg-blog | 927c26ee9e94f0739847aa649050b5263ece9239 | [
"MIT"
] | null | null | null | defmodule FutureCyborg.API.UserController do
use FutureCyborg.Web, :controller
alias FutureCyborg.User
def index(conn, %{"username" => username}) do
users = Repo.all(from u in User,
where: u.username == ^username)
|> Enum.map(&(Map.take(&1, [:username])))
json conn, %{users: users}
end
... | 24.863636 | 48 | 0.579525 |
330a3f82f37cc9857d04723c0bdb2a12a6803d2b | 2,161 | exs | Elixir | webchika_firmware/mix.exs | kentaro/nerves_webchika | cd110140894591022331b020d1296d040d6c44fb | [
"MIT"
] | 2 | 2020-11-26T14:29:17.000Z | 2020-11-26T18:45:56.000Z | webchika_firmware/mix.exs | kentaro/nerves_webchika | cd110140894591022331b020d1296d040d6c44fb | [
"MIT"
] | null | null | null | webchika_firmware/mix.exs | kentaro/nerves_webchika | cd110140894591022331b020d1296d040d6c44fb | [
"MIT"
] | 1 | 2021-01-06T15:50:28.000Z | 2021-01-06T15:50:28.000Z | defmodule WebchikaFirmware.MixProject do
use Mix.Project
@app :webchika_firmware
@version "0.1.0"
@all_targets [:rpi, :rpi0, :rpi2, :rpi3, :rpi3a, :rpi4, :bbb, :osd32mp1, :x86_64]
def project do
[
app: @app,
version: @version,
elixir: "~> 1.9",
archives: [nerves_bootstrap: "~> 1.... | 31.779412 | 83 | 0.591856 |
330a58f12cdada5c33237e8a7ddd466fc41db458 | 350 | ex | Elixir | lib/pkcs7/entry/signature/digest_algorithm_identifier.ex | edenlabllc/pkcs7_verify.api | ec2cfcd4892babae345ac485b833455773f1222b | [
"MIT"
] | 1 | 2020-09-25T10:10:16.000Z | 2020-09-25T10:10:16.000Z | lib/pkcs7/entry/signature/digest_algorithm_identifier.ex | Nebo15/pkcs7_verify.api | ec2cfcd4892babae345ac485b833455773f1222b | [
"MIT"
] | null | null | null | lib/pkcs7/entry/signature/digest_algorithm_identifier.ex | Nebo15/pkcs7_verify.api | ec2cfcd4892babae345ac485b833455773f1222b | [
"MIT"
] | 1 | 2018-01-16T14:37:16.000Z | 2018-01-16T14:37:16.000Z | defmodule PKCS7.Entry.Signature.DigestAlgorithmIdentifier do
defstruct algorithm: nil, # %PKCS7.Shared.AlgorithmIdentifier{}
parameters: nil # binary
def from_record({:DigestAlgorithmIdentifier, algorithm, parameters}) do
%__MODULE__{
algorithm: PKCS7.oid_to_atom(algorithm),
parameter... | 29.166667 | 73 | 0.728571 |
330a7854df613d37ab1cfdf053dbca9ab34d4306 | 1,292 | ex | Elixir | lib/rig/authorization_check/subscription.ex | steveoliver/reactive-interaction-gateway | 59b6dc994fd0f098bed19b7bf1e699513ac87167 | [
"Apache-2.0"
] | 518 | 2017-11-09T13:10:49.000Z | 2022-03-28T14:29:50.000Z | lib/rig/authorization_check/subscription.ex | steveoliver/reactive-interaction-gateway | 59b6dc994fd0f098bed19b7bf1e699513ac87167 | [
"Apache-2.0"
] | 270 | 2017-11-10T00:11:34.000Z | 2022-02-27T13:08:16.000Z | lib/rig/authorization_check/subscription.ex | steveoliver/reactive-interaction-gateway | 59b6dc994fd0f098bed19b7bf1e699513ac87167 | [
"Apache-2.0"
] | 67 | 2017-12-19T20:16:37.000Z | 2022-03-31T10:43:04.000Z | defmodule RIG.AuthorizationCheck.Subscription do
@moduledoc """
Decides whether to allow or reject a subscription request.
"""
use Rig.Config, :custom_validation
alias RIG.AuthorizationCheck.External
alias RIG.AuthorizationCheck.Header
alias RIG.AuthorizationCheck.Request
# Confex callback
defp vali... | 23.071429 | 75 | 0.641641 |
330a9cf2e42ebc4abe33a5e9bfee5f44ee4ae3d0 | 122 | exs | Elixir | test_apps/0.0.1/elixir_test/test/elixir_test_test.exs | emedia-project/xrel | 56d69ad8fbd9da5be043a6a094ca3ef0a2d1db83 | [
"Unlicense"
] | 5 | 2015-12-14T16:02:09.000Z | 2016-11-29T12:50:50.000Z | test_apps/0.0.1/elixir_test/test/elixir_test_test.exs | G-Corp/jorel | 56d69ad8fbd9da5be043a6a094ca3ef0a2d1db83 | [
"Unlicense"
] | 3 | 2016-02-12T14:36:50.000Z | 2016-08-29T08:17:55.000Z | test_apps/0.0.1/elixir_test/test/elixir_test_test.exs | G-Corp/jorel | 56d69ad8fbd9da5be043a6a094ca3ef0a2d1db83 | [
"Unlicense"
] | 2 | 2016-01-02T15:19:53.000Z | 2016-10-21T15:32:11.000Z | defmodule ElixirTestTest do
use ExUnit.Case
doctest ElixirTest
test "the truth" do
assert 1 + 1 == 2
end
end
| 13.555556 | 27 | 0.688525 |
330ac9024e00df8a4fec14b689ae85b6e22d6ee7 | 1,972 | ex | Elixir | lib/cforum_web/views/cite_view.ex | MatthiasApsel/cforum_ex | 52c621a583182d82692b74694b0b2792ac23b8ff | [
"MIT"
] | null | null | null | lib/cforum_web/views/cite_view.ex | MatthiasApsel/cforum_ex | 52c621a583182d82692b74694b0b2792ac23b8ff | [
"MIT"
] | null | null | null | lib/cforum_web/views/cite_view.ex | MatthiasApsel/cforum_ex | 52c621a583182d82692b74694b0b2792ac23b8ff | [
"MIT"
] | null | null | null | defmodule CforumWeb.CiteView do
use CforumWeb, :view
alias Cforum.Cites
alias CforumWeb.Paginator
alias Cforum.Abilities
alias Cforum.Helpers
alias CforumWeb.Views.ViewHelpers
alias CforumWeb.Views.ViewHelpers.Path
alias CforumWeb.ErrorHelpers
def page_title(:index, _), do: gettext("cites")
def... | 36.518519 | 116 | 0.681542 |
330ad0ccc4828c2d618f5af0264a729f83b3826e | 2,342 | ex | Elixir | clients/health_care/lib/google_api/health_care/v1beta1/model/entity.ex | mcrumm/elixir-google-api | 544f22797cec52b3a23dfb6e39117f0018448610 | [
"Apache-2.0"
] | null | null | null | clients/health_care/lib/google_api/health_care/v1beta1/model/entity.ex | mcrumm/elixir-google-api | 544f22797cec52b3a23dfb6e39117f0018448610 | [
"Apache-2.0"
] | 1 | 2020-12-18T09:25:12.000Z | 2020-12-18T09:25:12.000Z | clients/health_care/lib/google_api/health_care/v1beta1/model/entity.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... | 44.188679 | 439 | 0.740393 |
330ada8d87943460ed1b4621763634e7d06245bc | 1,211 | exs | Elixir | mix.exs | coop/opentelemetry_ecto | b3171033db83455bf0fed787ab29d74031c4b57d | [
"Apache-2.0"
] | null | null | null | mix.exs | coop/opentelemetry_ecto | b3171033db83455bf0fed787ab29d74031c4b57d | [
"Apache-2.0"
] | null | null | null | mix.exs | coop/opentelemetry_ecto | b3171033db83455bf0fed787ab29d74031c4b57d | [
"Apache-2.0"
] | null | null | null | defmodule OpentelemetryEcto.MixProject do
use Mix.Project
def project do
[
app: :opentelemetry_ecto,
description: description(),
version: "0.1.0",
elixir: "~> 1.9",
start_permanent: Mix.env() == :prod,
deps: deps(),
aliases: aliases(),
elixirc_paths: elixirc_path... | 23.288462 | 86 | 0.57308 |
330b023fe0b6774be237dd350012d33be693a58e | 15,522 | ex | Elixir | lib/phoenix/endpoint.ex | thegrubbsian/phoenix | a8ff809ddd24a2c4277da5cca122d70709313ac8 | [
"MIT"
] | null | null | null | lib/phoenix/endpoint.ex | thegrubbsian/phoenix | a8ff809ddd24a2c4277da5cca122d70709313ac8 | [
"MIT"
] | null | null | null | lib/phoenix/endpoint.ex | thegrubbsian/phoenix | a8ff809ddd24a2c4277da5cca122d70709313ac8 | [
"MIT"
] | null | null | null | defmodule Phoenix.Endpoint do
@moduledoc """
Defines a Phoenix endpoint.
The endpoint is the boundary where all requests to your
web application start. It is also the interface your
application provides to the underlying web servers.
Overall, an endpoint has three responsibilities:
* to provide a wra... | 33.89083 | 109 | 0.66686 |
330b3b9281b3556ac90070c2eedb232bb1b0a44a | 47,838 | exs | Elixir | test/ecto/changeset/has_assoc_test.exs | anthonator/ecto | 00df9cc724aedc753c8dd3206e9f6ff90f491a02 | [
"Apache-2.0"
] | null | null | null | test/ecto/changeset/has_assoc_test.exs | anthonator/ecto | 00df9cc724aedc753c8dd3206e9f6ff90f491a02 | [
"Apache-2.0"
] | null | null | null | test/ecto/changeset/has_assoc_test.exs | anthonator/ecto | 00df9cc724aedc753c8dd3206e9f6ff90f491a02 | [
"Apache-2.0"
] | null | null | null | defmodule Ecto.Changeset.HasAssocTest do
use ExUnit.Case, async: true
alias Ecto.Changeset
alias Ecto.Changeset.Relation
alias Ecto.TestRepo
alias __MODULE__.Author
alias __MODULE__.Post
alias __MODULE__.Profile
defmodule Post do
use Ecto.Schema
schema "posts" do
field :title, :string
... | 38.924329 | 128 | 0.653873 |
330b421f3472ae893f469bd73a96a963567d7c67 | 2,100 | exs | Elixir | test/jsonrpc2/http_test.exs | InoMurko/jsonrpc2-elixir | 3edb92061231ddc9edc1a69531f7248d3d00d8f3 | [
"Apache-2.0"
] | null | null | null | test/jsonrpc2/http_test.exs | InoMurko/jsonrpc2-elixir | 3edb92061231ddc9edc1a69531f7248d3d00d8f3 | [
"Apache-2.0"
] | null | null | null | test/jsonrpc2/http_test.exs | InoMurko/jsonrpc2-elixir | 3edb92061231ddc9edc1a69531f7248d3d00d8f3 | [
"Apache-2.0"
] | null | null | null | defmodule JSONRPC2.HTTPTest do
use ExUnit.Case, async: true
setup do
port = :rand.uniform(65535 - 1025) + 1025
{:ok, pid} = JSONRPC2.Servers.HTTP.http(JSONRPC2.SpecHandler, port: port)
on_exit(fn ->
ref = Process.monitor(pid)
JSONRPC2.Servers.HTTP.shutdown(JSONRPC2.SpecHandler.HTTP)
... | 31.343284 | 111 | 0.53 |
330b696833edad228aeefaa4130e8a61f114f9b0 | 4,894 | ex | Elixir | lib/elixir_rsyslog_backend.ex | sean-lin/elixir_rsyslog_backend | 1dd4d87b357b1e2c1c706e16a68ba45011066fea | [
"MIT"
] | 1 | 2019-07-17T15:58:39.000Z | 2019-07-17T15:58:39.000Z | lib/elixir_rsyslog_backend.ex | sean-lin/elixir_rsyslog_backend | 1dd4d87b357b1e2c1c706e16a68ba45011066fea | [
"MIT"
] | null | null | null | lib/elixir_rsyslog_backend.ex | sean-lin/elixir_rsyslog_backend | 1dd4d87b357b1e2c1c706e16a68ba45011066fea | [
"MIT"
] | 1 | 2018-09-19T08:39:59.000Z | 2018-09-19T08:39:59.000Z | defmodule Logger.Backends.Rsyslog do
use Bitwise
defmodule Utils do
def facility(:local0), do: 16 <<< 3
def facility(:local1), do: 17 <<< 3
def facility(:local2), do: 18 <<< 3
def facility(:local3), do: 19 <<< 3
def facility(:local4), do: 20 <<< 3
def facility(:local5), do: 21 <<< 3
def... | 25.757895 | 97 | 0.606253 |
330b73ffa31b7398672974764afaf583adcf9603 | 2,229 | ex | Elixir | apps/tai/lib/tai/test_support/mock.ex | CalebOts/tai | 1603bfefa390eac89085ba18fd259b2e9fcac6c0 | [
"MIT"
] | 1 | 2019-12-19T05:16:26.000Z | 2019-12-19T05:16:26.000Z | apps/tai/lib/tai/test_support/mock.ex | CalebOts/tai | 1603bfefa390eac89085ba18fd259b2e9fcac6c0 | [
"MIT"
] | null | null | null | apps/tai/lib/tai/test_support/mock.ex | CalebOts/tai | 1603bfefa390eac89085ba18fd259b2e9fcac6c0 | [
"MIT"
] | null | null | null | defmodule Tai.TestSupport.Mock do
@type location :: Tai.Markets.Location.t()
@type product :: Tai.Venues.Product.t()
@type fee_info :: Tai.Venues.FeeInfo.t()
@type venue_id :: Tai.Venues.Adapter.venue_id()
@type account_id :: Tai.Venues.Adapter.account_id()
@type asset :: Tai.Venues.AssetBalance.asset()
... | 27.182927 | 94 | 0.651862 |
330bd369fd614de2d917bf9e88513e60806e3aa1 | 7,601 | ex | Elixir | lib/virus_total.ex | FloatingGhost/virus_total_ex | e24a1910c88e4e8f805e97c033dc13c4ef12c3be | [
"MIT"
] | null | null | null | lib/virus_total.ex | FloatingGhost/virus_total_ex | e24a1910c88e4e8f805e97c033dc13c4ef12c3be | [
"MIT"
] | null | null | null | lib/virus_total.ex | FloatingGhost/virus_total_ex | e24a1910c88e4e8f805e97c033dc13c4ef12c3be | [
"MIT"
] | null | null | null | defmodule VirusTotal do
@moduledoc """
Documentation for VirusTotal.
Full API documentation can be found on the
[official site](https://www.virustotal.com/en/documentation/private-api)
As a note, this wrapper will convert HTTP-200 responses with a `response_code` of
0 to errors. Apparently VT considers to... | 32.622318 | 125 | 0.657677 |
330bf7ee0f50293f11c03d7fc0c03bd9523bb136 | 71 | exs | Elixir | test/vivid/rgba_test.exs | jamesotron/vivid | 01a0089384d8daced8f22a97c49e657fc245fb3c | [
"MIT"
] | 26 | 2017-01-03T01:18:38.000Z | 2019-02-21T09:26:20.000Z | test/vivid/rgba_test.exs | jamesotron/vivid | 01a0089384d8daced8f22a97c49e657fc245fb3c | [
"MIT"
] | null | null | null | test/vivid/rgba_test.exs | jamesotron/vivid | 01a0089384d8daced8f22a97c49e657fc245fb3c | [
"MIT"
] | 2 | 2017-03-18T22:45:49.000Z | 2017-05-08T07:24:58.000Z | defmodule Vivid.RGBATest do
use ExUnit.Case
doctest Vivid.RGBA
end
| 14.2 | 27 | 0.788732 |
330c1524949f9790d81413464b8e57892e1f97f2 | 112 | ex | Elixir | lib/ie_chat_bot/repo.ex | IE-bourgeois-union/ie_chat_bot | c0f155288170f558ff26bfc5cbd37f777c79a05b | [
"MIT"
] | null | null | null | lib/ie_chat_bot/repo.ex | IE-bourgeois-union/ie_chat_bot | c0f155288170f558ff26bfc5cbd37f777c79a05b | [
"MIT"
] | null | null | null | lib/ie_chat_bot/repo.ex | IE-bourgeois-union/ie_chat_bot | c0f155288170f558ff26bfc5cbd37f777c79a05b | [
"MIT"
] | null | null | null | defmodule IeChatBot.Repo do
use Ecto.Repo,
otp_app: :ie_chat_bot,
adapter: Ecto.Adapters.Postgres
end
| 18.666667 | 35 | 0.741071 |
330c1e5149ee8f1483a7bbcd6d8b08f51a8acbec | 18,709 | ex | Elixir | apps/ex_wire/lib/ex_wire/sync.ex | wolflee/mana | db66dac85addfaad98d40da5bd4082b3a0198bb1 | [
"ECL-2.0",
"Apache-2.0",
"MIT-0",
"MIT"
] | 152 | 2018-10-27T04:52:03.000Z | 2022-03-26T10:34:00.000Z | apps/ex_wire/lib/ex_wire/sync.ex | wolflee/mana | db66dac85addfaad98d40da5bd4082b3a0198bb1 | [
"ECL-2.0",
"Apache-2.0",
"MIT-0",
"MIT"
] | 270 | 2018-04-14T07:34:57.000Z | 2018-10-25T18:10:45.000Z | apps/ex_wire/lib/ex_wire/sync.ex | wolflee/mana | db66dac85addfaad98d40da5bd4082b3a0198bb1 | [
"ECL-2.0",
"Apache-2.0",
"MIT-0",
"MIT"
] | 25 | 2018-10-27T12:15:13.000Z | 2022-01-25T20:31:14.000Z | defmodule ExWire.Sync do
@moduledoc """
This is the heart of our syncing logic. Once we've connected to a number
of peers via `ExWire.PeerSupervisor`, we begin to ask for new blocks from
those peers. As we receive blocks, we add them to our
`ExWire.Struct.BlockQueue`.
If the blocks are confirmed by enough ... | 30.371753 | 97 | 0.655513 |
330c25d0981ee7cc7e5a4ca2a84f08eb0ca08b10 | 1,656 | exs | Elixir | test/level/tutorials_test.exs | mindriot101/level | 0a2cbae151869c2d9b79b3bfb388f5d00739ae12 | [
"Apache-2.0"
] | 928 | 2018-04-03T16:18:11.000Z | 2019-09-09T17:59:55.000Z | test/level/tutorials_test.exs | mindriot101/level | 0a2cbae151869c2d9b79b3bfb388f5d00739ae12 | [
"Apache-2.0"
] | 74 | 2018-04-03T00:46:50.000Z | 2019-03-10T18:57:27.000Z | test/level/tutorials_test.exs | mindriot101/level | 0a2cbae151869c2d9b79b3bfb388f5d00739ae12 | [
"Apache-2.0"
] | 89 | 2018-04-03T17:33:20.000Z | 2019-08-19T03:40:20.000Z | defmodule Level.TutorialsTest do
use Level.DataCase, async: true
alias Level.Tutorials
describe "update_current_step/3" do
test "records the step" do
{:ok, %{space_user: space_user}} = create_user_and_space()
{:ok, tutorial} = Tutorials.update_current_step(space_user, "foo", 3)
assert tuto... | 33.795918 | 76 | 0.676932 |
330c3857a08345fc33e97dfe31fe1ebfde5115e4 | 200 | exs | Elixir | test/dgraph_ex/client/adapters/http_test.exs | sunny-g/dgraph_ex | fab9f1fd684538758ed211537c3b0869233e7ce4 | [
"MIT"
] | 1 | 2019-05-01T15:18:41.000Z | 2019-05-01T15:18:41.000Z | test/dgraph_ex/client/adapters/http_test.exs | sunny-g/dgraph_ex | fab9f1fd684538758ed211537c3b0869233e7ce4 | [
"MIT"
] | null | null | null | test/dgraph_ex/client/adapters/http_test.exs | sunny-g/dgraph_ex | fab9f1fd684538758ed211537c3b0869233e7ce4 | [
"MIT"
] | 1 | 2019-05-01T15:18:48.000Z | 2019-05-01T15:18:48.000Z | defmodule DgraphEx.Client.Adapters.HTTP.UnitTest do
@moduledoc """
Tests the HTTP client's RESTful implementation details against a mocked
HTTPoison module (`TestHelpers.RequestMock`)
"""
end
| 28.571429 | 73 | 0.775 |
330c686d0015098a460200cd1faec4e1982138f9 | 271 | ex | Elixir | lib/cheerland_reservas.ex | fskinner/cheerland-reservas | 48a782d7e49736a89b4fd2136c98906269b6351e | [
"MIT"
] | 2 | 2019-03-14T20:03:44.000Z | 2019-08-30T13:30:42.000Z | lib/cheerland_reservas.ex | fskinner/cheerland-reservas | 48a782d7e49736a89b4fd2136c98906269b6351e | [
"MIT"
] | 1 | 2021-05-08T08:23:18.000Z | 2021-05-08T08:23:18.000Z | lib/cheerland_reservas.ex | fskinner/cheerland-reservas | 48a782d7e49736a89b4fd2136c98906269b6351e | [
"MIT"
] | null | null | null | defmodule CheerlandReservas do
@moduledoc """
CheerlandReservas 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
| 27.1 | 66 | 0.771218 |
330c74b2f0148ba7f1616dd297342536bb87fa46 | 1,581 | ex | Elixir | lib/game/values/tile_map.ex | Rabsztok/HexWorlds | 6d4b00824a6bf09ab84eca4efd14722cf3326616 | [
"MIT"
] | 7 | 2017-08-11T12:08:58.000Z | 2020-08-17T14:31:49.000Z | lib/game/values/tile_map.ex | Rabsztok/HexWorlds | 6d4b00824a6bf09ab84eca4efd14722cf3326616 | [
"MIT"
] | 1 | 2020-06-20T17:54:12.000Z | 2020-06-20T17:54:12.000Z | lib/game/values/tile_map.ex | Rabsztok/HexWorlds | 6d4b00824a6bf09ab84eca4efd14722cf3326616 | [
"MIT"
] | null | null | null | defmodule Game.TileMap do
alias Game.Region
defp generate({x, y, z}, dx, dy) do
size = Region.size()
tile = %{x: x + dx, y: y + dy, z: z - (dx + dy)}
cond do
dy < min(size, size - dx) ->
Map.put(
generate({x, y, z}, dx, dy + 1),
{tile.x, tile.y, tile.z},
til... | 21.657534 | 69 | 0.468058 |
330cbedd19389caa279d52c742bc4d7c2eb33a58 | 1,872 | exs | Elixir | mix.exs | Sebisnow/email_checker | b332fa83c5f20ce0b39c6b04fa481682a6a4aa35 | [
"MIT"
] | null | null | null | mix.exs | Sebisnow/email_checker | b332fa83c5f20ce0b39c6b04fa481682a6a4aa35 | [
"MIT"
] | null | null | null | mix.exs | Sebisnow/email_checker | b332fa83c5f20ce0b39c6b04fa481682a6a4aa35 | [
"MIT"
] | null | null | null | defmodule EmailChecker.Mixfile do
use Mix.Project
@version "0.1.3"
def project do
[
app: :email_checker,
version: @version,
elixir: "~> 1.3",
elixirc_paths: elixirc_paths(Mix.env()),
build_embedded: Mix.env() == :prod,
start_permanent: Mix.env() == :prod,
test_cover... | 24.311688 | 98 | 0.57906 |
330cbfcbb89b9ad56ad39010c06e05b5837fce44 | 9,098 | ex | Elixir | lib/phoenix/live_dashboard/components/table_component.ex | romkor/phoenix_live_dashboard | 66424a9367cf676f62c7c152b95da8931ad92a3f | [
"MIT"
] | null | null | null | lib/phoenix/live_dashboard/components/table_component.ex | romkor/phoenix_live_dashboard | 66424a9367cf676f62c7c152b95da8931ad92a3f | [
"MIT"
] | null | null | null | lib/phoenix/live_dashboard/components/table_component.ex | romkor/phoenix_live_dashboard | 66424a9367cf676f62c7c152b95da8931ad92a3f | [
"MIT"
] | null | null | null | defmodule Phoenix.LiveDashboard.TableComponent do
use Phoenix.LiveDashboard.Web, :live_component
@limit [50, 100, 500, 1000, 5000]
@type params() :: %{
limit: pos_integer(),
sort_by: :atom,
sort_dir: :desc | :asc,
search: binary(),
hint: binary() | nil
}... | 30.840678 | 164 | 0.569246 |
330cd27100b19d428df48984286ae7a100ade752 | 569 | exs | Elixir | mix.exs | elitau/module_dependency_visualizer | 7231f0f60fa2cddb048840e226fd990be2b51b1d | [
"MIT"
] | null | null | null | mix.exs | elitau/module_dependency_visualizer | 7231f0f60fa2cddb048840e226fd990be2b51b1d | [
"MIT"
] | null | null | null | mix.exs | elitau/module_dependency_visualizer | 7231f0f60fa2cddb048840e226fd990be2b51b1d | [
"MIT"
] | null | null | null | defmodule ModuleDependencyVisualizer.MixProject do
use Mix.Project
def project do
[
app: :module_dependency_visualizer,
version: "0.1.0",
elixir: "~> 1.6-dev",
start_permanent: Mix.env() == :prod,
deps: deps()
]
end
# Run "mix help compile.app" to learn about applications... | 19.62069 | 59 | 0.59051 |
330d33255dd3c85b33b0424b2299129962a55a7e | 254 | ex | Elixir | lib/kojin/sql/dql/result_column.ex | patefacio/kojin | 34f1959b7fa5fdc48e07ae6d81f8fa3ab31af982 | [
"MIT"
] | 3 | 2021-12-20T04:46:00.000Z | 2022-01-31T22:26:44.000Z | lib/kojin/sql/dql/result_column.ex | patefacio/kojin | 34f1959b7fa5fdc48e07ae6d81f8fa3ab31af982 | [
"MIT"
] | 1 | 2021-12-20T14:46:50.000Z | 2021-12-20T14:46:50.000Z | lib/kojin/sql/dql/result_column.ex | patefacio/kojin | 34f1959b7fa5fdc48e07ae6d81f8fa3ab31af982 | [
"MIT"
] | 1 | 2021-12-20T00:15:52.000Z | 2021-12-20T00:15:52.000Z | defmodule Kojin.Sql.Dql.ResultColumn do
use TypedStruct
typedstruct enforce: true do
field(:expr, binary)
field(:alias, binary)
field(:group, boolean)
field(:rollup, boolean)
end
def result_column(expr, opts \\ []) do
end
end
| 18.142857 | 40 | 0.681102 |
330d348051e6f0df38fd2637692a2b4495c6369b | 984 | ex | Elixir | lib/local_hex_web/plugs/auth_token_check.ex | imsoulfly/local_hex_repo | 18fca51c44b3dd01d27684877b3c7bc13471f548 | [
"Apache-2.0"
] | 5 | 2021-11-13T13:58:06.000Z | 2022-03-26T03:47:57.000Z | lib/local_hex_web/plugs/auth_token_check.ex | imsoulfly/local_hex_repo | 18fca51c44b3dd01d27684877b3c7bc13471f548 | [
"Apache-2.0"
] | 3 | 2021-11-16T18:45:45.000Z | 2021-12-05T13:58:25.000Z | lib/local_hex_web/plugs/auth_token_check.ex | imsoulfly/local_hex_repo | 18fca51c44b3dd01d27684877b3c7bc13471f548 | [
"Apache-2.0"
] | null | null | null | defmodule LocalHexWeb.Plugs.AuthTokenCheck do
@moduledoc """
The Hex API expects for each request to provide a valid authorization token in the `authorization` headers
that needs to match the configuration of the current system.
If validation fails the plugs will halt the request immediately and return a `401`... | 26.594595 | 108 | 0.704268 |
330d3f6da763eb3aa857640c89dc5d949e03f736 | 599 | ex | Elixir | lib/acl/graph_spec/constraint/resource/no_predicates.ex | Rahien/mu-authorization | 4535afd74ae3190d168bbebdf33cb40b919742f5 | [
"MIT"
] | null | null | null | lib/acl/graph_spec/constraint/resource/no_predicates.ex | Rahien/mu-authorization | 4535afd74ae3190d168bbebdf33cb40b919742f5 | [
"MIT"
] | null | null | null | lib/acl/graph_spec/constraint/resource/no_predicates.ex | Rahien/mu-authorization | 4535afd74ae3190d168bbebdf33cb40b919742f5 | [
"MIT"
] | null | null | null | alias Updates.QueryAnalyzer.Iri, as: Iri
defmodule Acl.GraphSpec.Constraint.Resource.NoPredicates do
defstruct [except: []]
@moduledoc """
This predicate matcher does not allow any predicates.
"""
defimpl Acl.GraphSpec.Constraint.Resource.PredicateMatchProtocol do
def member?( %Acl.GraphSpec.Constraint... | 31.526316 | 109 | 0.694491 |
330d60453069229e17500623bb7f4b06f481f754 | 261 | exs | Elixir | api_server/priv/repo/migrations/20161002195527_create_position.exs | Spippolo/wheredafuckRU | 4ff399532ab4847a390bfb0ce193ec5732c04595 | [
"MIT"
] | null | null | null | api_server/priv/repo/migrations/20161002195527_create_position.exs | Spippolo/wheredafuckRU | 4ff399532ab4847a390bfb0ce193ec5732c04595 | [
"MIT"
] | null | null | null | api_server/priv/repo/migrations/20161002195527_create_position.exs | Spippolo/wheredafuckRU | 4ff399532ab4847a390bfb0ce193ec5732c04595 | [
"MIT"
] | null | null | null | defmodule WheredafuckruApi.Repo.Migrations.CreatePosition do
use Ecto.Migration
def change do
create table(:positions) do
add :identifier, :string
add :latitude, :decimal
add :longitude, :decimal
timestamps()
end
end
end
| 18.642857 | 60 | 0.685824 |
330d66bbf3b79fc87530604880c1ad225177b4d0 | 668 | ex | Elixir | lib/game_of_life/chaos_monkey/process_picker.ex | rdk08/otp-game-of-life | 142740af57f9d49a05b1cf159fe00474956b696f | [
"MIT"
] | null | null | null | lib/game_of_life/chaos_monkey/process_picker.ex | rdk08/otp-game-of-life | 142740af57f9d49a05b1cf159fe00474956b696f | [
"MIT"
] | null | null | null | lib/game_of_life/chaos_monkey/process_picker.ex | rdk08/otp-game-of-life | 142740af57f9d49a05b1cf159fe00474956b696f | [
"MIT"
] | null | null | null | defmodule GameOfLife.ChaosMonkey.ProcessPicker do
alias GameOfLife.{Cell, Universe}
@spec random(list(atom)) :: {String.t(), pid}
def random(process_pool) do
name = get_name(process_pool)
pid = get_pid(name)
{format(name), pid}
end
defp get_name(process_pool) do
Enum.random(process_pool)
e... | 19.647059 | 49 | 0.639222 |
330d8ec6c5f98f925c1df1007fb2a58d2c98e4fd | 3,253 | exs | Elixir | test/api/workflow_definitions_test.exs | media-io/ex_step_flow | 07b6fe98399836679728547319c55137a1b5c933 | [
"MIT"
] | 4 | 2019-12-07T05:18:26.000Z | 2020-11-06T23:28:43.000Z | test/api/workflow_definitions_test.exs | media-io/ex_step_flow | 07b6fe98399836679728547319c55137a1b5c933 | [
"MIT"
] | 53 | 2020-01-06T11:23:09.000Z | 2021-06-25T15:30:07.000Z | test/api/workflow_definitions_test.exs | media-io/ex_step_flow | 07b6fe98399836679728547319c55137a1b5c933 | [
"MIT"
] | 3 | 2020-01-30T15:37:40.000Z | 2020-10-27T14:10:02.000Z | defmodule StepFlow.Api.WorkflowDefinitionsTest do
use ExUnit.Case
use Plug.Test
alias Ecto.Adapters.SQL.Sandbox
alias StepFlow.Router
doctest StepFlow
@opts Router.init([])
setup do
# Explicitly get a connection before each test
:ok = Sandbox.checkout(StepFlow.Repo)
# Setting the shared mod... | 27.803419 | 93 | 0.565939 |
330dc118bc51200873fadc848b970d0331fcc501 | 375 | ex | Elixir | testData/org/elixir_lang/parser_definition/matched_qualified_call_operation_parsing_test_case/Alias.ex | keyno63/intellij-elixir | 4033e319992c53ddd42a683ee7123a97b5e34f02 | [
"Apache-2.0"
] | 1,668 | 2015-01-03T05:54:27.000Z | 2022-03-25T08:01:20.000Z | testData/org/elixir_lang/parser_definition/matched_qualified_call_operation_parsing_test_case/Alias.ex | keyno63/intellij-elixir | 4033e319992c53ddd42a683ee7123a97b5e34f02 | [
"Apache-2.0"
] | 2,018 | 2015-01-01T22:43:39.000Z | 2022-03-31T20:13:08.000Z | testData/org/elixir_lang/parser_definition/matched_qualified_call_operation_parsing_test_case/Alias.ex | keyno63/intellij-elixir | 4033e319992c53ddd42a683ee7123a97b5e34f02 | [
"Apache-2.0"
] | 145 | 2015-01-15T11:37:16.000Z | 2021-12-22T05:51:02.000Z | Alias.relative_identifier(
positional,
key: value
)
Alias.relative_identifier(
inner_postional,
key: inner_value
)(
outer_positional,
key: outer_value
)
Alias.relative_identifier key: value
Alias.relative_identifier unqualified positional,
key: value
ALias.relative_iden... | 23.4375 | 49 | 0.672 |
330dc20bf1d49ec622a618558b0fa978fa3e5109 | 1,026 | ex | Elixir | lib/cforum/release.ex | MatthiasApsel/cforum_ex | 52c621a583182d82692b74694b0b2792ac23b8ff | [
"MIT"
] | null | null | null | lib/cforum/release.ex | MatthiasApsel/cforum_ex | 52c621a583182d82692b74694b0b2792ac23b8ff | [
"MIT"
] | null | null | null | lib/cforum/release.ex | MatthiasApsel/cforum_ex | 52c621a583182d82692b74694b0b2792ac23b8ff | [
"MIT"
] | null | null | null | defmodule Cforum.Release do
require Logger
def create do
for repo <- repos() do
case repo.__adapter__.storage_up(repo.config) do
:ok ->
Logger.info("The database for #{inspect(repo)} has been created")
{:error, :already_up} ->
Logger.info("The database for #{inspect(r... | 27.72973 | 97 | 0.616959 |
330dcff91f5ee6f19a37a0b682f1ad56088b199d | 102 | exs | Elixir | books/chat/config/dev.exs | idfumg/ElixirSynopsis | 74c668d84300812dd41eb18772aecfb89bc7628b | [
"MIT"
] | null | null | null | books/chat/config/dev.exs | idfumg/ElixirSynopsis | 74c668d84300812dd41eb18772aecfb89bc7628b | [
"MIT"
] | null | null | null | books/chat/config/dev.exs | idfumg/ElixirSynopsis | 74c668d84300812dd41eb18772aecfb89bc7628b | [
"MIT"
] | null | null | null | use Mix.Config
config :chat, remote_supervisor: fn(recipient) -> {Chat.TaskSupervisor, recipient} end
| 34 | 86 | 0.784314 |
330de46971c07612b38993fbc6f2ed69409b57b9 | 9,318 | ex | Elixir | lib/mix/tasks/temple.gen.html.ex | rktjmp/temple | 6fe46cbb4998477d76147fa95c9fd9c7841545ef | [
"MIT"
] | 366 | 2019-07-12T22:43:35.000Z | 2022-03-31T07:26:25.000Z | lib/mix/tasks/temple.gen.html.ex | rktjmp/temple | 6fe46cbb4998477d76147fa95c9fd9c7841545ef | [
"MIT"
] | 114 | 2019-07-12T19:49:10.000Z | 2022-03-23T10:48:48.000Z | lib/mix/tasks/temple.gen.html.ex | rktjmp/temple | 6fe46cbb4998477d76147fa95c9fd9c7841545ef | [
"MIT"
] | 17 | 2019-07-23T15:16:34.000Z | 2021-02-25T02:42:02.000Z | if Code.ensure_loaded?(Mix.Phoenix) do
defmodule Mix.Tasks.Temple.Gen.Html do
@shortdoc "Generates controller, views, and context for an HTML resource in Temple"
@moduledoc """
Generates controller, views, and context for an HTML resource in Temple.
mix temple.gen.html Accounts User users name:s... | 35.295455 | 98 | 0.641769 |
330de6454449e1792465256d09376ca4ddc02489 | 2,328 | ex | Elixir | lib/advent/y2021/d14.ex | ed-flanagan/advent-of-code-solutions-elixir | ca4b62f82088e7a120699fbba9809c04c76403a6 | [
"MIT"
] | null | null | null | lib/advent/y2021/d14.ex | ed-flanagan/advent-of-code-solutions-elixir | ca4b62f82088e7a120699fbba9809c04c76403a6 | [
"MIT"
] | null | null | null | lib/advent/y2021/d14.ex | ed-flanagan/advent-of-code-solutions-elixir | ca4b62f82088e7a120699fbba9809c04c76403a6 | [
"MIT"
] | null | null | null | defmodule Advent.Y2021.D14 do
@moduledoc """
https://adventofcode.com/2021/day/14
"""
@typep rules :: %{charlist() => {charlist(), charlist()}}
@doc """
Apply 10 steps of pair insertion to the polymer template and find the most
and least common elements in the result. What do you get if you take the
q... | 28.390244 | 76 | 0.573024 |
330df9da37817046094a4dc78a1455651b2911cc | 14,988 | ex | Elixir | lib/ecto/adapters/postgres.ex | yrashk/ecto | 1462d5ad4cbb7bf74c292ec405852bc196808daf | [
"Apache-2.0"
] | 1 | 2016-08-15T21:23:28.000Z | 2016-08-15T21:23:28.000Z | lib/ecto/adapters/postgres.ex | yrashk/ecto | 1462d5ad4cbb7bf74c292ec405852bc196808daf | [
"Apache-2.0"
] | null | null | null | lib/ecto/adapters/postgres.ex | yrashk/ecto | 1462d5ad4cbb7bf74c292ec405852bc196808daf | [
"Apache-2.0"
] | null | null | null | if Code.ensure_loaded?(Postgrex.Connection) do
defmodule Ecto.Adapters.Postgres do
@moduledoc """
This is the adapter module for PostgreSQL. It handles and pools the
connections to the postgres database with poolboy.
## Options
The options should be given via `Ecto.Repo.conf/0`.
`:hostname`... | 28.067416 | 111 | 0.599413 |
330e12e8469795750f0e0a879f22b79de3be0492 | 930 | ex | Elixir | lib/anchore_engine_api_server/model/service.ex | michaeljguarino/anchore-elixir-client | 156a44f429ecb62433729a2b4c52de5dc0ef44d2 | [
"MIT"
] | null | null | null | lib/anchore_engine_api_server/model/service.ex | michaeljguarino/anchore-elixir-client | 156a44f429ecb62433729a2b4c52de5dc0ef44d2 | [
"MIT"
] | null | null | null | lib/anchore_engine_api_server/model/service.ex | michaeljguarino/anchore-elixir-client | 156a44f429ecb62433729a2b4c52de5dc0ef44d2 | [
"MIT"
] | 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 AnchoreEngineAPIServer.Model.Service do
@moduledoc """
A service status record
"""
@derive [Poison.Encoder]
defstruct [
:base_url,
... | 23.25 | 98 | 0.694624 |
330e5ae4eb7934b353d8496833beb98ce8636637 | 2,190 | ex | Elixir | lib/sbom_poc_web/controllers/user_settings_controller.ex | TraceyOnim/SbomPoc-sFractal | bac895a7eda61c47c00b8bbe682a6fda4dd7255c | [
"MIT"
] | 2 | 2020-10-04T12:41:58.000Z | 2021-03-11T20:51:26.000Z | lib/sbom_poc_web/controllers/user_settings_controller.ex | TraceyOnim/SbomPoc-sFractal | bac895a7eda61c47c00b8bbe682a6fda4dd7255c | [
"MIT"
] | 113 | 2020-07-25T02:29:33.000Z | 2022-03-01T01:07:23.000Z | lib/sbom_poc_web/controllers/user_settings_controller.ex | TraceyOnim/SbomPoc-sFractal | bac895a7eda61c47c00b8bbe682a6fda4dd7255c | [
"MIT"
] | 5 | 2020-07-10T09:57:58.000Z | 2021-03-11T20:51:29.000Z | defmodule SbomPocWeb.UserSettingsController do
use SbomPocWeb, :controller
alias SbomPoc.Accounts
alias SbomPocWeb.UserAuth
plug :assign_email_and_password_changesets
def edit(conn, _params) do
render(conn, "edit.html")
end
def update_email(conn, %{"current_password" => password, "user" => user_pa... | 30 | 88 | 0.659361 |
330e8560aaad3c30090cff18efa9fb70b18aaa71 | 2,169 | ex | Elixir | lib/egndf/api/base.ex | Nebo15/egndf | e55f3800e1f51dea82978b057886b46acae5ad04 | [
"MIT"
] | 1 | 2016-12-08T12:59:07.000Z | 2016-12-08T12:59:07.000Z | lib/egndf/api/base.ex | Nebo15/egndf | e55f3800e1f51dea82978b057886b46acae5ad04 | [
"MIT"
] | 1 | 2016-09-05T15:45:43.000Z | 2016-12-08T12:55:14.000Z | lib/egndf/api/base.ex | Nebo15/egndf | e55f3800e1f51dea82978b057886b46acae5ad04 | [
"MIT"
] | 2 | 2017-12-21T12:39:17.000Z | 2020-02-23T20:27:28.000Z | defmodule Egndf.Api.Base do
@moduledoc """
Basic module for API requests
"""
use Confex, otp_app: :egndf
use HTTPoison.Base
def send_get(path) do
path
|> get_uri
|> get(get_req_headers!)
|> normalize_resp
|> decode_request_body
end
def send_post(values, path) when is_map(values) do... | 22.360825 | 80 | 0.600277 |
330e929de15403bd99a6df9172881e8287fe4500 | 1,319 | ex | Elixir | web/models/user.ex | daraclare/phoenix-trello | 98ba9b776047c3b2ea8bd2c327a2c06324b9e2e4 | [
"MIT"
] | 1 | 2020-07-24T17:13:26.000Z | 2020-07-24T17:13:26.000Z | web/models/user.ex | daraclare/phoenix-trello | 98ba9b776047c3b2ea8bd2c327a2c06324b9e2e4 | [
"MIT"
] | null | null | null | web/models/user.ex | daraclare/phoenix-trello | 98ba9b776047c3b2ea8bd2c327a2c06324b9e2e4 | [
"MIT"
] | null | null | null | defmodule PhoenixTrello.User do
use PhoenixTrello.Web, :model
@derive {Poison.Encoder, only: [:id, :first_name, :last_name, :email]}
schema "users" do
field :first_name, :string
field :last_name, :string
field :email, :string
field :encrypted_password, :string
field :password, :string, virtu... | 29.311111 | 98 | 0.697498 |
330ea61091144f556922b2bdfb38eeb261c5301a | 2,171 | ex | Elixir | lib/slack/web/web.ex | albert-io/Elixir-Slack | 830fcbf1b260b8fc014de33ba9e4cdf273c88e98 | [
"MIT"
] | null | null | null | lib/slack/web/web.ex | albert-io/Elixir-Slack | 830fcbf1b260b8fc014de33ba9e4cdf273c88e98 | [
"MIT"
] | null | null | null | lib/slack/web/web.ex | albert-io/Elixir-Slack | 830fcbf1b260b8fc014de33ba9e4cdf273c88e98 | [
"MIT"
] | null | null | null | defmodule Slack.Web do
@moduledoc false
def get_documentation do
File.ls!("#{__DIR__}/docs")
|> format_documentation
end
defp format_documentation(files) do
Enum.reduce(files, %{}, fn(file, module_names) ->
json =
File.read!("#{__DIR__}/docs/#{file}")
|> Poison.Parser.parse!(... | 28.565789 | 93 | 0.625518 |
330ed314c1a13cca63b1b114928e760f733c17c3 | 353 | exs | Elixir | priv/repo/migrations/20200816212316_create_product.exs | Wobblesday/JIT-Jerky | b60c52ee76cf9ae4836ee99f3deccda72fccc656 | [
"Apache-2.0"
] | null | null | null | priv/repo/migrations/20200816212316_create_product.exs | Wobblesday/JIT-Jerky | b60c52ee76cf9ae4836ee99f3deccda72fccc656 | [
"Apache-2.0"
] | null | null | null | priv/repo/migrations/20200816212316_create_product.exs | Wobblesday/JIT-Jerky | b60c52ee76cf9ae4836ee99f3deccda72fccc656 | [
"Apache-2.0"
] | null | null | null | defmodule JITJerky.Repo.Migrations.CreateProduct do
use Ecto.Migration
def change do
create table(:product) do
add :name, :string
add :price, :decimal
add :sku, :string
add :opaque_id, :uuid
timestamps()
end
create unique_index(:product, [:sku])
create unique_index(:... | 19.611111 | 51 | 0.651558 |
330ed7f16c4554dd88af7dbb16e696dbcc7d3710 | 453 | ex | Elixir | lib/forge_sdk/wallet/type/validator.ex | ArcBlock/forge-elixir-sdk | 61ff656a59116d3da18055d54655e8eb5ca15f63 | [
"Apache-2.0"
] | 21 | 2019-05-08T01:25:42.000Z | 2022-02-08T02:30:18.000Z | lib/forge_sdk/wallet/type/validator.ex | ArcBlock/forge-elixir-sdk | 61ff656a59116d3da18055d54655e8eb5ca15f63 | [
"Apache-2.0"
] | 6 | 2019-05-27T23:07:00.000Z | 2020-03-10T04:33:10.000Z | lib/forge_sdk/wallet/type/validator.ex | ArcBlock/forge-elixir-sdk | 61ff656a59116d3da18055d54655e8eb5ca15f63 | [
"Apache-2.0"
] | 2 | 2019-07-21T18:12:47.000Z | 2021-07-31T21:18:38.000Z | defmodule ForgeSdk.Wallet.Type.Validator do
@moduledoc """
Wallet type for validator
"""
use TypedStruct
typedstruct do
field :pk, atom(), default: :ed25519
field :hash, atom(), default: :sha2
field :address, atom(), default: :base58
field :role, atom(), default: :role_validator
end
end
de... | 25.166667 | 66 | 0.715232 |
330edbdb3cb06f76cff415a7b434eebcb4cc230c | 536 | ex | Elixir | lib/shenu/schema.ex | jsdelivrbot/shenu | 98acf65b915b62528eccd824020e8007931ee01c | [
"MIT"
] | 3 | 2016-06-19T00:21:54.000Z | 2021-09-28T22:04:07.000Z | lib/shenu/schema.ex | jsdelivrbot/shenu | 98acf65b915b62528eccd824020e8007931ee01c | [
"MIT"
] | null | null | null | lib/shenu/schema.ex | jsdelivrbot/shenu | 98acf65b915b62528eccd824020e8007931ee01c | [
"MIT"
] | 1 | 2018-12-06T22:51:26.000Z | 2018-12-06T22:51:26.000Z | defmodule Shenu.Schema do
defmodule InputError do
defexception [:message, :path]
end
def init(schema) do
ExJsonSchema.Schema.resolve(schema)
end
def validate(schema, value) do
case ExJsonSchema.Validator.validate(schema, value) do
:ok ->
:ok
{:error, errors} ->
{:erro... | 22.333333 | 64 | 0.662313 |
330ee47226ca0ed214b600c71ea3fdc5ed13e982 | 2,220 | exs | Elixir | test/hexa_web/controllers/github_callbacks_test.exs | libreearth/hexa | 81938c3a5abc710eb16055d73c43cbf60dbf487e | [
"MIT"
] | null | null | null | test/hexa_web/controllers/github_callbacks_test.exs | libreearth/hexa | 81938c3a5abc710eb16055d73c43cbf60dbf487e | [
"MIT"
] | null | null | null | test/hexa_web/controllers/github_callbacks_test.exs | libreearth/hexa | 81938c3a5abc710eb16055d73c43cbf60dbf487e | [
"MIT"
] | null | null | null | defmodule HexaWeb.GithubCallbackTest do
use HexaWeb.ConnCase, async: true
alias Hexa.Accounts
def exchange_access_token(opts) do
_code = opts[:code]
state = opts[:state]
case state do
"valid" ->
{:ok,
%{
info: %{
"login" => "chrismccord",
... | 28.831169 | 96 | 0.590541 |
330f1d6f7a0f7def13fd2e33eb9fe736b6bf71b9 | 930 | ex | Elixir | backend/test/support/channel_case.ex | eeng/caffe | d85d0dd56a8204c715052ddaf3d990e47c5df0e9 | [
"MIT"
] | 7 | 2020-03-27T08:26:52.000Z | 2021-08-29T09:50:31.000Z | backend/test/support/channel_case.ex | eeng/caffe | d85d0dd56a8204c715052ddaf3d990e47c5df0e9 | [
"MIT"
] | null | null | null | backend/test/support/channel_case.ex | eeng/caffe | d85d0dd56a8204c715052ddaf3d990e47c5df0e9 | [
"MIT"
] | null | null | null | defmodule CaffeWeb.ChannelCase do
@moduledoc """
This module defines the test case to be used by
channel tests.
Such tests rely on `Phoenix.ChannelTest` and also
import other functionality to make it easier
to build common data structures and query the data layer.
Finally, if the test case interacts wit... | 24.473684 | 67 | 0.712903 |
330f2324ae1824d3a5e247e3cd3dc3ef04a04867 | 1,953 | exs | Elixir | mix.exs | infinitered/phoenix_base | 8c8ddd63ff1412f9f90cbe7cf24278618bcb2e11 | [
"MIT"
] | 71 | 2016-01-07T18:36:47.000Z | 2021-02-26T00:21:58.000Z | mix.exs | infinitered/phoenix_base | 8c8ddd63ff1412f9f90cbe7cf24278618bcb2e11 | [
"MIT"
] | 15 | 2016-01-15T17:48:07.000Z | 2017-07-18T16:00:03.000Z | mix.exs | infinitered/phoenix_base | 8c8ddd63ff1412f9f90cbe7cf24278618bcb2e11 | [
"MIT"
] | 22 | 2016-02-02T23:49:21.000Z | 2019-08-08T12:53:49.000Z | defmodule PhoenixBase.Mixfile do
use Mix.Project
def project do
[app: :phoenix_base,
version: "0.0.1",
elixir: "~> 1.0",
elixirc_paths: elixirc_paths(Mix.env),
compilers: [:phoenix, :gettext] ++ Mix.compilers,
build_embedded: Mix.env == :prod,
start_permanent: Mix.env == :prod,
... | 32.016393 | 109 | 0.58679 |
330f783cf65d4b458e1380acb33c5db948f31e6b | 1,556 | exs | Elixir | test/drab/core_test.exs | Gamecode-HQ/drab | dfbe73c0675831f42829f0f3f7fe12d47a78badc | [
"MIT"
] | 933 | 2017-01-14T13:47:37.000Z | 2022-03-21T18:14:41.000Z | test/drab/core_test.exs | Gamecode-HQ/drab | dfbe73c0675831f42829f0f3f7fe12d47a78badc | [
"MIT"
] | 189 | 2017-01-15T18:35:06.000Z | 2022-01-24T17:41:22.000Z | test/drab/core_test.exs | Gamecode-HQ/drab | dfbe73c0675831f42829f0f3f7fe12d47a78badc | [
"MIT"
] | 54 | 2017-01-15T18:10:48.000Z | 2021-02-06T17:21:44.000Z | defmodule Drab.CoreTest do
import Drab.Core
use ExUnit.Case, async: true
doctest Drab.Core, only: [same_path: 1, same_controller: 1, same_topic: 1]
test "this/1 should return drab_id" do
dom_sender = %{"drab_id" => "DRAB_ID"}
assert Drab.Core.this(dom_sender) == "[drab-id=\"DRAB_ID\"]"
end
test "... | 30.509804 | 90 | 0.51671 |
330fad28d985b9dbc81f8d537dd3c12b852a61a8 | 1,121 | exs | Elixir | config/config.exs | milmazz/lang_tags | 4162648cb36957bc301c12434b0c82029e483885 | [
"Apache-2.0"
] | null | null | null | config/config.exs | milmazz/lang_tags | 4162648cb36957bc301c12434b0c82029e483885 | [
"Apache-2.0"
] | null | null | null | config/config.exs | milmazz/lang_tags | 4162648cb36957bc301c12434b0c82029e483885 | [
"Apache-2.0"
] | 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.16129 | 73 | 0.752007 |
330faf3226d9ea9da886f048045d18b85788eb33 | 1,070 | ex | Elixir | lib/humiex/client.ex | blockfi/humiex | dd3c2a6e34df4a90ff14d64cf1445f998ede6517 | [
"MIT"
] | 2 | 2020-11-17T15:25:48.000Z | 2021-02-05T16:51:26.000Z | lib/humiex/client.ex | blockfi/humiex | dd3c2a6e34df4a90ff14d64cf1445f998ede6517 | [
"MIT"
] | 1 | 2020-10-28T15:27:53.000Z | 2020-11-23T20:41:45.000Z | lib/humiex/client.ex | blockfi/humiex | dd3c2a6e34df4a90ff14d64cf1445f998ede6517 | [
"MIT"
] | null | null | null | defmodule Humiex.Client do
@moduledoc """
Humiex Client configuration
Stores the url, repo and token needed to use the Search API
"""
alias Humiex.Client.HTTPClient
defstruct [:url, :repo, :token, :headers, :http_client, :opts]
@type header() :: {String.t(), String.t()}
@type token() :: String.t()
... | 24.318182 | 76 | 0.57757 |
330fb2c0d2eb927226fefe7e3f6055ee09b5631c | 1,744 | ex | Elixir | lib/ash/resource/transformers/create_join_relationship.ex | MrFlorius/ash | 247abbb8333d252da5440a58ddf4f1b7f184342f | [
"MIT"
] | null | null | null | lib/ash/resource/transformers/create_join_relationship.ex | MrFlorius/ash | 247abbb8333d252da5440a58ddf4f1b7f184342f | [
"MIT"
] | null | null | null | lib/ash/resource/transformers/create_join_relationship.ex | MrFlorius/ash | 247abbb8333d252da5440a58ddf4f1b7f184342f | [
"MIT"
] | null | null | null | defmodule Ash.Resource.Transformers.CreateJoinRelationship do
@moduledoc """
Creates an automatically named `has_many` relationship for each many_to_many.
This will likely not be around for long, as our logic around many to many relationships
will update soon.
"""
use Ash.Dsl.Transformer
alias Ash.Dsl.T... | 29.559322 | 89 | 0.65367 |
330ff9d350f7ba30afa037a3f726d73e2d76e298 | 1,790 | ex | Elixir | lib/ex_stone_openbank/authenticator/http_middleware.ex | polvalente/ex-stone-openbank | f60720abbf755ebf7824fe0de435e47e8cc5c3f5 | [
"Apache-2.0"
] | null | null | null | lib/ex_stone_openbank/authenticator/http_middleware.ex | polvalente/ex-stone-openbank | f60720abbf755ebf7824fe0de435e47e8cc5c3f5 | [
"Apache-2.0"
] | null | null | null | lib/ex_stone_openbank/authenticator/http_middleware.ex | polvalente/ex-stone-openbank | f60720abbf755ebf7824fe0de435e47e8cc5c3f5 | [
"Apache-2.0"
] | null | null | null | defmodule ExStoneOpenbank.Authenticator.AuthHTTPMiddleware do
@moduledoc """
A Tesla Middleware that ensures we always have a valid access_token.
This middleware implementation has a retryable approach. It tries the call with the current token
available. It might get a 401 at first and so, it calls for a refre... | 34.423077 | 99 | 0.686592 |
3310551b7c9d9cdfa55c8a1e46d371e5e4396942 | 323 | ex | Elixir | lib/codes/codes_b92.ex | badubizzle/icd_code | 4c625733f92b7b1d616e272abc3009bb8b916c0c | [
"Apache-2.0"
] | null | null | null | lib/codes/codes_b92.ex | badubizzle/icd_code | 4c625733f92b7b1d616e272abc3009bb8b916c0c | [
"Apache-2.0"
] | null | null | null | lib/codes/codes_b92.ex | badubizzle/icd_code | 4c625733f92b7b1d616e272abc3009bb8b916c0c | [
"Apache-2.0"
] | null | null | null | defmodule IcdCode.ICDCode.Codes_B92 do
alias IcdCode.ICDCode
def _B92 do
%ICDCode{full_code: "B92",
category_code: "B92",
short_code: "",
full_name: "Sequelae of leprosy",
short_name: "Sequelae of leprosy",
category_name: "Sequelae of leprosy"
}
end
e... | 20.1875 | 46 | 0.606811 |
331074720885e7372b33d325aa4561949452bbbf | 9,311 | exs | Elixir | test/graphvix/graph_test.exs | futpib/graphvix | 9f78c7f4dddd101ac315085bc520c3d282057f27 | [
"MIT"
] | null | null | null | test/graphvix/graph_test.exs | futpib/graphvix | 9f78c7f4dddd101ac315085bc520c3d282057f27 | [
"MIT"
] | null | null | null | test/graphvix/graph_test.exs | futpib/graphvix | 9f78c7f4dddd101ac315085bc520c3d282057f27 | [
"MIT"
] | null | null | null | defmodule Graphvix.GraphTest do
use ExUnit.Case, async: true
use ExUnitProperties
alias Graphvix.{Graph, HTMLRecord, Record}
doctest Graph, except: [
new: 1, digraph_tables: 1, to_dot: 1, write: 2, compile: 3, show: 2,
set_global_properties: 3
]
import HTMLRecord, only: [tr: 1, td: 1, td: 2]
pro... | 25.30163 | 111 | 0.554935 |
33107da3cf00694e3d6aea4565a0a292d15f9a9d | 81 | ex | Elixir | lib/command_handler/read_channel.ex | jonasrichard/iris | eb4547ced7f7ff9305a4edfa1c32e8d45fa2aa00 | [
"Apache-2.0"
] | 1 | 2017-03-31T09:26:21.000Z | 2017-03-31T09:26:21.000Z | lib/command_handler/read_channel.ex | jonasrichard/iris | eb4547ced7f7ff9305a4edfa1c32e8d45fa2aa00 | [
"Apache-2.0"
] | 1 | 2017-05-03T06:30:09.000Z | 2017-05-03T06:30:09.000Z | lib/command_handler/read_channel.ex | jonasrichard/iris | eb4547ced7f7ff9305a4edfa1c32e8d45fa2aa00 | [
"Apache-2.0"
] | null | null | null | defmodule Iris.CommandHandler.ReadChannel do
def handle(_command) do
end
end
| 16.2 | 44 | 0.802469 |
3310cab7dbb4013db1fdd53c4ad9046fa7bd2151 | 9,150 | exs | Elixir | test/client_test.exs | Schultzer/hawk | 2ce277ebc24d3554031e1c44cc6af2ce40bca738 | [
"MIT",
"Unlicense"
] | null | null | null | test/client_test.exs | Schultzer/hawk | 2ce277ebc24d3554031e1c44cc6af2ce40bca738 | [
"MIT",
"Unlicense"
] | null | null | null | test/client_test.exs | Schultzer/hawk | 2ce277ebc24d3554031e1c44cc6af2ce40bca738 | [
"MIT",
"Unlicense"
] | null | null | null | defmodule HawkClientTest do
use ExUnit.Case
alias Hawk.{Client, Crypto, Now}
describe "header/3" do
test "returns a valid authorization header (sha1)" do
credentials = %{id: "123456", key: "2983d45yun89q", algorithm: :sha}
%{header: header} = Client.header("http://example.net/somewhere/over/the/r... | 67.777778 | 302 | 0.709727 |
3310edefc725f3fccb0921d14092d50777960f55 | 150 | exs | Elixir | test/test_helper.exs | castingclouds/rc4gho | fdbd6665aa233370c857d63b1d6a22459e1833ce | [
"MIT"
] | null | null | null | test/test_helper.exs | castingclouds/rc4gho | fdbd6665aa233370c857d63b1d6a22459e1833ce | [
"MIT"
] | null | null | null | test/test_helper.exs | castingclouds/rc4gho | fdbd6665aa233370c857d63b1d6a22459e1833ce | [
"MIT"
] | null | null | null | ExUnit.start
Mix.Task.run "ecto.create", ["--quiet"]
Mix.Task.run "ecto.migrate", ["--quiet"]
Ecto.Adapters.SQL.begin_test_transaction(Rocket.Repo)
| 21.428571 | 53 | 0.726667 |
3311063b48bb1303d05f7934792ad2e8fb0c7be7 | 823 | ex | Elixir | lib/exvcr/adapter/hackney/store.ex | edwardzhou/exvcr | 0d1e0ab702c9caca74bcbbe4dd7f4894cb8816cd | [
"MIT"
] | 608 | 2015-01-05T18:44:49.000Z | 2022-03-21T19:54:01.000Z | lib/exvcr/adapter/hackney/store.ex | edwardzhou/exvcr | 0d1e0ab702c9caca74bcbbe4dd7f4894cb8816cd | [
"MIT"
] | 165 | 2015-01-04T13:01:01.000Z | 2022-03-16T08:31:48.000Z | lib/exvcr/adapter/hackney/store.ex | edwardzhou/exvcr | 0d1e0ab702c9caca74bcbbe4dd7f4894cb8816cd | [
"MIT"
] | 130 | 2015-01-28T19:33:21.000Z | 2022-02-08T22:21:43.000Z | defmodule ExVCR.Adapter.Hackney.Store do
@moduledoc """
Provides a datastore for temporary saving client key (Reference) and body relationship.
"""
@doc """
Initialize the datastore.
"""
def start do
if :ets.info(table()) == :undefined do
:ets.new(table(), [:set, :public, :named_table])
end... | 18.288889 | 89 | 0.594168 |
331109d915f70bd919111ec30e41e0be445a3a98 | 550 | ex | Elixir | lib/country.ex | aenglisc/countries | db8c730fd6b84bf09bc8103a56ec06cd512e7c20 | [
"MIT"
] | null | null | null | lib/country.ex | aenglisc/countries | db8c730fd6b84bf09bc8103a56ec06cd512e7c20 | [
"MIT"
] | null | null | null | lib/country.ex | aenglisc/countries | db8c730fd6b84bf09bc8103a56ec06cd512e7c20 | [
"MIT"
] | null | null | null | defmodule Countries.Country do
defstruct [:number, :alpha2, :alpha3, :currency, :name, :unofficial_names,
:continent, :region, :subregion, :geo,
:world_region, :country_code, :national_destination_code_lengths,
:national_number_lengths, :international_prefix, :national_prefix,
... | 55 | 89 | 0.689091 |
331131759e8dad5bdb1749188e1d402e8779ce63 | 1,581 | ex | Elixir | year_2021/lib/day_09.ex | bschmeck/advent_of_code | cbec98019c6c00444e0f4c7e15e01b1ed9ae6145 | [
"MIT"
] | null | null | null | year_2021/lib/day_09.ex | bschmeck/advent_of_code | cbec98019c6c00444e0f4c7e15e01b1ed9ae6145 | [
"MIT"
] | null | null | null | year_2021/lib/day_09.ex | bschmeck/advent_of_code | cbec98019c6c00444e0f4c7e15e01b1ed9ae6145 | [
"MIT"
] | null | null | null | defmodule Day09 do
def part_one(input) do
map = map(input)
map
|> Enum.filter(fn {pos, value} -> lowest?(pos, value, map) end)
|> Enum.map(fn {_pos, value} -> value + 1 end)
|> Enum.reduce(&Kernel.+/2)
end
def part_two(input) do
map = map(input)
map
|> Enum.filter(fn {pos, value... | 25.918033 | 89 | 0.542062 |
331133877afba6201055705d8e6f4c4b2c41bf3c | 8,757 | ex | Elixir | gherkin/elixir/lib/gherkin/token_matcher.ex | endersstocker/cucumber | 5ad94a9ab5f87bca6ee23a6b4212705cdc58753d | [
"MIT"
] | null | null | null | gherkin/elixir/lib/gherkin/token_matcher.ex | endersstocker/cucumber | 5ad94a9ab5f87bca6ee23a6b4212705cdc58753d | [
"MIT"
] | null | null | null | gherkin/elixir/lib/gherkin/token_matcher.ex | endersstocker/cucumber | 5ad94a9ab5f87bca6ee23a6b4212705cdc58753d | [
"MIT"
] | null | null | null | defmodule Gherkin.TokenMatcher do
alias Gherkin.{Dialect, GherkinLine, Location, NoSuchLanguageError, Token}
@type on_match :: {:ok, Token.t(), t} | :error
@type t :: %__MODULE__{
active_doc_string_separator: <<_::24>> | nil,
default_language: String.t(),
dialect: Dialect.t(),
... | 33.296578 | 99 | 0.621902 |
331163c45e0734f1a47429990337fee970a004cf | 5,625 | ex | Elixir | DL-AC/DL-AC (NO2_WE_0=256,NO2_S=0.256,NO2_AUX_0=227,NO_WE_0=320,NO_S=0.512,NO_AUX_0=288,Ox_WE_0=235,Ox_S=0.345,Ox_AUX_0=200,CO_WE_0=544,CO_S=0.424,CO_AUX_0=301).ELEMENT-IoT.ex | Realscrat/decentlab-decoders | 3ca5006cd85e3772a15a1b3fff3922c50979eeb6 | [
"MIT"
] | 13 | 2020-01-18T22:08:44.000Z | 2022-02-06T14:19:57.000Z | DL-AC/DL-AC (NO2_WE_0=256,NO2_S=0.256,NO2_AUX_0=227,NO_WE_0=320,NO_S=0.512,NO_AUX_0=288,Ox_WE_0=235,Ox_S=0.345,Ox_AUX_0=200,CO_WE_0=544,CO_S=0.424,CO_AUX_0=301).ELEMENT-IoT.ex | johannesE/decentlab-decoders | c290ea1218de2c82d665fdc9f71f16682e12d917 | [
"MIT"
] | 4 | 2019-05-10T07:17:41.000Z | 2021-10-20T16:24:04.000Z | DL-AC/DL-AC (NO2_WE_0=256,NO2_S=0.256,NO2_AUX_0=227,NO_WE_0=320,NO_S=0.512,NO_AUX_0=288,Ox_WE_0=235,Ox_S=0.345,Ox_AUX_0=200,CO_WE_0=544,CO_S=0.424,CO_AUX_0=301).ELEMENT-IoT.ex | johannesE/decentlab-decoders | c290ea1218de2c82d665fdc9f71f16682e12d917 | [
"MIT"
] | 15 | 2019-06-04T06:13:32.000Z | 2022-02-15T07:28:52.000Z |
# https://www.decentlab.com/products/air-quality-station-no2-no-co-ox-for-lorawan
defmodule Parser do
use Platform.Parsing.Behaviour
# device-specific parameters
defp no2_we_0(), do: 256
defp no2_s(), do: 0.256
defp no2_aux_0(), do: 227
defp no_we_0(), do: 320
defp no_s(), do: 0.512
defp no_aux_0(), ... | 41.360294 | 116 | 0.537956 |
331172e288c3d4f014324e10dfe15c2a48647087 | 2,034 | ex | Elixir | lib/exq_ui_web/live/queue_live/show.ex | neslinesli93/exq_ui | 11fe6b75f104cf524757e008a46af541c3cbeb0e | [
"Apache-2.0"
] | null | null | null | lib/exq_ui_web/live/queue_live/show.ex | neslinesli93/exq_ui | 11fe6b75f104cf524757e008a46af541c3cbeb0e | [
"Apache-2.0"
] | null | null | null | lib/exq_ui_web/live/queue_live/show.ex | neslinesli93/exq_ui | 11fe6b75f104cf524757e008a46af541c3cbeb0e | [
"Apache-2.0"
] | null | null | null | defmodule ExqUIWeb.QueueLive.Show do
@moduledoc false
use ExqUIWeb, :live_view
alias ExqUI.Queue
@page_size 30
@impl true
def mount(%{"name" => name} = params, _session, socket) do
socket =
assign(socket, :columns, [
%{header: "Module", accessor: fn item -> item.job.class end},
%... | 26.415584 | 93 | 0.622911 |
3311767ddf6f8de2a82de7a8e59564f56c47ca36 | 7,911 | ex | Elixir | apps/aecore/lib/aecore/channel/tx/channel_close_mutal_tx.ex | SingularityMatrix/elixir-node | ad126aa97931165185cf35454718ed2eee40ceed | [
"ISC"
] | null | null | null | apps/aecore/lib/aecore/channel/tx/channel_close_mutal_tx.ex | SingularityMatrix/elixir-node | ad126aa97931165185cf35454718ed2eee40ceed | [
"ISC"
] | null | null | null | apps/aecore/lib/aecore/channel/tx/channel_close_mutal_tx.ex | SingularityMatrix/elixir-node | ad126aa97931165185cf35454718ed2eee40ceed | [
"ISC"
] | null | null | null | defmodule Aecore.Channel.Tx.ChannelCloseMutalTx do
@moduledoc """
Module defining the ChannelCloseMutual transaction
"""
use Aecore.Tx.Transaction
alias Aecore.Governance.GovernanceConstants
alias Aecore.Channel.Tx.ChannelCloseMutalTx
alias Aecore.Tx.DataTx
alias Aecore.Account.{Account, AccountStateT... | 30.194656 | 158 | 0.656049 |
331178a800820e013a721a232366979721239c69 | 1,676 | exs | Elixir | test/controllers/callbacks/success_callback_controller_test.exs | van-mronov/ex_money | 39010f02fd822657e3b5694e08b872bd2ab72c26 | [
"0BSD"
] | 184 | 2015-11-23T20:51:50.000Z | 2022-03-30T01:01:39.000Z | test/controllers/callbacks/success_callback_controller_test.exs | van-mronov/ex_money | 39010f02fd822657e3b5694e08b872bd2ab72c26 | [
"0BSD"
] | 15 | 2015-11-26T16:00:20.000Z | 2018-05-25T20:13:39.000Z | test/controllers/callbacks/success_callback_controller_test.exs | van-mronov/ex_money | 39010f02fd822657e3b5694e08b872bd2ab72c26 | [
"0BSD"
] | 21 | 2015-11-26T21:34:40.000Z | 2022-03-26T02:56:42.000Z | defmodule ExMoney.Web.Callbacks.SuccessCallbackControllerTest do
use ExMoney.Web.ConnCase
import ExMoney.Factory
alias ExMoney.{Repo, Login}
test "when login does not exist", %{conn: conn} do
user = insert(:user)
login_id = 123
body = [
data: [
customer_id: user.saltedge_customer_id... | 22.648649 | 82 | 0.594272 |
33118e80382e2b3825b33e77f64ab716e80b07a1 | 832 | ex | Elixir | lib/ex_rss/date_parser.ex | cruessler/exrss | 6ac17b7533d78460a1c34cabaae86fec317f460a | [
"MIT"
] | 4 | 2020-02-16T07:18:35.000Z | 2021-12-09T14:43:10.000Z | lib/ex_rss/date_parser.ex | cruessler/exrss | 6ac17b7533d78460a1c34cabaae86fec317f460a | [
"MIT"
] | 27 | 2019-10-16T18:35:19.000Z | 2022-03-13T16:39:57.000Z | lib/ex_rss/date_parser.ex | cruessler/exrss | 6ac17b7533d78460a1c34cabaae86fec317f460a | [
"MIT"
] | null | null | null | defmodule ExRss.DateParser do
import Ecto.Query
alias Ecto.Changeset
alias ExRss.Entry
alias ExRss.Repo
def list_unparsed(number) do
from(e in Entry, where: is_nil(e.posted_at) and not is_nil(e.raw_posted_at), limit: ^number)
|> Repo.all()
end
def clear_parsed() do
Entry
|> Repo.update_... | 23.111111 | 96 | 0.610577 |
3311a3f9f1fd92878e80d242bdb3880910a9e5f8 | 723 | exs | Elixir | day09/test/day09_test.exs | bjorng/advent-of-code-2019 | b3612eefb5097f07ae139b5b7c637fabd3c86bef | [
"Apache-2.0"
] | 5 | 2019-12-08T05:14:27.000Z | 2020-10-26T04:06:22.000Z | day09/test/day09_test.exs | bjorng/advent-of-code-2019 | b3612eefb5097f07ae139b5b7c637fabd3c86bef | [
"Apache-2.0"
] | 1 | 2019-12-22T18:20:36.000Z | 2019-12-22T19:06:48.000Z | day09/test/day09_test.exs | bjorng/advent-of-code-2019 | b3612eefb5097f07ae139b5b7c637fabd3c86bef | [
"Apache-2.0"
] | null | null | null | defmodule Day09Test do
use ExUnit.Case
doctest Day09
test "test part 1 with examples" do
assert Day09.part1(example1()) == [109,1,204,-1,1001,100,1,100,1008,100,16,101,1006,101,0,99]
assert Day09.part1("104,1125899906842624,99") == [1125899906842624]
# assert Day09.part1("1102,34915192,34915192,7,4,7,... | 24.1 | 97 | 0.647303 |
3311acf03c05f0c5c56fe25ec6603ac35769779e | 564 | ex | Elixir | lib/bitpal_api/authentication/basic_auth.ex | bitpal/bitpal | 0e10eeaacf7a65b23945cfb95e4dbda8bffd4590 | [
"BSD-3-Clause-Clear"
] | 5 | 2021-05-04T21:28:00.000Z | 2021-12-01T11:19:48.000Z | lib/bitpal_api/authentication/basic_auth.ex | bitpal/bitpal | 0e10eeaacf7a65b23945cfb95e4dbda8bffd4590 | [
"BSD-3-Clause-Clear"
] | 71 | 2021-04-21T05:48:49.000Z | 2022-03-23T06:30:37.000Z | lib/bitpal_api/authentication/basic_auth.ex | bitpal/bitpal | 0e10eeaacf7a65b23945cfb95e4dbda8bffd4590 | [
"BSD-3-Clause-Clear"
] | 1 | 2021-04-25T10:35:41.000Z | 2021-04-25T10:35:41.000Z | defmodule BitPalApi.Authentication.BasicAuth do
import Plug.Conn
alias BitPal.Authentication.Tokens
alias BitPalApi.UnauthorizedError
def init(opts), do: opts
def call(conn, _opts) do
case parse(conn) do
{:ok, store_id} ->
assign(conn, :current_store, store_id)
_ ->
raise Un... | 20.888889 | 63 | 0.648936 |
3311cae0dd33b93648311675c5e7967a17d35013 | 1,000 | ex | Elixir | lib/toby/util/cursor.ex | ndreynolds/toby | fc2e6960d8d5b366c0ecf130349659fc33ac2e2a | [
"MIT"
] | 82 | 2019-01-14T20:35:16.000Z | 2022-02-22T11:19:43.000Z | lib/toby/util/cursor.ex | ndreynolds/toby | fc2e6960d8d5b366c0ecf130349659fc33ac2e2a | [
"MIT"
] | 3 | 2019-01-20T17:17:44.000Z | 2019-01-24T08:51:55.000Z | lib/toby/util/cursor.ex | ndreynolds/toby | fc2e6960d8d5b366c0ecf130349659fc33ac2e2a | [
"MIT"
] | 5 | 2020-03-27T16:54:18.000Z | 2021-07-26T18:24:00.000Z | defmodule Toby.Util.Cursor do
@moduledoc """
Utils for managing cursors
"""
def next(%{position: position, size: size, continuous: true} = cursor)
when position >= size - 1 do
%{cursor | position: 0}
end
def next(%{position: position, size: size, continuous: false} = cursor)
when position ... | 22.727273 | 80 | 0.63 |
3311fc113654df51d52112d6138d58ade63253e7 | 2,802 | ex | Elixir | lib/snowplow_tracker/payload.ex | WTTJ/snowplow-elixir-tracker | 86b6301b4b98b04fca0d79ab2f4fca03a5e748c1 | [
"Apache-2.0"
] | 6 | 2018-04-30T11:02:45.000Z | 2021-06-18T19:09:39.000Z | lib/snowplow_tracker/payload.ex | WTTJ/snowplow-elixir-tracker | 86b6301b4b98b04fca0d79ab2f4fca03a5e748c1 | [
"Apache-2.0"
] | 15 | 2018-05-23T05:26:27.000Z | 2020-07-12T10:12:32.000Z | lib/snowplow_tracker/payload.ex | WTTJ/snowplow-elixir-tracker | 86b6301b4b98b04fca0d79ab2f4fca03a5e748c1 | [
"Apache-2.0"
] | 3 | 2020-06-05T23:30:14.000Z | 2021-06-22T08:14:35.000Z | defmodule SnowplowTracker.Payload do
@moduledoc """
Represents the data structure used to store event information
"""
@derive Jason.Encoder
alias __MODULE__
alias SnowplowTracker.Payloads.Helper
@keys [
pairs: %{}
]
defstruct @keys
@type t :: %__MODULE__{
pairs: map()
}
... | 25.706422 | 103 | 0.626338 |
3311fed2b5a01e6c3661c39d0e99254fb0287c15 | 445 | exs | Elixir | src/034/p034.exs | Ernulphus/polyglot-euler | a5b59b08e6844f0c278bff5ab798acefa95749f3 | [
"MIT"
] | 67 | 2017-12-05T20:44:33.000Z | 2022-03-04T08:13:16.000Z | src/034/p034.exs | Ernulphus/polyglot-euler | a5b59b08e6844f0c278bff5ab798acefa95749f3 | [
"MIT"
] | 49 | 2018-03-26T14:20:26.000Z | 2021-08-17T09:08:55.000Z | src/034/p034.exs | Ernulphus/polyglot-euler | a5b59b08e6844f0c278bff5ab798acefa95749f3 | [
"MIT"
] | 17 | 2018-03-25T23:40:47.000Z | 2022-03-04T08:13:44.000Z | defmodule Problem034 do
defp factorial(1), do: 1
defp factorial(x) when is_integer(x) and x > 0, do: x*factorial(x-1)
defp is_factorial_sum?(number) do
number ==
number
|> Integer.digits()
|> Enum.map(&(factorial(&1)))
|> Enum.sum()
end
def solve do
3..40_585 # magic number... | 20.227273 | 70 | 0.602247 |
331234e3e59477d3665caf6dbaa3178e183bfc9f | 601 | exs | Elixir | test/cog/chat/slack/templates/embedded/history_list_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/slack/templates/embedded/history_list_test.exs | matusf/cog | 71708301c7dc570fb0d3498a50f47a70ef957788 | [
"Apache-2.0"
] | 906 | 2016-02-22T22:54:19.000Z | 2022-03-11T15:19:43.000Z | test/cog/chat/slack/templates/embedded/history_list_test.exs | matusf/cog | 71708301c7dc570fb0d3498a50f47a70ef957788 | [
"Apache-2.0"
] | 95 | 2016-02-23T13:42:31.000Z | 2021-11-30T14:39:55.000Z | defmodule Cog.Chat.Slack.Templates.Embedded.HistoryListTest do
use Cog.TemplateCase
test "history-list template" do
data = %{"results" => [
%{"index" => 1,
"text" => "echo foo"},
%{"index" => 2,
"text" => "echo bar"}
]}
expected = "... | 22.259259 | 79 | 0.427621 |
33124d18da814062bb415e1106a0ab36f2a5dba9 | 870 | ex | Elixir | lib/cbr_elixir.ex | maratgaliev/cbr_elixir | b96cf927ecf531e54691cbda1faee52df0424b49 | [
"MIT"
] | null | null | null | lib/cbr_elixir.ex | maratgaliev/cbr_elixir | b96cf927ecf531e54691cbda1faee52df0424b49 | [
"MIT"
] | null | null | null | lib/cbr_elixir.ex | maratgaliev/cbr_elixir | b96cf927ecf531e54691cbda1faee52df0424b49 | [
"MIT"
] | null | null | null | defmodule CbrElixir do
import CbrElixir.Parser.DataParser
def daily(date \\ nil) do
period = date || format_date(Timex.today)
xml = HTTPoison.get!("http://www.cbr.ru/scripts/XML_daily.asp?date_req=#{period}").body
{:ok, resp} = xml |> Codepagex.to_string("VENDORS/MICSFT/WINDOWS/CP1251")
parse_dail... | 29 | 92 | 0.682759 |
33125105ed2265e79bdedd2ce7596c3c53d41c0c | 735 | exs | Elixir | test/decoder/decoder_test.exs | Homepolish/ulid | 376d778a30bdd9c15e43a29418613e48bd0e3519 | [
"MIT"
] | 23 | 2018-07-16T07:54:35.000Z | 2019-08-04T10:05:47.000Z | test/decoder/decoder_test.exs | Homepolish/ulid | 376d778a30bdd9c15e43a29418613e48bd0e3519 | [
"MIT"
] | 2 | 2020-01-10T21:38:10.000Z | 2021-03-14T13:13:07.000Z | test/decoder/decoder_test.exs | Homepolish/ulid | 376d778a30bdd9c15e43a29418613e48bd0e3519 | [
"MIT"
] | 2 | 2018-07-16T07:54:48.000Z | 2019-01-14T21:38:02.000Z | defmodule Ulid.DecoderTest do
use ExUnit.Case, async: true
describe "decode/1" do
test "decodes a text ulid" do
ulid = "01C9S7RTEBG8NJTYT689ENQD2X"
expected = <<1, 98, 114, 124, 105, 203, 130, 43, 45, 123, 70, 66, 93, 91, 180, 93>>
{:ok, result} = Ulid.Decoder.decode(ulid)
assert byte... | 26.25 | 89 | 0.616327 |
33125b4146da7a89afe90bfc099777232889a9c5 | 1,371 | ex | Elixir | clients/dataflow/lib/google_api/dataflow/v1b3/model/send_debug_capture_response.ex | leandrocp/elixir-google-api | a86e46907f396d40aeff8668c3bd81662f44c71e | [
"Apache-2.0"
] | null | null | null | clients/dataflow/lib/google_api/dataflow/v1b3/model/send_debug_capture_response.ex | leandrocp/elixir-google-api | a86e46907f396d40aeff8668c3bd81662f44c71e | [
"Apache-2.0"
] | null | null | null | clients/dataflow/lib/google_api/dataflow/v1b3/model/send_debug_capture_response.ex | leandrocp/elixir-google-api | a86e46907f396d40aeff8668c3bd81662f44c71e | [
"Apache-2.0"
] | 1 | 2020-11-10T16:58:27.000Z | 2020-11-10T16:58:27.000Z | # Copyright 2017 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in... | 31.883721 | 86 | 0.768053 |
33128f89799076cb766f507b5b2a64b081025746 | 7,519 | ex | Elixir | apps/socket/lib/grapevine_socket/handler/core.ex | oestrich/grapevine | 7fb745a3a6e4eb68bd761baa190b2df32fa1f73d | [
"MIT"
] | 107 | 2018-10-05T18:20:32.000Z | 2022-02-28T04:02:50.000Z | apps/socket/lib/grapevine_socket/handler/core.ex | oestrich/grapevine | 7fb745a3a6e4eb68bd761baa190b2df32fa1f73d | [
"MIT"
] | 33 | 2018-10-05T14:11:18.000Z | 2022-02-10T22:19:18.000Z | apps/socket/lib/grapevine_socket/handler/core.ex | oestrich/grapevine | 7fb745a3a6e4eb68bd761baa190b2df32fa1f73d | [
"MIT"
] | 18 | 2019-02-03T03:08:20.000Z | 2021-12-28T04:29:36.000Z | defmodule GrapevineSocket.Handler.Core do
@moduledoc """
Core events
Authenticate, heartbeat, etc
"""
use GrapevineSocket.Web.Module
require Logger
alias GrapevineData.Channels
alias GrapevineData.Games
alias GrapevineData.Messages
alias GrapevineSocket.Channels, as: LocalChannels
alias Grapev... | 27.441606 | 97 | 0.628142 |
3312976a61ab619fe1104f7f084b7310f0da4561 | 528 | ex | Elixir | test/support/test_tools.ex | diogobaracho/cashflowex | 7b66ff98239407f2ea2e11bf1693783dd94a725b | [
"Apache-2.0"
] | null | null | null | test/support/test_tools.ex | diogobaracho/cashflowex | 7b66ff98239407f2ea2e11bf1693783dd94a725b | [
"Apache-2.0"
] | null | null | null | test/support/test_tools.ex | diogobaracho/cashflowex | 7b66ff98239407f2ea2e11bf1693783dd94a725b | [
"Apache-2.0"
] | null | null | null | defmodule CashFlowEx.TestTools do
@moduledoc """
helper for reduce import mudules in test files
"""
use ExUnit.CaseTemplate
using do
quote do
use CashFlowExWeb.ConnCase, async: true
# import CashFlowEx.Support.Factory
# import CashFlowEx.Test.ConnSimulator
# import CashFlowEx.Tes... | 24 | 77 | 0.691288 |
3312aef8089ad52f726f0657dc7a8fb76c7a361a | 1,519 | ex | Elixir | clients/testing/lib/google_api/testing/v1/model/account.ex | mocknen/elixir-google-api | dac4877b5da2694eca6a0b07b3bd0e179e5f3b70 | [
"Apache-2.0"
] | null | null | null | clients/testing/lib/google_api/testing/v1/model/account.ex | mocknen/elixir-google-api | dac4877b5da2694eca6a0b07b3bd0e179e5f3b70 | [
"Apache-2.0"
] | null | null | null | clients/testing/lib/google_api/testing/v1/model/account.ex | mocknen/elixir-google-api | dac4877b5da2694eca6a0b07b3bd0e179e5f3b70 | [
"Apache-2.0"
] | null | null | null | # Copyright 2017 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in... | 31.645833 | 84 | 0.74391 |
3312c52cedabdacecb4fe492d32452a5c255c1e2 | 9,283 | ex | Elixir | lib/rihanna/job.ex | victorolinasc/rihanna | 560353c43e22bf81be14fbaaea066a144c0a55c9 | [
"MIT"
] | null | null | null | lib/rihanna/job.ex | victorolinasc/rihanna | 560353c43e22bf81be14fbaaea066a144c0a55c9 | [
"MIT"
] | null | null | null | lib/rihanna/job.ex | victorolinasc/rihanna | 560353c43e22bf81be14fbaaea066a144c0a55c9 | [
"MIT"
] | null | null | null | defmodule Rihanna.Job do
require Logger
@type result :: any
@type reason :: any
@type arg :: any
@type t :: %__MODULE__{}
@callback perform(arg :: any) :: :ok | {:ok, result} | :error | {:error, reason}
@callback after_error({:error, reason} | :error | Exception.t(), arg) :: any()
@optional_callbacks ... | 24.558201 | 113 | 0.573414 |
3312e96c1c569817c62a58b5d009ee93bb83ce73 | 1,861 | ex | Elixir | lib/changelog_web/plugs/vanity_domains.ex | axelson/changelog.com | bad9f461aabbde0faa938f7b2ae643ed47d1df9b | [
"MIT"
] | 1 | 2021-01-06T18:21:45.000Z | 2021-01-06T18:21:45.000Z | lib/changelog_web/plugs/vanity_domains.ex | codexn/changelog.com | 25ce501ee62eef76731c38d590667e8132096ba8 | [
"MIT"
] | null | null | null | lib/changelog_web/plugs/vanity_domains.ex | codexn/changelog.com | 25ce501ee62eef76731c38d590667e8132096ba8 | [
"MIT"
] | null | null | null | defmodule ChangelogWeb.Plug.VanityDomains do
@moduledoc """
Handles all redirects of podcast vanity domains to their appropriate place.
"""
alias ChangelogWeb.PodcastView
alias ChangelogWeb.RedirectController, as: Redirect
import ChangelogWeb.Plug.Conn
def init(opts), do: opts
# should be called after... | 30.508197 | 77 | 0.681891 |
3312ebe128a452b063b0f307701ab5ffe2a05fdd | 2,764 | ex | Elixir | lib/asciinema/telemetry.ex | remerle/asciinema-server | 895bf5a7ffb7db1b418c97cfd2ac9136c46dfb57 | [
"Apache-2.0"
] | 893 | 2017-09-14T14:18:29.000Z | 2022-03-31T21:45:08.000Z | lib/asciinema/telemetry.ex | remerle/asciinema-server | 895bf5a7ffb7db1b418c97cfd2ac9136c46dfb57 | [
"Apache-2.0"
] | 103 | 2017-09-29T22:15:33.000Z | 2022-03-27T21:47:43.000Z | lib/asciinema/telemetry.ex | remerle/asciinema-server | 895bf5a7ffb7db1b418c97cfd2ac9136c46dfb57 | [
"Apache-2.0"
] | 152 | 2017-09-07T12:43:15.000Z | 2022-03-10T18:47:47.000Z | defmodule Asciinema.Telemetry do
use Supervisor
import Telemetry.Metrics
def start_link(arg) do
if enabled?() do
Supervisor.start_link(__MODULE__, arg, name: __MODULE__)
else
:ignore
end
end
def init(_arg) do
children = [
{:telemetry_poller, period: 10_000},
{Telemetr... | 27.919192 | 89 | 0.656657 |
331300153fd142cc72d61823a1c57cdbeca2a646 | 88 | exs | Elixir | test/ve_collector_web/views/page_view_test.exs | fossabot/ve_collector | dd003f9d1e332b5495756a483098ad8bbd75adf0 | [
"MIT"
] | null | null | null | test/ve_collector_web/views/page_view_test.exs | fossabot/ve_collector | dd003f9d1e332b5495756a483098ad8bbd75adf0 | [
"MIT"
] | 2 | 2020-06-02T08:28:31.000Z | 2021-03-10T17:07:09.000Z | test/ve_collector_web/views/page_view_test.exs | fossabot/ve_collector | dd003f9d1e332b5495756a483098ad8bbd75adf0 | [
"MIT"
] | 1 | 2020-06-02T08:06:48.000Z | 2020-06-02T08:06:48.000Z | defmodule VeCollectorWeb.PageViewTest do
use VeCollectorWeb.ConnCase, async: true
end
| 22 | 42 | 0.840909 |
3313225e0abb9d6a74468fc8530bcb0e44c65567 | 4,696 | ex | Elixir | lib/plausible/google/api.ex | etienneCharignon/analytics | 924c96f0a563432fffcb83c6c01cb04169d1a819 | [
"MIT"
] | null | null | null | lib/plausible/google/api.ex | etienneCharignon/analytics | 924c96f0a563432fffcb83c6c01cb04169d1a819 | [
"MIT"
] | null | null | null | lib/plausible/google/api.ex | etienneCharignon/analytics | 924c96f0a563432fffcb83c6c01cb04169d1a819 | [
"MIT"
] | null | null | null | defmodule Plausible.Google.Api do
@scope URI.encode_www_form("https://www.googleapis.com/auth/webmasters.readonly email")
@verified_permission_levels ["siteOwner", "siteFullUser", "siteRestrictedUser"]
def authorize_url(site_id) do
if Application.get_env(:plausible, :environment) == "test" do
""
el... | 30.493506 | 125 | 0.622019 |
33135a6b7f0af962e746e755823cb9e736096d42 | 2,227 | ex | Elixir | clients/games_management/lib/google_api/games_management/v1management/model/player_score_reset_response.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/games_management/lib/google_api/games_management/v1management/model/player_score_reset_response.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/games_management/lib/google_api/games_management/v1management/model/player_score_reset_response.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | # Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, s... | 39.070175 | 212 | 0.728783 |
33137f98f5340f0a0e2ca71a50fef5f961841c3c | 28,594 | ex | Elixir | lib/elixir/lib/task.ex | favetelinguis/elixir | e395b5d7491184acc9cfc9f14cd9673e423f5382 | [
"Apache-2.0"
] | null | null | null | lib/elixir/lib/task.ex | favetelinguis/elixir | e395b5d7491184acc9cfc9f14cd9673e423f5382 | [
"Apache-2.0"
] | null | null | null | lib/elixir/lib/task.ex | favetelinguis/elixir | e395b5d7491184acc9cfc9f14cd9673e423f5382 | [
"Apache-2.0"
] | null | null | null | defmodule Task do
@moduledoc """
Conveniences for spawning and awaiting tasks.
Tasks are processes meant to execute one particular
action throughout their lifetime, often with little or no
communication with other processes. The most common use case
for tasks is to convert sequential code into concurrent c... | 33.32634 | 106 | 0.67077 |
3313928100cb0bbedcb52bcac008b3896c95c49b | 1,536 | ex | Elixir | clients/iam/lib/google_api/iam/v1/model/undelete_service_account_response.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/iam/lib/google_api/iam/v1/model/undelete_service_account_response.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | 1 | 2020-12-18T09:25:12.000Z | 2020-12-18T09:25:12.000Z | clients/iam/lib/google_api/iam/v1/model/undelete_service_account_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... | 32.680851 | 138 | 0.753255 |
33139be680ceb8272e6eec157701caf5f8c3183b | 512 | exs | Elixir | mix.exs | vscGabriel/gen_report | 984b17b48f80869761a4b0fdb95472f46c810429 | [
"MIT"
] | null | null | null | mix.exs | vscGabriel/gen_report | 984b17b48f80869761a4b0fdb95472f46c810429 | [
"MIT"
] | null | null | null | mix.exs | vscGabriel/gen_report | 984b17b48f80869761a4b0fdb95472f46c810429 | [
"MIT"
] | null | null | null | defmodule GenReport.MixProject do
use Mix.Project
def project do
[
app: :gen_report,
version: "0.1.0",
elixir: "~> 1.12",
start_permanent: Mix.env() == :prod,
deps: deps()
]
end
# Run "mix help compile.app" to learn about applications.
def application do
[
ext... | 18.285714 | 61 | 0.574219 |
33139de7feb2dc47a43b28d191302ffbbee96029 | 9,448 | exs | Elixir | backend/test/spades_game/game_test.exs | mreishus/spades | 3e06fa5c2415ff43258ec4c231f8d6c49c683fe0 | [
"MIT"
] | 9 | 2019-10-28T08:48:50.000Z | 2021-03-05T09:44:46.000Z | backend/test/spades_game/game_test.exs | mreishus/spades | 3e06fa5c2415ff43258ec4c231f8d6c49c683fe0 | [
"MIT"
] | 227 | 2019-10-28T08:52:58.000Z | 2022-02-27T04:31:42.000Z | backend/test/spades_game/game_test.exs | mreishus/spades | 3e06fa5c2415ff43258ec4c231f8d6c49c683fe0 | [
"MIT"
] | 4 | 2020-04-18T19:38:37.000Z | 2021-08-02T19:43:03.000Z | defmodule GameTest do
use ExUnit.Case, async: true
doctest SpadesGame.Game
alias SpadesGame.{Card, Game, GameOptions, GamePlayer, TrickCard}
setup do
{:ok, options} = GameOptions.validate(%{"hardcoded_cards" => true})
%{options: options}
end
describe "new/1" do
test "returns a game" do
... | 35.253731 | 92 | 0.570068 |
3313a986df39bc3f146a1b5ccb6d9d76b11ac0c0 | 890 | exs | Elixir | kv_umbrella/apps/kv/mix.exs | guthb/fp | 2a754adfcf2eb60e80016a23de81fad83993bafe | [
"MIT"
] | null | null | null | kv_umbrella/apps/kv/mix.exs | guthb/fp | 2a754adfcf2eb60e80016a23de81fad83993bafe | [
"MIT"
] | null | null | null | kv_umbrella/apps/kv/mix.exs | guthb/fp | 2a754adfcf2eb60e80016a23de81fad83993bafe | [
"MIT"
] | null | null | null | defmodule KV.MixProject do
use Mix.Project
def project do
[
app: :kv,
version: "0.1.0",
elixir: "~> 1.11",
start_permanent: Mix.env() == :prod,
deps: deps(),
build_path: "../../_build",
config_path: "../../config/config.exs",
deps_path: "../../deps",
lockfi... | 21.707317 | 85 | 0.529213 |
3313f6208e486d5a2091e452b3da9b5fca044bf7 | 2,839 | ex | Elixir | deps/gettext/lib/gettext/fuzzy.ex | hallebadkapp/rumbl-ms | ae2ef9975658115f8c4d5c49c28d8bde00a74b83 | [
"MIT"
] | 1 | 2017-10-16T03:00:50.000Z | 2017-10-16T03:00:50.000Z | deps/gettext/lib/gettext/fuzzy.ex | hallebadkapp/rumbl-ms | ae2ef9975658115f8c4d5c49c28d8bde00a74b83 | [
"MIT"
] | null | null | null | deps/gettext/lib/gettext/fuzzy.ex | hallebadkapp/rumbl-ms | ae2ef9975658115f8c4d5c49c28d8bde00a74b83 | [
"MIT"
] | 1 | 2019-11-23T12:09:14.000Z | 2019-11-23T12:09:14.000Z | defmodule Gettext.Fuzzy do
@moduledoc false
alias Gettext.PO
alias Gettext.PO.Translation
alias Gettext.PO.PluralTranslation
@type translation_key :: binary | {binary, binary}
@doc """
Returns a matcher function that takes two translation keys and checks if they
match.
`String.jaro_distance/2` (wh... | 43.015152 | 98 | 0.704473 |
3313ff35cf650cfac837919518f9c3d913dcd676 | 5,739 | ex | Elixir | lib/aws/generated/backup_gateway.ex | andrewhr/aws-elixir | 861dc2fafca50a2b2f83badba4cdcb44b5b0c171 | [
"Apache-2.0"
] | null | null | null | lib/aws/generated/backup_gateway.ex | andrewhr/aws-elixir | 861dc2fafca50a2b2f83badba4cdcb44b5b0c171 | [
"Apache-2.0"
] | null | null | null | lib/aws/generated/backup_gateway.ex | andrewhr/aws-elixir | 861dc2fafca50a2b2f83badba4cdcb44b5b0c171 | [
"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.BackupGateway do
@moduledoc """
Backup gateway
Backup gateway connects Backup to your hypervisor, so you can create, store, and
restore backups of your virtual machines (VMs) anywhere, wh... | 32.982759 | 93 | 0.707092 |
33143a36fcdda554b56c0e30f9c51da21fa5c92d | 498 | ex | Elixir | test/support/create_person.ex | elixir-cqrs/cqrs_tools_absinthe | c80285f252eba8273384fdd1c718cf50b2d36671 | [
"MIT"
] | 3 | 2022-03-06T03:07:49.000Z | 2022-03-06T03:16:08.000Z | test/support/create_person.ex | blunt-elixir/blunt_absinthe | c80285f252eba8273384fdd1c718cf50b2d36671 | [
"MIT"
] | null | null | null | test/support/create_person.ex | blunt-elixir/blunt_absinthe | c80285f252eba8273384fdd1c718cf50b2d36671 | [
"MIT"
] | null | null | null | defmodule Blunt.Absinthe.Test.CreatePerson do
@moduledoc """
Creates's a person.
"""
use Blunt.Command
alias Blunt.Absinthe.Test.ReadModel.Person
field :name, :string
field :gender, :enum, values: Person.genders(), default: :not_sure
internal_field :id, :binary_id, desc: "Id is set internally. Settin... | 23.714286 | 94 | 0.716867 |
331443aeaab2d7e0c846a09d88ae2bc9181eac4d | 388 | exs | Elixir | priv/repo/seeds.exs | MorphicPro/morphic.pro | 9098da267344e025f262a344de6a2fb5cfea50a8 | [
"MIT"
] | 5 | 2020-04-23T21:12:17.000Z | 2020-09-30T00:16:58.000Z | priv/repo/seeds.exs | joshchernoff/morphic.pro | 9098da267344e025f262a344de6a2fb5cfea50a8 | [
"MIT"
] | 232 | 2020-04-24T00:52:24.000Z | 2021-08-05T17:23:12.000Z | priv/repo/seeds.exs | MorphicPro/morphic.pro | 9098da267344e025f262a344de6a2fb5cfea50a8 | [
"MIT"
] | 1 | 2020-04-04T02:19:44.000Z | 2020-04-04T02:19:44.000Z | # 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:
#
# MorphicPro.Repo.insert!(%MorphicPro.SomeSchema{})
#
# We recommend using the bang functions (`insert!`, `update!`
# and so on) as the... | 27.714286 | 61 | 0.71134 |
3314463f00706d64f9970c04cfdd6e152b20a397 | 1,663 | ex | Elixir | clients/slides/lib/google_api/slides/v1/model/table_row_properties.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/slides/lib/google_api/slides/v1/model/table_row_properties.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/slides/lib/google_api/slides/v1/model/table_row_properties.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | # Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, s... | 33.938776 | 166 | 0.739627 |
33145aef856479f04401c8a86d40a80407d8c37e | 2,178 | exs | Elixir | web/mix.exs | lancaster-university/infolab-lights | 4914fd9ef8519be27199b1ed5e9ca8e81ecb05fd | [
"MIT"
] | 5 | 2021-11-04T08:31:46.000Z | 2021-11-07T12:15:57.000Z | web/mix.exs | lancaster-university/infolab-lights | 4914fd9ef8519be27199b1ed5e9ca8e81ecb05fd | [
"MIT"
] | 2 | 2021-11-01T19:00:35.000Z | 2021-11-04T13:07:47.000Z | web/mix.exs | lancaster-university/infolab-lights | 4914fd9ef8519be27199b1ed5e9ca8e81ecb05fd | [
"MIT"
] | 2 | 2021-11-04T10:46:41.000Z | 2022-02-22T18:05:44.000Z | defmodule InfolabLightGames.MixProject do
use Mix.Project
def project do
[
app: :infolab_light_games,
version: "0.1.0",
elixir: "~> 1.12",
elixirc_paths: elixirc_paths(Mix.env()),
compilers: [:phoenix] ++ Mix.compilers() ++ [:phoenix_swagger],
start_permanent: Mix.env() == :... | 29.04 | 87 | 0.562443 |
33146718034d25f50e0b026aba04530bf5539977 | 1,777 | exs | Elixir | mix.exs | Kr00lIX/cast_params | 3e57d41afee04139cb959e2835f459912753f102 | [
"MIT"
] | 2 | 2018-12-07T20:31:56.000Z | 2020-07-06T12:14:59.000Z | mix.exs | Kr00lIX/cast_params | 3e57d41afee04139cb959e2835f459912753f102 | [
"MIT"
] | null | null | null | mix.exs | Kr00lIX/cast_params | 3e57d41afee04139cb959e2835f459912753f102 | [
"MIT"
] | null | null | null | defmodule CastParams.MixProject do
use Mix.Project
@version "0.0.4"
def project do
[
app: :cast_params,
version: @version,
elixir: ">= 1.5.0",
start_permanent: Mix.env() == :prod,
deps: deps(),
test_coverage: [tool: ExCoveralls],
preferred_cli_env: [coveralls: :test... | 26.132353 | 82 | 0.588633 |
33147beb44f72413f45b3a167b540904145efcac | 51,346 | ex | Elixir | lib/elixir/lib/file.ex | RyanBard/elixir | 3e0f3b47cf26aa121470141b9a1aa55a366c066e | [
"Apache-2.0"
] | 2 | 2018-11-15T06:38:14.000Z | 2018-11-17T18:03:14.000Z | lib/elixir/lib/file.ex | RyanBard/elixir | 3e0f3b47cf26aa121470141b9a1aa55a366c066e | [
"Apache-2.0"
] | 1 | 2018-09-10T23:36:45.000Z | 2018-09-10T23:36:45.000Z | lib/elixir/lib/file.ex | RyanBard/elixir | 3e0f3b47cf26aa121470141b9a1aa55a366c066e | [
"Apache-2.0"
] | 1 | 2018-09-10T23:32:56.000Z | 2018-09-10T23:32:56.000Z | defmodule File do
@moduledoc ~S"""
This module contains functions to manipulate files.
Some of those functions are low-level, allowing the user
to interact with files or IO devices, like `open/2`,
`copy/3` and others. This module also provides higher
level functions that work with filenames and have their ... | 29.526164 | 101 | 0.621548 |
331489bb082e8548a7ea01e276f46e76839cb9c9 | 366 | ex | Elixir | repository_summary/lib/auth/plug_refresh.ex | joabehenrique/repository-summary | 6a7c28098a9faf11386b43996bf5ad33b50cddf2 | [
"MIT"
] | null | null | null | repository_summary/lib/auth/plug_refresh.ex | joabehenrique/repository-summary | 6a7c28098a9faf11386b43996bf5ad33b50cddf2 | [
"MIT"
] | null | null | null | repository_summary/lib/auth/plug_refresh.ex | joabehenrique/repository-summary | 6a7c28098a9faf11386b43996bf5ad33b50cddf2 | [
"MIT"
] | null | null | null | defmodule RepositorySummaryWeb.Auth.RefreshToken do
import Plug.Conn
alias RepositorySummaryWeb.Auth.Guardian
def init(options), do: options
def call(conn, _options) do
old_token = Guardian.Plug.current_token(conn)
with {:ok, new_token} <- Guardian.refresh_token(old_token) do
put_private(conn,... | 22.875 | 65 | 0.745902 |
3314abad3a6a363a07d684afd01ed39917d809ef | 24,620 | ex | Elixir | lib/level_web/schema/mutations.ex | mindriot101/level | 0a2cbae151869c2d9b79b3bfb388f5d00739ae12 | [
"Apache-2.0"
] | 928 | 2018-04-03T16:18:11.000Z | 2019-09-09T17:59:55.000Z | lib/level_web/schema/mutations.ex | mindriot101/level | 0a2cbae151869c2d9b79b3bfb388f5d00739ae12 | [
"Apache-2.0"
] | 74 | 2018-04-03T00:46:50.000Z | 2019-03-10T18:57:27.000Z | lib/level_web/schema/mutations.ex | mindriot101/level | 0a2cbae151869c2d9b79b3bfb388f5d00739ae12 | [
"Apache-2.0"
] | 89 | 2018-04-03T17:33:20.000Z | 2019-08-19T03:40:20.000Z | defmodule LevelWeb.Schema.Mutations do
@moduledoc false
use Absinthe.Schema.Notation
@desc "Interface for payloads containing validation data."
interface :validatable do
field :success, non_null(:boolean)
field :errors, list_of(:error)
resolve_type fn _, _ -> nil end
end
@desc "A validation e... | 27.50838 | 76 | 0.684972 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.