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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
5a505c4ec152c09f68bca9372385f4f71b6d423c | 3,281 | ex | Elixir | clients/storage_transfer/lib/google_api/storage_transfer/v1/model/http_data.ex | GoNZooo/elixir-google-api | cf3ad7392921177f68091f3d9001f1b01b92f1cc | [
"Apache-2.0"
] | null | null | null | clients/storage_transfer/lib/google_api/storage_transfer/v1/model/http_data.ex | GoNZooo/elixir-google-api | cf3ad7392921177f68091f3d9001f1b01b92f1cc | [
"Apache-2.0"
] | null | null | null | clients/storage_transfer/lib/google_api/storage_transfer/v1/model/http_data.ex | GoNZooo/elixir-google-api | cf3ad7392921177f68091f3d9001f1b01b92f1cc | [
"Apache-2.0"
] | 1 | 2018-07-28T20:50:50.000Z | 2018-07-28T20:50:50.000Z | # Copyright 2017 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in... | 71.326087 | 1,830 | 0.762268 |
5a506feb49e9a43240f4f57c5cf9efdec24b8692 | 649 | ex | Elixir | lib/straw_hat_map/migrations/create_cities_table.ex | straw-hat-team/straw_hat_map | df71340122852577b9df2ed2afcbcc4be879aba1 | [
"MIT"
] | 4 | 2018-03-07T04:12:36.000Z | 2018-03-08T16:13:14.000Z | lib/straw_hat_map/migrations/create_cities_table.ex | straw-hat-labs/straw_hat_map | df71340122852577b9df2ed2afcbcc4be879aba1 | [
"MIT"
] | 61 | 2018-03-07T04:50:42.000Z | 2019-11-01T10:24:03.000Z | lib/straw_hat_map/migrations/create_cities_table.ex | straw-hat-team/straw_hat_map | df71340122852577b9df2ed2afcbcc4be879aba1 | [
"MIT"
] | 2 | 2018-03-22T19:44:45.000Z | 2019-08-02T03:45:47.000Z | defmodule StrawHat.Map.Migrations.CreateCitiesTable do
@moduledoc """
Create cities table.
Created at: ~N[2017-05-17 23:23:49]
"""
use Ecto.Migration
def change do
create table(:cities, primary_key: false) do
add(:id, :binary_id, primary_key: true)
add(:name, :string, null: false)
a... | 28.217391 | 96 | 0.668721 |
5a5071b498332d99dd4f7c54642029bf68a8447d | 685 | exs | Elixir | mix.exs | tegon/elixir-in-action | 1bcb8fb0e1d32593a505dc634977c0ea3d4a56ba | [
"MIT"
] | 1 | 2017-09-07T14:36:47.000Z | 2017-09-07T14:36:47.000Z | mix.exs | tegon/elixir-in-action | 1bcb8fb0e1d32593a505dc634977c0ea3d4a56ba | [
"MIT"
] | null | null | null | mix.exs | tegon/elixir-in-action | 1bcb8fb0e1d32593a505dc634977c0ea3d4a56ba | [
"MIT"
] | null | null | null | defmodule ElixirInAction.Mixfile do
use Mix.Project
def project do
[app: :elixir_in_action,
version: "0.1.0",
elixir: "~> 1.3",
build_embedded: Mix.env == :prod,
start_permanent: Mix.env == :prod,
deps: deps()]
end
# Configuration for the OTP application
#
# Type "mix help com... | 20.757576 | 77 | 0.616058 |
5a50d5e41fba255b62f5c39917196e09b1a4e573 | 1,693 | ex | Elixir | lib/queryhub_web/endpoint.ex | blaedj/queryhub | 1605d29e1d2b8a2a66bf911945dab441682083dc | [
"Apache-2.0"
] | null | null | null | lib/queryhub_web/endpoint.ex | blaedj/queryhub | 1605d29e1d2b8a2a66bf911945dab441682083dc | [
"Apache-2.0"
] | null | null | null | lib/queryhub_web/endpoint.ex | blaedj/queryhub | 1605d29e1d2b8a2a66bf911945dab441682083dc | [
"Apache-2.0"
] | null | null | null | defmodule QueryHubWeb.Endpoint do
use Phoenix.Endpoint, otp_app: :queryhub
socket("/socket", QueryHubWeb.UserSocket)
# Serve at "/" the static files from "priv/static" directory.
#
# You should set gzip to true if you are running phoenix.digest
# when deploying your static files in production.
plug(
... | 26.046154 | 95 | 0.689309 |
5a50e5b9e457639e81addcd54e78d2c926539346 | 208 | exs | Elixir | test/mathmatical_web/controllers/page_controller_test.exs | shawnonthenet/mathmatical | d0f8d9e77dc71edfdc88776daca973fcd9cd106b | [
"Apache-2.0"
] | null | null | null | test/mathmatical_web/controllers/page_controller_test.exs | shawnonthenet/mathmatical | d0f8d9e77dc71edfdc88776daca973fcd9cd106b | [
"Apache-2.0"
] | null | null | null | test/mathmatical_web/controllers/page_controller_test.exs | shawnonthenet/mathmatical | d0f8d9e77dc71edfdc88776daca973fcd9cd106b | [
"Apache-2.0"
] | null | null | null | defmodule MathmaticalWeb.PageControllerTest do
use MathmaticalWeb.ConnCase
test "GET /", %{conn: conn} do
conn = get(conn, "/")
assert html_response(conn, 200) =~ "Welcome to Phoenix!"
end
end
| 23.111111 | 60 | 0.692308 |
5a50e8d2d17193437015eee71fb6d9774e0451f6 | 1,052 | ex | Elixir | lib/ouidata/release_reader.ex | shamanime/ouidata | 4acba55f56195c6f939b4eefd68472480548e7fe | [
"MIT"
] | null | null | null | lib/ouidata/release_reader.ex | shamanime/ouidata | 4acba55f56195c6f939b4eefd68472480548e7fe | [
"MIT"
] | null | null | null | lib/ouidata/release_reader.ex | shamanime/ouidata | 4acba55f56195c6f939b4eefd68472480548e7fe | [
"MIT"
] | null | null | null | defmodule Ouidata.ReleaseReader do
@moduledoc false
def vendors, do: simple_lookup(:vendors) |> hd |> elem(1)
def release_version, do: simple_lookup(:release_version) |> hd |> elem(1)
def archive_content_length, do: simple_lookup(:archive_content_length) |> hd |> elem(1)
def get(address) do
do_get(addre... | 24.465116 | 89 | 0.688213 |
5a5112ed2e93578537c7bb86a10806d488875ccf | 9,733 | exs | Elixir | test/acceptance/ast/links_images/link_test.exs | akash-akya/earmark_parser | de2216ca0622a9d2491ea2295d0be1bedcaf64c6 | [
"Apache-2.0"
] | null | null | null | test/acceptance/ast/links_images/link_test.exs | akash-akya/earmark_parser | de2216ca0622a9d2491ea2295d0be1bedcaf64c6 | [
"Apache-2.0"
] | null | null | null | test/acceptance/ast/links_images/link_test.exs | akash-akya/earmark_parser | de2216ca0622a9d2491ea2295d0be1bedcaf64c6 | [
"Apache-2.0"
] | null | null | null | defmodule Acceptance.Ast.LinkImages.LinkTest do
use ExUnit.Case, async: true
import Support.Helpers, only: [as_ast: 1, as_ast: 2, parse_html: 1]
import EarmarkAstDsl, only: [p: 1, tag: 3]
describe "Link reference definitions" do
test "link with title" do
markdown = "[foo]: /url \"title\"\n\n[foo]\n"
... | 30.996815 | 133 | 0.549882 |
5a5119e0b1eb301c97424c5801ebbc6921d81a91 | 20,520 | ex | Elixir | lib/phoenix_live_view/upload_config.ex | kuroda/phoenix_live_view | ffa5d555368f2ca42d57bc573bba63e01c218226 | [
"MIT"
] | null | null | null | lib/phoenix_live_view/upload_config.ex | kuroda/phoenix_live_view | ffa5d555368f2ca42d57bc573bba63e01c218226 | [
"MIT"
] | null | null | null | lib/phoenix_live_view/upload_config.ex | kuroda/phoenix_live_view | ffa5d555368f2ca42d57bc573bba63e01c218226 | [
"MIT"
] | null | null | null | defmodule Phoenix.LiveView.UploadEntry do
@moduledoc """
The struct representing an upload entry.
"""
alias Phoenix.LiveView.UploadEntry
defstruct progress: 0,
preflighted?: false,
upload_config: nil,
upload_ref: nil,
ref: nil,
uuid: nil,
... | 29.189189 | 102 | 0.60307 |
5a511a01065bfd767920b60ae6068aa0889ef26a | 3,090 | ex | Elixir | lib/docdog_web/controllers/document_controller.ex | wunsh/docdog-engine | a3044d21a6ac00098a295249358a367059453b8d | [
"MIT"
] | 40 | 2017-04-19T15:35:42.000Z | 2020-02-14T11:07:44.000Z | lib/docdog_web/controllers/document_controller.ex | wunsh/docdog-engine | a3044d21a6ac00098a295249358a367059453b8d | [
"MIT"
] | 43 | 2017-01-17T23:03:47.000Z | 2018-08-16T01:25:24.000Z | lib/docdog_web/controllers/document_controller.ex | wunsh/docdog-engine | a3044d21a6ac00098a295249358a367059453b8d | [
"MIT"
] | 6 | 2018-02-15T09:43:15.000Z | 2018-04-10T21:08:36.000Z | defmodule DocdogWeb.DocumentController do
use DocdogWeb, :controller
plug(DocdogWeb.AuthorizationRequiredPlug)
alias Docdog.Editor
alias Docdog.Editor.Document
def index(conn, %{"project_id" => project_id}) do
user = conn.assigns.current_user
project = Editor.get_project!(project_id)
documents ... | 33.586957 | 105 | 0.67055 |
5a512d5a5dd1b2ff467cec54cccfa05bd470a9c9 | 1,625 | ex | Elixir | web/web.ex | Namuraid/backend | 04a10248bfeb156eb291207931621b40585d8f7e | [
"MIT"
] | null | null | null | web/web.ex | Namuraid/backend | 04a10248bfeb156eb291207931621b40585d8f7e | [
"MIT"
] | null | null | null | web/web.ex | Namuraid/backend | 04a10248bfeb156eb291207931621b40585d8f7e | [
"MIT"
] | null | null | null | defmodule Namuraid.Web do
@moduledoc """
A module that keeps using definitions for controllers,
views and so on.
This can be used in your application as:
use Namuraid.Web, :controller
use Namuraid.Web, :view
The definitions below will be executed for every view,
controller, etc, so keep them ... | 19.817073 | 88 | 0.668308 |
5a514ece92290e71ce519ff8143bc15b06f891a8 | 2,298 | exs | Elixir | mix.exs | mbta/api | e22e0b29dfa4f600d1b630db1a391c37ad619245 | [
"MIT"
] | 62 | 2019-01-17T12:34:39.000Z | 2022-03-20T21:49:47.000Z | mix.exs | mbta/api | e22e0b29dfa4f600d1b630db1a391c37ad619245 | [
"MIT"
] | 375 | 2019-02-13T15:30:50.000Z | 2022-03-30T18:50:41.000Z | mix.exs | mbta/api | e22e0b29dfa4f600d1b630db1a391c37ad619245 | [
"MIT"
] | 14 | 2019-01-16T19:35:57.000Z | 2022-02-26T18:55:54.000Z | defmodule ApiUmbrella.Mixfile do
use Mix.Project
def project do
[
apps_path: "apps",
aliases: aliases(),
build_embedded: Mix.env() == :prod,
deps: deps(),
dialyzer: [
plt_add_deps: :app_tree,
flags: [
:race_conditions,
:unmatched_returns
... | 27.035294 | 94 | 0.559617 |
5a515bf5998438bd60b51c43695d34bb279465d2 | 1,016 | ex | Elixir | lib/liveman_web/helpers/ecto_helpers.ex | nimblehq/liveman-demo-api | e184349983f949c8434b8651f9223db597ef1025 | [
"MIT"
] | null | null | null | lib/liveman_web/helpers/ecto_helpers.ex | nimblehq/liveman-demo-api | e184349983f949c8434b8651f9223db597ef1025 | [
"MIT"
] | 19 | 2021-07-02T08:14:52.000Z | 2021-07-30T09:33:12.000Z | lib/liveman_web/helpers/ecto_helpers.ex | nimblehq/liveman | e184349983f949c8434b8651f9223db597ef1025 | [
"MIT"
] | null | null | null | defmodule LivemanWeb.EctoHelpers do
def pretty_errors(errors) do
Enum.map(errors, fn error ->
do_prettify(error)
end)
end
defp do_prettify({field_name, message}) when is_bitstring(message) do
human_field_name =
field_name
|> Atom.to_string()
|> String.replace("_", " ")
|... | 29.028571 | 79 | 0.692913 |
5a517eeef51b5baf398e193187b6fa98cf324ab9 | 3,738 | exs | Elixir | test/unit/stargate/producer_test.exs | jeffgrunewald/stargate | d80e5376a831c8fae232434e4d305784464f196a | [
"Apache-2.0"
] | 33 | 2019-11-09T09:12:18.000Z | 2022-02-24T05:22:20.000Z | test/unit/stargate/producer_test.exs | tspannhw/stargate | d80e5376a831c8fae232434e4d305784464f196a | [
"Apache-2.0"
] | 7 | 2019-11-28T06:52:18.000Z | 2021-10-07T09:09:16.000Z | test/unit/stargate/producer_test.exs | tspannhw/stargate | d80e5376a831c8fae232434e4d305784464f196a | [
"Apache-2.0"
] | 7 | 2020-06-30T10:37:59.000Z | 2021-11-26T06:54:23.000Z | defmodule Stargate.ProducerTest do
use ExUnit.Case
setup do
port = Enum.random(49_152..65_535)
path = "ws/v2/producer/persistent/default/public/foobar"
{:ok, server} = MockSocket.Supervisor.start_link(port: port, path: path, source: self())
on_exit(fn ->
kill(server)
end)
[port: po... | 28.105263 | 130 | 0.539593 |
5a51883d95a1d5bcc8d07ab63d1cd176ec5d951c | 8,908 | ex | Elixir | clients/dfa_reporting/lib/google_api/dfa_reporting/v35/api/change_logs.ex | renovate-bot/elixir-google-api | 1da34cd39b670c99f067011e05ab90af93fef1f6 | [
"Apache-2.0"
] | 1 | 2021-12-20T03:40:53.000Z | 2021-12-20T03:40:53.000Z | clients/dfa_reporting/lib/google_api/dfa_reporting/v35/api/change_logs.ex | swansoffiee/elixir-google-api | 9ea6d39f273fb430634788c258b3189d3613dde0 | [
"Apache-2.0"
] | 1 | 2020-08-18T00:11:23.000Z | 2020-08-18T00:44:16.000Z | clients/dfa_reporting/lib/google_api/dfa_reporting/v35/api/change_logs.ex | dazuma/elixir-google-api | 6a9897168008efe07a6081d2326735fe332e522c | [
"Apache-2.0"
] | null | null | null | # Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, s... | 50.044944 | 446 | 0.636619 |
5a518de88f8fbe572104e1e76abbebac1bc1d7aa | 105 | ex | Elixir | ch2/private_fun.ex | TheEndIsNear/ElixirInAction | 9b18ebd4845723935e03ec2a0c3cf869aa955541 | [
"MIT"
] | null | null | null | ch2/private_fun.ex | TheEndIsNear/ElixirInAction | 9b18ebd4845723935e03ec2a0c3cf869aa955541 | [
"MIT"
] | null | null | null | ch2/private_fun.ex | TheEndIsNear/ElixirInAction | 9b18ebd4845723935e03ec2a0c3cf869aa955541 | [
"MIT"
] | null | null | null | defmodule TestPrivate do
def double(a) do
sum(a, a)
end
defp sum(a, b) do
a + b
end
end
| 10.5 | 24 | 0.580952 |
5a51ac128c6e120c95eeac199ea8fda5f664cd3c | 432 | ex | Elixir | app/lib/reading_list/reading_list/media.ex | benjohns1/reading-list | edd87616b9f244d598fbcfddcf60c284021c140a | [
"MIT"
] | null | null | null | app/lib/reading_list/reading_list/media.ex | benjohns1/reading-list | edd87616b9f244d598fbcfddcf60c284021c140a | [
"MIT"
] | null | null | null | app/lib/reading_list/reading_list/media.ex | benjohns1/reading-list | edd87616b9f244d598fbcfddcf60c284021c140a | [
"MIT"
] | null | null | null | defmodule ReadingList.ReadingList.Media do
use Ecto.Schema
import Ecto.Changeset
schema "media" do
field :author, :string
field :description, :string
field :link, :string
field :title, :string
timestamps()
end
@doc false
def changeset(media, attrs) do
media
|> cast(attrs, [:t... | 19.636364 | 64 | 0.664352 |
5a51ad02ec4eaaf22739dabfea3a5d6b85bc28f8 | 9,298 | ex | Elixir | apps/state/lib/state/schedule.ex | losvedir/api | a9bacff911704f53fac238c0eb23b7d6d6d3b70e | [
"MIT"
] | null | null | null | apps/state/lib/state/schedule.ex | losvedir/api | a9bacff911704f53fac238c0eb23b7d6d6d3b70e | [
"MIT"
] | null | null | null | apps/state/lib/state/schedule.ex | losvedir/api | a9bacff911704f53fac238c0eb23b7d6d6d3b70e | [
"MIT"
] | null | null | null | defmodule State.Schedule do
@moduledoc "State for Schedules"
use State.Server,
indices: [:trip_id, :stop_id],
recordable: Model.Schedule
require Logger
alias Events.Gather
alias Model.Schedule
alias Parse.StopTimes
alias State.Trip
@fetch_stop_times {:fetch, "stop_times.txt"}
@subscriptions... | 30.286645 | 87 | 0.675737 |
5a51c677a243ae55f1bd63b456ec1248312b792f | 2,637 | exs | Elixir | mix.exs | xadhoom/xema | 267fbdbdd30c3e9a99542141d3959dd6cd7f5708 | [
"MIT"
] | null | null | null | mix.exs | xadhoom/xema | 267fbdbdd30c3e9a99542141d3959dd6cd7f5708 | [
"MIT"
] | null | null | null | mix.exs | xadhoom/xema | 267fbdbdd30c3e9a99542141d3959dd6cd7f5708 | [
"MIT"
] | null | null | null | defmodule Xema.Mixfile do
use Mix.Project
def project do
[
app: :xema,
version: "0.14.2",
elixir: "~> 1.7",
build_embedded: Mix.env() == :prod,
start_permanent: Mix.env() == :prod,
deps: deps(),
description: description(),
package: package(),
elixirc_paths:... | 24.877358 | 65 | 0.513083 |
5a51f0dd4c9afa1ced67d37c37f83e24618feec3 | 13,536 | ex | Elixir | lib/exq/manager/server.ex | blueshift-labs/exq | 57973ec3e83f9a505fc83385b645bf2e658b8cdd | [
"Apache-2.0"
] | null | null | null | lib/exq/manager/server.ex | blueshift-labs/exq | 57973ec3e83f9a505fc83385b645bf2e658b8cdd | [
"Apache-2.0"
] | null | null | null | lib/exq/manager/server.ex | blueshift-labs/exq | 57973ec3e83f9a505fc83385b645bf2e658b8cdd | [
"Apache-2.0"
] | null | null | null | defmodule Exq.Manager.Server do
@moduledoc """
The Manager module is the main orchestrator for the system
It is also the entry point Pid process used by the client to interact
with the Exq system.
It's responsibilities include:
* Handle interaction with client and delegate to responsible sub-system
... | 33.095355 | 101 | 0.653664 |
5a5219d044263583d3a701167f3039b3177e30e6 | 2,186 | ex | Elixir | clients/sheets/lib/google_api/sheets/v4/model/date_time_rule.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/sheets/lib/google_api/sheets/v4/model/date_time_rule.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/sheets/lib/google_api/sheets/v4/model/date_time_rule.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... | 31.681159 | 94 | 0.612534 |
5a52303b0e838d1e421f2c6d2ce17ce92b2e50db | 37,436 | ex | Elixir | lib/elixir/lib/task.ex | Kartstig/elixir | 223e518813f2f32545aebb4fe5447041c908fc5e | [
"Apache-2.0"
] | null | null | null | lib/elixir/lib/task.ex | Kartstig/elixir | 223e518813f2f32545aebb4fe5447041c908fc5e | [
"Apache-2.0"
] | null | null | null | lib/elixir/lib/task.ex | Kartstig/elixir | 223e518813f2f32545aebb4fe5447041c908fc5e | [
"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... | 34.282051 | 106 | 0.672401 |
5a52535b47a7ee096b57154b0bb6994bb9229bb8 | 1,261 | ex | Elixir | apps/service_broadcast/lib/broadcast_web/views/error_helpers.ex | rucker/hindsight | 876a5d344c5d8eebbea37684ee07e0a91e4430f0 | [
"Apache-2.0"
] | 12 | 2020-01-27T19:43:02.000Z | 2021-07-28T19:46:29.000Z | apps/service_broadcast/lib/broadcast_web/views/error_helpers.ex | rucker/hindsight | 876a5d344c5d8eebbea37684ee07e0a91e4430f0 | [
"Apache-2.0"
] | 81 | 2020-01-28T18:07:23.000Z | 2021-11-22T02:12:13.000Z | apps/service_broadcast/lib/broadcast_web/views/error_helpers.ex | rucker/hindsight | 876a5d344c5d8eebbea37684ee07e0a91e4430f0 | [
"Apache-2.0"
] | 10 | 2020-02-13T21:24:09.000Z | 2020-05-21T18:39:35.000Z | defmodule BroadcastWeb.ErrorHelpers do
@moduledoc """
Conveniences for translating and building error messages.
"""
@doc """
Translates an error message using gettext.
"""
@dialyzer {:no_return, translate_error: 1}
def translate_error({msg, opts}) do
# When using gettext, we typically pass the stri... | 36.028571 | 78 | 0.674861 |
5a526dde299b55cef7abe8d90ac10500ac10a67e | 2,448 | ex | Elixir | lib/bodyguard/plug/authorize.ex | jslegend/bodyguard-master | 242a14245640a16ee6164e96ac03ae35fba7e806 | [
"MIT"
] | 1 | 2017-11-06T19:07:06.000Z | 2017-11-06T19:07:06.000Z | lib/bodyguard/plug/authorize.ex | jslegend/bodyguard-master | 242a14245640a16ee6164e96ac03ae35fba7e806 | [
"MIT"
] | null | null | null | lib/bodyguard/plug/authorize.ex | jslegend/bodyguard-master | 242a14245640a16ee6164e96ac03ae35fba7e806 | [
"MIT"
] | null | null | null | defmodule Bodyguard.Plug.Authorize do
@behaviour Plug
@moduledoc """
Perform authorization in a Plug pipeline.
## Options
* `policy` *required* - the policy (or context) module
* `action` *required* - the action to authorize
* `user` - a 1-arity function which accepts the connection and returns a
... | 32.64 | 132 | 0.669935 |
5a527fb71401c8aa2d8994e1d41f8962d4743049 | 6,324 | exs | Elixir | test/changelog_web/controllers/admin/news_item_controller_test.exs | type1fool/changelog.com | fbec3528cc3f5adfdc75b008bb92b17efc4f248f | [
"MIT"
] | 1 | 2020-05-20T16:58:17.000Z | 2020-05-20T16:58:17.000Z | test/changelog_web/controllers/admin/news_item_controller_test.exs | type1fool/changelog.com | fbec3528cc3f5adfdc75b008bb92b17efc4f248f | [
"MIT"
] | null | null | null | test/changelog_web/controllers/admin/news_item_controller_test.exs | type1fool/changelog.com | fbec3528cc3f5adfdc75b008bb92b17efc4f248f | [
"MIT"
] | null | null | null | defmodule ChangelogWeb.Admin.NewsItemControllerTest do
use ChangelogWeb.ConnCase
import Mock
alias Changelog.{Buffer, NewsItem, NewsQueue}
@valid_attrs %{type: :project, headline: "Ruby on Rails", url: "https://rubyonrails.org", logger_id: 1}
@invalid_attrs %{type: :project, headline: "Ruby on Rails", url:... | 36.344828 | 178 | 0.690702 |
5a5280b4f4f3a821a4b262aaf24006738cd44faf | 1,264 | ex | Elixir | lib/radixir/core/request/get_mempool_transaction.ex | radixir/radixir | 703034330e857bc084b78dd927ec611c3ea54349 | [
"Apache-2.0"
] | 16 | 2022-01-05T20:41:55.000Z | 2022-03-25T09:06:43.000Z | lib/radixir/core/request/get_mempool_transaction.ex | radixir/radixir | 703034330e857bc084b78dd927ec611c3ea54349 | [
"Apache-2.0"
] | null | null | null | lib/radixir/core/request/get_mempool_transaction.ex | radixir/radixir | 703034330e857bc084b78dd927ec611c3ea54349 | [
"Apache-2.0"
] | 1 | 2022-02-10T21:55:26.000Z | 2022-02-10T21:55:26.000Z | defmodule Radixir.Core.Request.GetMempoolTransaction do
@moduledoc false
# @moduledoc """
# Methods to create each map in `GetMempoolTransaction` request body.
# """
alias Radixir.StitchPlan
@type stitch_plans :: list(keyword)
@type params :: keyword
@doc """
Generates stitch plan for `network_ident... | 38.30303 | 138 | 0.727848 |
5a52c5da071ec920935a2c97512cc2eccf6e5342 | 9,039 | ex | Elixir | clients/logging/lib/google_api/logging/v2/model/metric_descriptor.ex | MasashiYokota/elixir-google-api | 975dccbff395c16afcb62e7a8e411fbb58e9ab01 | [
"Apache-2.0"
] | null | null | null | clients/logging/lib/google_api/logging/v2/model/metric_descriptor.ex | MasashiYokota/elixir-google-api | 975dccbff395c16afcb62e7a8e411fbb58e9ab01 | [
"Apache-2.0"
] | null | null | null | clients/logging/lib/google_api/logging/v2/model/metric_descriptor.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... | 117.38961 | 3,288 | 0.740679 |
5a530240f5a95e6dd171ec242e863082bcf1198c | 1,564 | ex | Elixir | web/controllers/topic_controller.ex | JumboLove/dotad | a3e5ec14cb5c784f492b38cc37fe2f03495a957f | [
"MIT"
] | null | null | null | web/controllers/topic_controller.ex | JumboLove/dotad | a3e5ec14cb5c784f492b38cc37fe2f03495a957f | [
"MIT"
] | null | null | null | web/controllers/topic_controller.ex | JumboLove/dotad | a3e5ec14cb5c784f492b38cc37fe2f03495a957f | [
"MIT"
] | null | null | null | defmodule Discuss.TopicController do
use Discuss.Web, :controller
alias Discuss.Topic
def index(conn, _params) do
IO.inspect(conn.assigns)
topics = Repo.all(Topic)
render conn, "index.html", topics: topics
end
def new(conn, _params) do
changeset = Topic.changeset(%Topic{}, %{})
render conn, "new.html... | 24.061538 | 65 | 0.652174 |
5a531608215e36728df9faac722ac5d0f7bcfde9 | 1,650 | ex | Elixir | clients/container_analysis/lib/google_api/container_analysis/v1beta1/model/layer.ex | mcrumm/elixir-google-api | 544f22797cec52b3a23dfb6e39117f0018448610 | [
"Apache-2.0"
] | null | null | null | clients/container_analysis/lib/google_api/container_analysis/v1beta1/model/layer.ex | mcrumm/elixir-google-api | 544f22797cec52b3a23dfb6e39117f0018448610 | [
"Apache-2.0"
] | 1 | 2020-12-18T09:25:12.000Z | 2020-12-18T09:25:12.000Z | clients/container_analysis/lib/google_api/container_analysis/v1beta1/model/layer.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 | 133 | 0.730909 |
5a534d00870ffc51d5bf197ab101957304c1face | 522 | exs | Elixir | test/bech32_test.exs | radixpool/bech32-elixir | 117acdaf78f2a27ff4e054334aa35d1e20df9828 | [
"MIT"
] | 3 | 2019-10-03T11:16:36.000Z | 2021-05-25T10:49:16.000Z | test/bech32_test.exs | radixpool/bech32-elixir | 117acdaf78f2a27ff4e054334aa35d1e20df9828 | [
"MIT"
] | null | null | null | test/bech32_test.exs | radixpool/bech32-elixir | 117acdaf78f2a27ff4e054334aa35d1e20df9828 | [
"MIT"
] | 3 | 2020-09-02T22:43:53.000Z | 2021-09-13T08:38:21.000Z | defmodule Bech32Test do
use ExUnit.Case
doctest Bech32
test "encoding" do
addr = Bech32.encode("ckt", <<1, 0, 248, 233, 196, 92, 241, 52, 177, 249, 178, 100, 1, 226, 254, 133, 46, 33, 214, 246, 151, 234>>)
assert addr === "ckt1qyq036wytncnfv0ekfjqrch7s5hzr4hkjl4qd3tkj9"
end
test "decoding" do
as... | 32.625 | 195 | 0.651341 |
5a535cedf62fa86c48cc59b4e5aa3acd1273b4e8 | 908 | ex | Elixir | clients/double_click_bid_manager/lib/google_api/double_click_bid_manager/v1/metadata.ex | jechol/elixir-google-api | 0290b683dfc6491ca2ef755a80bc329378738d03 | [
"Apache-2.0"
] | null | null | null | clients/double_click_bid_manager/lib/google_api/double_click_bid_manager/v1/metadata.ex | jechol/elixir-google-api | 0290b683dfc6491ca2ef755a80bc329378738d03 | [
"Apache-2.0"
] | null | null | null | clients/double_click_bid_manager/lib/google_api/double_click_bid_manager/v1/metadata.ex | jechol/elixir-google-api | 0290b683dfc6491ca2ef755a80bc329378738d03 | [
"Apache-2.0"
] | null | null | null | # Copyright 2020 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, s... | 33.62963 | 74 | 0.765419 |
5a5363239be71facddbf3779b50d7f3d9b757755 | 2,383 | ex | Elixir | lib/cep/client.ex | douglascamata/cep | 042aa6d2bcb64b459ac6ac281add2f2f753a6877 | [
"MIT"
] | 11 | 2016-03-23T20:34:19.000Z | 2019-07-16T13:21:48.000Z | lib/cep/client.ex | douglascamata/cep | 042aa6d2bcb64b459ac6ac281add2f2f753a6877 | [
"MIT"
] | 5 | 2016-03-22T05:35:46.000Z | 2019-04-02T16:44:00.000Z | lib/cep/client.ex | douglascamata/cep | 042aa6d2bcb64b459ac6ac281add2f2f753a6877 | [
"MIT"
] | 3 | 2019-03-26T18:54:59.000Z | 2020-07-06T22:41:51.000Z | defmodule Cep.Client do
@moduledoc """
Provides a function `get_address/1` to query addreses of a given cep.
"""
@doc """
Gets the address related to a given CEP.
## Parameters
- cep: The CEP code
## Return value
It returns a Cep.Address when the CEP was found.
### Errors
It returns... | 24.070707 | 79 | 0.638691 |
5a5364c5f31391c47cbb88469c104301a52eb5f4 | 193 | ex | Elixir | skippy/eagle/lib/eagle.ex | mashbytes/baby_zoo | 4554890242a2493d17d9b1c1f4cc90d7ad1e637e | [
"MIT"
] | null | null | null | skippy/eagle/lib/eagle.ex | mashbytes/baby_zoo | 4554890242a2493d17d9b1c1f4cc90d7ad1e637e | [
"MIT"
] | 5 | 2020-07-17T23:35:42.000Z | 2021-05-10T07:00:10.000Z | skippy/eagle/lib/eagle.ex | mashbytes/baby_zoo | 4554890242a2493d17d9b1c1f4cc90d7ad1e637e | [
"MIT"
] | null | null | null | defmodule Eagle do
@moduledoc """
Documentation for Eagle.
"""
@doc """
Hello world.
## Examples
iex> Eagle.hello()
:world
"""
def hello do
:world
end
end
| 10.157895 | 26 | 0.549223 |
5a538613ef514e19de85c30e9aa337c56f49f665 | 714 | ex | Elixir | lib/liqen_core/accounts/medium_credential.ex | exacs/liqen_core | bba1727ff3b3061ad5a0ecb668eb3038070836a4 | [
"MIT"
] | null | null | null | lib/liqen_core/accounts/medium_credential.ex | exacs/liqen_core | bba1727ff3b3061ad5a0ecb668eb3038070836a4 | [
"MIT"
] | null | null | null | lib/liqen_core/accounts/medium_credential.ex | exacs/liqen_core | bba1727ff3b3061ad5a0ecb668eb3038070836a4 | [
"MIT"
] | null | null | null | defmodule LiqenCore.Accounts.MediumCredential do
use Ecto.Schema
import Ecto.Changeset
alias LiqenCore.Accounts.{MediumCredential,
User}
@moduledoc """
LiqenCredential stores the information to identify a person using the
information stored at Medium
"""
schema "medium_crede... | 24.62069 | 71 | 0.677871 |
5a53972b6e72be71b7cb542dae9ff1b8a17b6721 | 6,043 | ex | Elixir | clients/dfa_reporting/lib/google_api/dfa_reporting/v33/api/operating_systems.ex | kolorahl/elixir-google-api | 46bec1e092eb84c6a79d06c72016cb1a13777fa6 | [
"Apache-2.0"
] | null | null | null | clients/dfa_reporting/lib/google_api/dfa_reporting/v33/api/operating_systems.ex | kolorahl/elixir-google-api | 46bec1e092eb84c6a79d06c72016cb1a13777fa6 | [
"Apache-2.0"
] | null | null | null | clients/dfa_reporting/lib/google_api/dfa_reporting/v33/api/operating_systems.ex | kolorahl/elixir-google-api | 46bec1e092eb84c6a79d06c72016cb1a13777fa6 | [
"Apache-2.0"
] | null | null | null | # Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, s... | 40.019868 | 187 | 0.642396 |
5a53aa99e433e772a75a7d76199a454a7e010662 | 17,577 | ex | Elixir | clients/plus_domains/lib/google_api/plus_domains/v1/api/circles.ex | mocknen/elixir-google-api | dac4877b5da2694eca6a0b07b3bd0e179e5f3b70 | [
"Apache-2.0"
] | null | null | null | clients/plus_domains/lib/google_api/plus_domains/v1/api/circles.ex | mocknen/elixir-google-api | dac4877b5da2694eca6a0b07b3bd0e179e5f3b70 | [
"Apache-2.0"
] | null | null | null | clients/plus_domains/lib/google_api/plus_domains/v1/api/circles.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... | 41.750594 | 225 | 0.673266 |
5a53b8483b8941ddc0c798da5a548ccab81033e9 | 1,486 | ex | Elixir | mix/tasks/install_cldr_data.ex | KineticCafe/cldr | 7b84cd85564bca4a2c4e01c02ee0aa284bf07367 | [
"Apache-2.0"
] | 179 | 2019-06-16T09:16:00.000Z | 2022-03-30T04:04:55.000Z | mix/tasks/install_cldr_data.ex | KineticCafe/cldr | 7b84cd85564bca4a2c4e01c02ee0aa284bf07367 | [
"Apache-2.0"
] | 46 | 2019-06-09T02:35:58.000Z | 2022-03-08T10:39:08.000Z | mix/tasks/install_cldr_data.ex | KineticCafe/cldr | 7b84cd85564bca4a2c4e01c02ee0aa284bf07367 | [
"Apache-2.0"
] | 14 | 2020-03-03T16:35:50.000Z | 2022-02-27T14:01:40.000Z | defmodule Mix.Tasks.Cldr.Install.Locales do
@moduledoc """
Installs the cldr core data and configured locales into the application. By
default it installs into the ./priv/cldr directory.
## Arguments
* `backend` is the name of any backend module for which
the locales will be installed. This is a requir... | 24.360656 | 78 | 0.691117 |
5a53c7640a12ca59f94a758ed42ff202c6819cae | 567 | exs | Elixir | day13/mix.exs | bjorng/advent-of-code-2017 | bd58a36864a4d82809253770f8a6d0c4e02cb59a | [
"Apache-2.0"
] | null | null | null | day13/mix.exs | bjorng/advent-of-code-2017 | bd58a36864a4d82809253770f8a6d0c4e02cb59a | [
"Apache-2.0"
] | null | null | null | day13/mix.exs | bjorng/advent-of-code-2017 | bd58a36864a4d82809253770f8a6d0c4e02cb59a | [
"Apache-2.0"
] | null | null | null | defmodule Day13.MixProject do
use Mix.Project
def project do
[
app: :day13,
version: "0.1.0",
elixir: "~> 1.8",
start_permanent: Mix.env() == :prod,
deps: deps()
]
end
# Run "mix help compile.app" to learn about applications.
def application do
[
extra_applica... | 19.551724 | 87 | 0.573192 |
5a53f618859cac5be53cb4997edbf4165a9b88a4 | 1,583 | ex | Elixir | clients/chrome_policy/lib/google_api/chrome_policy/v1/model/google_protobuf_empty.ex | renovate-bot/elixir-google-api | 1da34cd39b670c99f067011e05ab90af93fef1f6 | [
"Apache-2.0"
] | 1 | 2021-12-20T03:40:53.000Z | 2021-12-20T03:40:53.000Z | clients/chrome_policy/lib/google_api/chrome_policy/v1/model/google_protobuf_empty.ex | swansoffiee/elixir-google-api | 9ea6d39f273fb430634788c258b3189d3613dde0 | [
"Apache-2.0"
] | 1 | 2020-08-18T00:11:23.000Z | 2020-08-18T00:44:16.000Z | clients/chrome_policy/lib/google_api/chrome_policy/v1/model/google_protobuf_empty.ex | dazuma/elixir-google-api | 6a9897168008efe07a6081d2326735fe332e522c | [
"Apache-2.0"
] | null | null | null | # Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, s... | 37.690476 | 345 | 0.766267 |
5a5424b40be32ff5f312369383e6fab9aea1c4fc | 1,334 | exs | Elixir | apps/sms_code/mix.exs | puppetlabs/openrobby | a4b70939ee1b878d44cb09d757b7f72e7109ac5d | [
"Apache-2.0"
] | 3 | 2021-04-16T21:54:55.000Z | 2021-04-30T22:15:41.000Z | apps/sms_code/mix.exs | puppetlabs/openrobby | a4b70939ee1b878d44cb09d757b7f72e7109ac5d | [
"Apache-2.0"
] | 1 | 2021-06-29T15:54:19.000Z | 2021-06-29T15:54:19.000Z | apps/sms_code/mix.exs | puppetlabs/openrobby | a4b70939ee1b878d44cb09d757b7f72e7109ac5d | [
"Apache-2.0"
] | 2 | 2021-04-16T22:23:16.000Z | 2021-05-26T15:52:55.000Z | defmodule SmsCode.Mixfile do
use Mix.Project
def project do
[
app: :sms_code,
version: get_version(),
deps_path: "../../deps",
lockfile: "../../mix.lock",
elixir: "~> 1.0",
build_embedded: Mix.env() == :prod,
start_permanent: Mix.env() == :prod,
deps: deps()
... | 24.254545 | 77 | 0.564468 |
5a544cd5651d8e7954bbf4738f444259fe3946e3 | 1,713 | ex | Elixir | clients/vision/lib/google_api/vision/v1/model/batch_annotate_files_response.ex | matehat/elixir-google-api | c1b2523c2c4cdc9e6ca4653ac078c94796b393c3 | [
"Apache-2.0"
] | 1 | 2018-12-03T23:43:10.000Z | 2018-12-03T23:43:10.000Z | clients/vision/lib/google_api/vision/v1/model/batch_annotate_files_response.ex | matehat/elixir-google-api | c1b2523c2c4cdc9e6ca4653ac078c94796b393c3 | [
"Apache-2.0"
] | null | null | null | clients/vision/lib/google_api/vision/v1/model/batch_annotate_files_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 ... | 35.6875 | 179 | 0.757735 |
5a546daad7b13f77d437265802ed38330fcada6c | 235 | exs | Elixir | priv/repo/migrations/00620170502203020_create_permissions_permission.exs | josephkabraham/ucx_ucc | 0dbd9e3eb5940336b4870cff033482ceba5f6ee7 | [
"MIT"
] | null | null | null | priv/repo/migrations/00620170502203020_create_permissions_permission.exs | josephkabraham/ucx_ucc | 0dbd9e3eb5940336b4870cff033482ceba5f6ee7 | [
"MIT"
] | null | null | null | priv/repo/migrations/00620170502203020_create_permissions_permission.exs | josephkabraham/ucx_ucc | 0dbd9e3eb5940336b4870cff033482ceba5f6ee7 | [
"MIT"
] | null | null | null | defmodule UcxUcc.Repo.Migrations.CreateUcxUcc.Permissions.Permission do
use Ecto.Migration
def change do
create table(:permissions) do
add :name, :string
end
create unique_index(:permissions, [:name])
end
end
| 19.583333 | 71 | 0.723404 |
5a546f40329247122e7af56f9ae77313b3bbe718 | 1,270 | ex | Elixir | apps/demon_spirit_web/lib/demon_spirit_web/router.ex | mreishus/demon_spirit_umbrella | 1ab9161427361ac7d35132fce2aed36923896a4b | [
"MIT"
] | 12 | 2019-09-17T13:47:57.000Z | 2021-12-11T17:11:11.000Z | apps/demon_spirit_web/lib/demon_spirit_web/router.ex | mreishus/demon_spirit_umbrella | 1ab9161427361ac7d35132fce2aed36923896a4b | [
"MIT"
] | 181 | 2019-10-15T01:21:44.000Z | 2021-08-31T19:26:54.000Z | apps/demon_spirit_web/lib/demon_spirit_web/router.ex | mreishus/demon_spirit_umbrella | 1ab9161427361ac7d35132fce2aed36923896a4b | [
"MIT"
] | 2 | 2020-07-11T02:18:46.000Z | 2021-05-31T10:46:39.000Z | defmodule DemonSpiritWeb.Router do
use DemonSpiritWeb, :router
import Plug.BasicAuth
import Phoenix.LiveDashboard.Router
pipeline :browser do
plug(:accepts, ["html"])
plug(:fetch_session)
plug(:fetch_flash)
plug(:protect_from_forgery)
plug(:put_secure_browser_headers)
plug(DemonSpiritWe... | 24.423077 | 93 | 0.679528 |
5a5485b51e6df74aee7f5e1413b14676c5f1d559 | 35,288 | ex | Elixir | lib/elixir/lib/inspect/algebra.ex | bruteforcecat/elixir | 2013b4dc34cd65953615f71e721e2e9c3949ec85 | [
"Apache-2.0"
] | null | null | null | lib/elixir/lib/inspect/algebra.ex | bruteforcecat/elixir | 2013b4dc34cd65953615f71e721e2e9c3949ec85 | [
"Apache-2.0"
] | null | null | null | lib/elixir/lib/inspect/algebra.ex | bruteforcecat/elixir | 2013b4dc34cd65953615f71e721e2e9c3949ec85 | [
"Apache-2.0"
] | null | null | null | defmodule Inspect.Opts do
@moduledoc """
Defines the options used by the `Inspect` protocol.
The following fields are available:
* `:base` - prints integers as `:binary`, `:octal`, `:decimal`, or `:hex`,
defaults to `:decimal`. When inspecting binaries any `:base` other than
`:decimal` implies `... | 33.480076 | 101 | 0.618992 |
5a549727c206f92486bd7d216790a39f27f10f2d | 3,248 | exs | Elixir | test/oauther_test.exs | lobo-tuerto/oauther | c6eceba8ef2576fbd2d6039b190e0e6aad6b0d0e | [
"0BSD"
] | 2 | 2021-07-25T15:48:45.000Z | 2021-08-17T16:11:52.000Z | test/oauther_test.exs | lobo-tuerto/oauther | c6eceba8ef2576fbd2d6039b190e0e6aad6b0d0e | [
"0BSD"
] | null | null | null | test/oauther_test.exs | lobo-tuerto/oauther | c6eceba8ef2576fbd2d6039b190e0e6aad6b0d0e | [
"0BSD"
] | 3 | 2021-07-01T17:45:32.000Z | 2021-08-17T02:35:51.000Z | defmodule OAutherTest do
use ExUnit.Case
test "HMAC-SHA1 signature" do
creds =
OAuther.credentials(
consumer_secret: "kd94hf93k423kf44",
token_secret: "pfkkdhi9sl3r4s00",
consumer_key: "dpf43f3p2l4k3l03",
token: "nnch734d00sl2jdk"
)
params = protocol_params(cred... | 28.243478 | 187 | 0.658559 |
5a54a2d6a5b0fa30cdd47f800860652aa309f5da | 349 | ex | Elixir | code examples/example-15-8.ex | kujua/erlang-elixir-imperative-bookcompanion | 7bc9f033bacd0f8744ec6bcee3932794d594fe69 | [
"Apache-2.0"
] | 8 | 2016-08-14T12:35:16.000Z | 2021-01-26T04:05:31.000Z | code examples/example-15-8.ex | kujua/erlang-elixir-imperative-bookcompanion | 7bc9f033bacd0f8744ec6bcee3932794d594fe69 | [
"Apache-2.0"
] | null | null | null | code examples/example-15-8.ex | kujua/erlang-elixir-imperative-bookcompanion | 7bc9f033bacd0f8744ec6bcee3932794d594fe69 | [
"Apache-2.0"
] | 5 | 2016-08-18T22:12:19.000Z | 2020-02-17T18:52:41.000Z | # from https://github.com/elixir-lang/ecto/blob/master/lib/ecto/query.ex
defmacro from(expr, kw \\ []) do
unless Keyword.keyword?(kw) do
raise ArgumentError, "second argument to `from` must be a keyword list"
end
{quoted, binds, count_bind} = From.build(expr, __CALLER__)
from(kw, __CALLER__, coun... | 34.9 | 77 | 0.696275 |
5a54b070173732fbe8b2794c0b3a281ebc92c15b | 4,662 | exs | Elixir | integration_test/sql/sandbox.exs | dgvncsz0f/ecto | bae06fe650328cc1060c09fe889a2de9a10edb1b | [
"Apache-2.0"
] | null | null | null | integration_test/sql/sandbox.exs | dgvncsz0f/ecto | bae06fe650328cc1060c09fe889a2de9a10edb1b | [
"Apache-2.0"
] | null | null | null | integration_test/sql/sandbox.exs | dgvncsz0f/ecto | bae06fe650328cc1060c09fe889a2de9a10edb1b | [
"Apache-2.0"
] | 1 | 2018-09-21T16:05:29.000Z | 2018-09-21T16:05:29.000Z | defmodule Ecto.Integration.SandboxTest do
use ExUnit.Case
alias Ecto.Adapters.SQL.Sandbox
alias Ecto.Integration.{PoolRepo, TestRepo}
alias Ecto.Integration.Post
import ExUnit.CaptureLog
test "raises if repo is not started or not exist" do
assert_raise RuntimeError, ~r"could not lookup UnknownRepo be... | 28.956522 | 97 | 0.688117 |
5a54b558f3f9355b2ba3c326a1ec02683922fd3b | 1,249 | ex | Elixir | samples/client/petstore/elixir/lib/openapi_petstore/model/format_test.ex | MalcolmScoffable/openapi-generator | 73605a0c0e0c825286c95123c63678ba75b44d5c | [
"Apache-2.0"
] | 4 | 2020-07-24T07:02:57.000Z | 2022-01-08T17:37:38.000Z | samples/client/petstore/elixir/lib/openapi_petstore/model/format_test.ex | MalcolmScoffable/openapi-generator | 73605a0c0e0c825286c95123c63678ba75b44d5c | [
"Apache-2.0"
] | 10 | 2021-03-09T14:12:46.000Z | 2022-02-27T11:42:16.000Z | samples/client/petstore/elixir/lib/openapi_petstore/model/format_test.ex | MalcolmScoffable/openapi-generator | 73605a0c0e0c825286c95123c63678ba75b44d5c | [
"Apache-2.0"
] | 5 | 2020-11-26T05:13:41.000Z | 2021-04-09T15:58:18.000Z | # NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
# https://openapi-generator.tech
# Do not edit the class manually.
defmodule OpenapiPetstore.Model.FormatTest do
@moduledoc """
"""
@derive [Poison.Encoder]
defstruct [
:"integer",
:"int32",
:"int64",
... | 22.709091 | 91 | 0.57486 |
5a54c884aec77022da08d9c8c1fe23b8474d63c3 | 2,148 | ex | Elixir | clients/tasks/lib/google_api/tasks/v1/deserializer.ex | GoNZooo/elixir-google-api | cf3ad7392921177f68091f3d9001f1b01b92f1cc | [
"Apache-2.0"
] | null | null | null | clients/tasks/lib/google_api/tasks/v1/deserializer.ex | GoNZooo/elixir-google-api | cf3ad7392921177f68091f3d9001f1b01b92f1cc | [
"Apache-2.0"
] | null | null | null | clients/tasks/lib/google_api/tasks/v1/deserializer.ex | GoNZooo/elixir-google-api | cf3ad7392921177f68091f3d9001f1b01b92f1cc | [
"Apache-2.0"
] | 1 | 2018-07-28T20:50:50.000Z | 2018-07-28T20:50:50.000Z | # Copyright 2017 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in... | 35.8 | 139 | 0.687616 |
5a5534f266a77296edd2a8aa57afd2732782e101 | 2,776 | ex | Elixir | clients/docs/lib/google_api/docs/v1/model/page_break.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2021-12-20T03:40:53.000Z | 2021-12-20T03:40:53.000Z | clients/docs/lib/google_api/docs/v1/model/page_break.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2020-08-18T00:11:23.000Z | 2020-08-18T00:44:16.000Z | clients/docs/lib/google_api/docs/v1/model/page_break.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... | 48.701754 | 297 | 0.729467 |
5a553caec72f7c2365f6f05d2053257cf6c677b6 | 188 | ex | Elixir | lib/urldome/entities/url.ex | Brinuz/url-dome | 6f01b598f51ccad422e7172b99a26fcc58c86a72 | [
"MIT"
] | 3 | 2020-06-26T16:17:43.000Z | 2020-08-17T08:40:27.000Z | lib/urldome/entities/url.ex | Brinuz/url-dome | 6f01b598f51ccad422e7172b99a26fcc58c86a72 | [
"MIT"
] | null | null | null | lib/urldome/entities/url.ex | Brinuz/url-dome | 6f01b598f51ccad422e7172b99a26fcc58c86a72 | [
"MIT"
] | null | null | null | defmodule Urldome.Entities.Url do
defstruct hash: nil, url: nil
@type t(hash, url) :: %__MODULE__{hash: hash, url: url}
@type t :: %__MODULE__{hash: String.t(), url: String.t()}
end
| 31.333333 | 59 | 0.670213 |
5a554505415224ce82eb682cdaaeaf635026642f | 992 | exs | Elixir | plt_test_app/config/config.exs | bcdevices/ly11_system_x86_64 | e4e7e86f9987d4f3fd298c3ee8d4135ab844994b | [
"Apache-2.0"
] | 5 | 2020-08-15T20:14:11.000Z | 2021-11-12T12:09:33.000Z | plt_test_app/config/config.exs | bcdevices/ly11_system_x86_64 | e4e7e86f9987d4f3fd298c3ee8d4135ab844994b | [
"Apache-2.0"
] | 6 | 2020-04-02T14:30:52.000Z | 2021-09-29T00:03:23.000Z | plt_test_app/config/config.exs | bcdevices/ly11-system-rpi4 | 2a6d14c151f11939e780502d5b82c21f2d8584a3 | [
"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.
#
# This configuration file is loaded before any dependency and
# is restricted to this project.
import Config
# Enable the Nerves integration with Mix
Application.start(:nerves_bootstrap)
config ... | 31 | 82 | 0.785282 |
5a5547f030cc4c035d72ae5127b9d63169e2fcd9 | 4,096 | ex | Elixir | lib/slack/state.ex | jokawachi-hg/Elixir-Slack | 342f63f3b75b64ea43328277d568a4ba3c5e3977 | [
"MIT"
] | 657 | 2015-01-05T21:56:30.000Z | 2022-03-28T12:56:47.000Z | lib/slack/state.ex | jokawachi-hg/Elixir-Slack | 342f63f3b75b64ea43328277d568a4ba3c5e3977 | [
"MIT"
] | 214 | 2015-02-15T18:06:20.000Z | 2022-02-21T21:15:53.000Z | lib/slack/state.ex | jokawachi-hg/Elixir-Slack | 342f63f3b75b64ea43328277d568a4ba3c5e3977 | [
"MIT"
] | 207 | 2015-02-26T23:24:36.000Z | 2022-02-27T21:53:57.000Z | defmodule Slack.State do
@moduledoc "Slack state"
@behaviour Access
def fetch(client, key)
defdelegate fetch(client, key), to: Map
def get(client, key, default)
defdelegate get(client, key, default), to: Map
def get_and_update(client, key, function)
defdelegate get_and_update(client, key, function), ... | 28.84507 | 125 | 0.629639 |
5a556902443ecbe765a8d54f21bcc650e623ff1a | 460 | ex | Elixir | test/e2e/lib/hologram_e2e_web/pages/operators/equal_to_page.ex | gregjohnsonsaltaire/hologram | aa8e9ea0d599def864c263cc37cc8ee31f02ac4a | [
"MIT"
] | 40 | 2022-01-19T20:27:36.000Z | 2022-03-31T18:17:41.000Z | test/e2e/lib/hologram_e2e_web/pages/operators/equal_to_page.ex | gregjohnsonsaltaire/hologram | aa8e9ea0d599def864c263cc37cc8ee31f02ac4a | [
"MIT"
] | 42 | 2022-02-03T22:52:43.000Z | 2022-03-26T20:57:32.000Z | test/e2e/lib/hologram_e2e_web/pages/operators/equal_to_page.ex | gregjohnsonsaltaire/hologram | aa8e9ea0d599def864c263cc37cc8ee31f02ac4a | [
"MIT"
] | 3 | 2022-02-10T04:00:37.000Z | 2022-03-08T22:07:45.000Z | defmodule HologramE2E.Operators.EqualToPage do
use Hologram.Page
route "/e2e/operators/equal-to"
def init(_params, _conn) do
%{
left: 2,
right: 2,
result: 0
}
end
def template do
~H"""
<button id="button" on:click="calculate">Calculate</button>
<div id="text">Result = ... | 18.4 | 63 | 0.615217 |
5a55a5926e30900a05e398b0e8ef8438ec739591 | 2,015 | exs | Elixir | test/stormchat/social/social_test.exs | gautambaghel/stormchat | 1882467113158e7524d02d273e1f88439cc1f152 | [
"MIT"
] | null | null | null | test/stormchat/social/social_test.exs | gautambaghel/stormchat | 1882467113158e7524d02d273e1f88439cc1f152 | [
"MIT"
] | 7 | 2019-06-25T17:21:41.000Z | 2022-02-10T12:09:08.000Z | test/stormchat/social/social_test.exs | gautambaghel/stormchat | 1882467113158e7524d02d273e1f88439cc1f152 | [
"MIT"
] | null | null | null | defmodule Stormchat.SocialTest do
use Stormchat.DataCase
alias Stormchat.Social
describe "posts" do
alias Stormchat.Social.Post
@valid_attrs %{alert: "some alert", body: "some body"}
@update_attrs %{alert: "some updated alert", body: "some updated body"}
@invalid_attrs %{alert: nil, body: nil}
... | 29.632353 | 83 | 0.646154 |
5a55a70869f7b1e8a559fa2f3a3d2f203e16bf12 | 1,005 | ex | Elixir | lib/graphitex.ex | oscar-lopez/graphitex | 4b57c0503a934f48985110a048b763bfb2b61fab | [
"BSD-2-Clause-FreeBSD"
] | null | null | null | lib/graphitex.ex | oscar-lopez/graphitex | 4b57c0503a934f48985110a048b763bfb2b61fab | [
"BSD-2-Clause-FreeBSD"
] | null | null | null | lib/graphitex.ex | oscar-lopez/graphitex | 4b57c0503a934f48985110a048b763bfb2b61fab | [
"BSD-2-Clause-FreeBSD"
] | null | null | null | defmodule Graphitex do
use GenServer
@name __MODULE__
@moduledoc """
"""
defmodule Sample do
defstruct metric: nil,
value: nil,
timestamp: nil
end
@carbon_port Application.get_env(:carbon, :port)
@carbon_host Application.get_env(:carbon, :host)
#####
# Public AP... | 19.326923 | 89 | 0.61194 |
5a55bdf0ee8dbfc51e88de181caaa9f2dd6ceaef | 1,274 | exs | Elixir | mix.exs | ninoseki/ExUrlscan | b714b132bd8f4be44553dcf272dc67e6db79aafa | [
"MIT"
] | 4 | 2019-07-22T13:13:14.000Z | 2021-11-16T20:07:57.000Z | mix.exs | fja43/ExUrlscan | b714b132bd8f4be44553dcf272dc67e6db79aafa | [
"MIT"
] | 1 | 2020-08-07T02:32:49.000Z | 2020-08-07T02:32:49.000Z | mix.exs | fja43/ExUrlscan | b714b132bd8f4be44553dcf272dc67e6db79aafa | [
"MIT"
] | 3 | 2020-01-31T02:53:32.000Z | 2021-11-16T04:07:59.000Z | defmodule Urlscan.MixProject do
use Mix.Project
def project do
[
app: :ex_urlscan,
version: "0.1.2",
elixir: "~> 1.9",
start_permanent: Mix.env() == :prod,
deps: deps(),
description: "Elixir API client for urlscan.io",
test_coverage: [tool: ExCoveralls],
preferre... | 24.037736 | 67 | 0.539246 |
5a55cc76a16454baf9d34b87065638c958d79fcb | 2,117 | ex | Elixir | clients/you_tube/lib/google_api/you_tube/v3/model/sponsor_snippet.ex | MasashiYokota/elixir-google-api | 975dccbff395c16afcb62e7a8e411fbb58e9ab01 | [
"Apache-2.0"
] | null | null | null | clients/you_tube/lib/google_api/you_tube/v3/model/sponsor_snippet.ex | MasashiYokota/elixir-google-api | 975dccbff395c16afcb62e7a8e411fbb58e9ab01 | [
"Apache-2.0"
] | null | null | null | clients/you_tube/lib/google_api/you_tube/v3/model/sponsor_snippet.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... | 37.803571 | 181 | 0.720359 |
5a55e1d1aa8bf097bba89c4ea0d17e0cc570b30a | 1,278 | ex | Elixir | test/conn/agent.ex | zergera/conn_pool | f5b870d9391ff6b395b2cf141448d4765dea6aa3 | [
"MIT"
] | 1 | 2018-06-05T21:32:29.000Z | 2018-06-05T21:32:29.000Z | test/conn/agent.ex | zergera/conn_pool | f5b870d9391ff6b395b2cf141448d4765dea6aa3 | [
"MIT"
] | null | null | null | test/conn/agent.ex | zergera/conn_pool | f5b870d9391ff6b395b2cf141448d4765dea6aa3 | [
"MIT"
] | null | null | null | defmodule(Conn.Agent, do: defstruct([:res]))
defimpl Conn, for: Conn.Agent do
def init(conn, []) do
if Process.alive?(conn.res) do
{:ok, %Conn.Agent{res: conn.res}}
else
{:error, :dead, :infinity, conn}
end
end
def init(conn, res: pid) do
if Process.alive?(pid) do
{:ok, %Conn.A... | 22.821429 | 95 | 0.579812 |
5a562209a9e4b9eb3e08e558be5dd666c376e361 | 2,915 | ex | Elixir | lib/herald/router.ex | herald-library/herald | f35da8c9450c330cbd1ecd01e7e0107ba18cbd56 | [
"MIT"
] | 7 | 2020-04-30T20:20:41.000Z | 2021-04-11T14:26:02.000Z | lib/herald/router.ex | herald-library/herald | f35da8c9450c330cbd1ecd01e7e0107ba18cbd56 | [
"MIT"
] | 10 | 2020-05-15T00:30:03.000Z | 2021-08-03T06:13:22.000Z | lib/herald/router.ex | herald-library/herald | f35da8c9450c330cbd1ecd01e7e0107ba18cbd56 | [
"MIT"
] | null | null | null | defmodule Herald.Router do
@moduledoc """
Provides the routes DSL.
Routes is a way trought Herald know:
* Which Message Schema uses to encode a
message before send it;
* Which function must be used to process
a message when receives
An router must be implemented as a module of your
application, as... | 22.423077 | 76 | 0.645283 |
5a5650c97fde8abf27bde7b0a6b860d1f72418ba | 5,505 | ex | Elixir | web/controllers/routine_controller.ex | OpenFermentor/Local-Monitor | 4b356e8ac3f154ec72bdd23b3a501d5f1645241c | [
"MIT"
] | null | null | null | web/controllers/routine_controller.ex | OpenFermentor/Local-Monitor | 4b356e8ac3f154ec72bdd23b3a501d5f1645241c | [
"MIT"
] | null | null | null | web/controllers/routine_controller.ex | OpenFermentor/Local-Monitor | 4b356e8ac3f154ec72bdd23b3a501d5f1645241c | [
"MIT"
] | null | null | null | defmodule BioMonitor.RoutineController do
use BioMonitor.Web, :controller
alias BioMonitor.Routine
alias BioMonitor.CloudSync
@routines_per_page "20"
def index(conn, params) do
{routines, rummage} =
Routine |>
Rummage.Ecto.rummage(%{
"paginate" => %{
"per_page" => @routine... | 33.363636 | 120 | 0.610899 |
5a5664a39bdcc26335623ca1c9232f8e588322d0 | 1,289 | ex | Elixir | test/support/conn_case.ex | carlosviana/doctor_schedule | 62a0272a2bf9534e7e6a1c6694da15ec5ea91063 | [
"MIT"
] | null | null | null | test/support/conn_case.ex | carlosviana/doctor_schedule | 62a0272a2bf9534e7e6a1c6694da15ec5ea91063 | [
"MIT"
] | 3 | 2021-07-16T10:49:17.000Z | 2021-07-21T08:39:29.000Z | test/support/conn_case.ex | carlosviana/doctor_schedule | 62a0272a2bf9534e7e6a1c6694da15ec5ea91063 | [
"MIT"
] | null | null | null | defmodule DoctorScheduleWeb.ConnCase do
@moduledoc """
This module defines the test case to be used by
tests that require setting up a connection.
Such tests rely on `Phoenix.ConnTest` and also
import other functionality to make it easier
to build common data structures and query the data layer.
Finally... | 28.021739 | 68 | 0.733126 |
5a568edf42ba66a60f63ada88c7e3f28f52c3d7f | 647 | exs | Elixir | mix.exs | aquarhead/depsup | c035b8a2b6bdcde48024a98e0699a4c3fa6d9227 | [
"MIT"
] | null | null | null | mix.exs | aquarhead/depsup | c035b8a2b6bdcde48024a98e0699a4c3fa6d9227 | [
"MIT"
] | null | null | null | mix.exs | aquarhead/depsup | c035b8a2b6bdcde48024a98e0699a4c3fa6d9227 | [
"MIT"
] | null | null | null | defmodule DepSup.MixProject do
use Mix.Project
def project do
[
app: :depsup,
version: "0.1.0",
elixir: "~> 1.8",
start_permanent: Mix.env() == :prod,
deps: deps(),
# Docs
name: "DepSup",
source_url: "https://github.com/aquarhead/depsup",
docs: docs()
... | 16.589744 | 63 | 0.508501 |
5a56bf84425ae41ab822f7740f13b0a64655ec2f | 1,698 | ex | Elixir | test/support/model_case.ex | taylonr/couchjitsu_track | 0a31c450ac734f9d8b69849cb766de0e99f178c4 | [
"MIT"
] | null | null | null | test/support/model_case.ex | taylonr/couchjitsu_track | 0a31c450ac734f9d8b69849cb766de0e99f178c4 | [
"MIT"
] | null | null | null | test/support/model_case.ex | taylonr/couchjitsu_track | 0a31c450ac734f9d8b69849cb766de0e99f178c4 | [
"MIT"
] | null | null | null | defmodule CouchjitsuTrack.ModelCase do
@moduledoc """
This module defines the test case to be used by
model tests.
You may define functions here to be used as helpers in
your model tests. See `errors_on/2`'s definition as reference.
Finally, if the test case interacts with the database,
it cannot be asy... | 26.53125 | 84 | 0.690224 |
5a56cf6e32e53e7b4572eefd1696e0e502ede3ba | 4,042 | ex | Elixir | lib/faker.ex | indocomsoft/faker | b964ad1aceeff867e0011b994bc97c89e36183bd | [
"MIT"
] | null | null | null | lib/faker.ex | indocomsoft/faker | b964ad1aceeff867e0011b994bc97c89e36183bd | [
"MIT"
] | null | null | null | lib/faker.ex | indocomsoft/faker | b964ad1aceeff867e0011b994bc97c89e36183bd | [
"MIT"
] | null | null | null | defmodule Faker do
@moduledoc """
Main module to start application with some helper functions.
"""
@doc """
Starts Faker with default locale.
"""
@spec start() :: :ok
def start do
:application.start(:faker)
end
@doc """
Starts Faker with `lang` locale.
"""
@spec start(atom) :: :ok
def ... | 23.776471 | 99 | 0.623949 |
5a56d00f16197d1d11654053374ef83b1c9ba90f | 3,691 | ex | Elixir | clients/sheets/lib/google_api/sheets/v4/model/filter_criteria.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/sheets/lib/google_api/sheets/v4/model/filter_criteria.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/sheets/lib/google_api/sheets/v4/model/filter_criteria.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... | 51.263889 | 182 | 0.73747 |
5a57012e0d79cc4c6b5c92d790f470ffd6be9115 | 3,389 | exs | Elixir | test/db_test.exs | emaiax/money_sql | 8b6ca5e98fca9f85bfd51279ca92c018e1a9f2fc | [
"Apache-2.0"
] | null | null | null | test/db_test.exs | emaiax/money_sql | 8b6ca5e98fca9f85bfd51279ca92c018e1a9f2fc | [
"Apache-2.0"
] | null | null | null | test/db_test.exs | emaiax/money_sql | 8b6ca5e98fca9f85bfd51279ca92c018e1a9f2fc | [
"Apache-2.0"
] | null | null | null | defmodule Money.DB.Test do
use Money.SQL.RepoCase
test "insert a record with a money amount" do
m = Money.new(:USD, 100)
assert {:ok, struct} = Repo.insert(%Organization{payroll: m})
assert Money.compare(m, struct.payroll) == :eq
end
test "insert a record with a money amount with params" do
m ... | 35.673684 | 94 | 0.640012 |
5a572b6474f7bfd053451ba5536c0f270e0e909d | 450 | exs | Elixir | apps/ewallet_db/test/ewallet_db/helpers/crypto_test.exs | turbo-play/ewallet | b7fee3eed62ac716f46246132c2ead1045f2e4f3 | [
"Apache-2.0"
] | 2 | 2019-07-13T05:49:03.000Z | 2021-08-19T23:58:23.000Z | apps/ewallet_db/test/ewallet_db/helpers/crypto_test.exs | turbo-play/ewallet | b7fee3eed62ac716f46246132c2ead1045f2e4f3 | [
"Apache-2.0"
] | null | null | null | apps/ewallet_db/test/ewallet_db/helpers/crypto_test.exs | turbo-play/ewallet | b7fee3eed62ac716f46246132c2ead1045f2e4f3 | [
"Apache-2.0"
] | 3 | 2018-05-08T17:15:42.000Z | 2021-11-10T04:08:33.000Z | defmodule EWalletDB.Helpers.CryptoTest do
use ExUnit.Case
alias EWalletDB.Helpers.Crypto
describe "generate_key/1" do
test "returns a key with the specified length" do
key = Crypto.generate_key(32)
assert String.length(key) == 43 # ceil(32 * 4 / 3)
# Test with another length to make sure i... | 28.125 | 65 | 0.671111 |
5a577d1e1c542a6488402efb2cdcb86149eec83e | 687 | ex | Elixir | web/gettext.ex | anndream/phoenix-commerce | 5e4471fa8fd1ac402d4df68fe7ccbcb0f7a53296 | [
"MIT"
] | 229 | 2016-09-21T09:24:46.000Z | 2020-05-16T22:41:31.000Z | web/gettext.ex | sadiqmmm/ex-shop | 5e4471fa8fd1ac402d4df68fe7ccbcb0f7a53296 | [
"MIT"
] | 3 | 2016-09-21T10:26:50.000Z | 2016-10-19T07:25:12.000Z | web/gettext.ex | sadiqmmm/ex-shop | 5e4471fa8fd1ac402d4df68fe7ccbcb0f7a53296 | [
"MIT"
] | 32 | 2016-09-22T05:19:05.000Z | 2019-11-01T04:07:13.000Z | defmodule Ap.Gettext do
@moduledoc """
A module providing Internationalization with a gettext-based API.
By using [Gettext](https://hexdocs.pm/gettext),
your module gains a set of macros for translations, for example:
import Ap.Gettext
# Simple translation
gettext "Here is the string to tra... | 27.48 | 72 | 0.671033 |
5a57b7f77c7655abc6683681e76763e5941da44c | 277 | ex | Elixir | lib/ptr_web/views/error_view.ex | francocatena/ptr | 4c8a960cdcb1c8523334fcc0cddba6b7fb3b3e60 | [
"MIT"
] | null | null | null | lib/ptr_web/views/error_view.ex | francocatena/ptr | 4c8a960cdcb1c8523334fcc0cddba6b7fb3b3e60 | [
"MIT"
] | 2 | 2021-03-09T01:59:47.000Z | 2022-02-10T17:08:54.000Z | lib/ptr_web/views/error_view.ex | francocatena/ptr | 4c8a960cdcb1c8523334fcc0cddba6b7fb3b3e60 | [
"MIT"
] | null | null | null | defmodule PtrWeb.ErrorView do
use PtrWeb, :view
import PtrWeb.LayoutView, only: [locale: 0]
# In case no render clause matches or no
# template is found, let's render it as 500
def template_not_found(_template, assigns) do
render("500.html", assigns)
end
end
| 23.083333 | 47 | 0.722022 |
5a57eaf4b8a69bfbdf461ffa95a83428aff6dd69 | 1,595 | ex | Elixir | clients/you_tube_reporting/lib/google_api/you_tube_reporting/v1/model/gdata_diff_download_response.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2021-12-20T03:40:53.000Z | 2021-12-20T03:40:53.000Z | clients/you_tube_reporting/lib/google_api/you_tube_reporting/v1/model/gdata_diff_download_response.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2020-08-18T00:11:23.000Z | 2020-08-18T00:44:16.000Z | clients/you_tube_reporting/lib/google_api/you_tube_reporting/v1/model/gdata_diff_download_response.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | null | null | null | # Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, s... | 33.93617 | 118 | 0.763009 |
5a58056ef8d8116e160e4c72c64d66a6c98c2697 | 934 | ex | Elixir | debian/postrm.ex | webOS-ports/isis-browser | 0f2a339d30023018d1d0d435b2aa0350a32c83e4 | [
"Apache-2.0"
] | 13 | 2015-01-14T01:39:17.000Z | 2021-11-15T09:39:07.000Z | debian/postrm.ex | isis-project/isis-browser | 0f2a339d30023018d1d0d435b2aa0350a32c83e4 | [
"Apache-2.0"
] | null | null | null | debian/postrm.ex | isis-project/isis-browser | 0f2a339d30023018d1d0d435b2aa0350a32c83e4 | [
"Apache-2.0"
] | 5 | 2016-11-24T10:41:00.000Z | 2021-04-10T10:27:44.000Z | #!/bin/sh
# postrm script for isisbrowser
#
# see: dh_installdeb(1)
set -e
# summary of how this script can be called:
# * <postrm> `remove'
# * <postrm> `purge'
# * <old-postrm> `upgrade' <new-version>
# * <new-postrm> `failed-upgrade' <old-version>
# * <new-postrm> `abort-install'... | 24.578947 | 78 | 0.62955 |
5a580fa950980c2eecbdaa6739f73713ff62347a | 68 | ex | Elixir | backend/lib/caffe/support/commanded/event_store.ex | eeng/caffe | d85d0dd56a8204c715052ddaf3d990e47c5df0e9 | [
"MIT"
] | 7 | 2020-03-27T08:26:52.000Z | 2021-08-29T09:50:31.000Z | backend/lib/caffe/support/commanded/event_store.ex | eeng/caffe | d85d0dd56a8204c715052ddaf3d990e47c5df0e9 | [
"MIT"
] | null | null | null | backend/lib/caffe/support/commanded/event_store.ex | eeng/caffe | d85d0dd56a8204c715052ddaf3d990e47c5df0e9 | [
"MIT"
] | null | null | null | defmodule Caffe.EventStore do
use EventStore, otp_app: :caffe
end
| 17 | 33 | 0.794118 |
5a5815fd479c60564999ddcf1e0a4e406e76a1d4 | 255 | ex | Elixir | lib/ex_keccak.ex | tzumby/ex_keccak | 3f400d0078e380d7bcad76942e35670f9384f876 | [
"Apache-2.0"
] | 10 | 2020-08-15T16:35:05.000Z | 2021-12-29T00:15:19.000Z | lib/ex_keccak.ex | tzumby/ex_keccak | 3f400d0078e380d7bcad76942e35670f9384f876 | [
"Apache-2.0"
] | 18 | 2020-09-07T11:12:51.000Z | 2022-03-11T12:38:25.000Z | lib/ex_keccak.ex | tzumby/ex_keccak | 3f400d0078e380d7bcad76942e35670f9384f876 | [
"Apache-2.0"
] | 12 | 2020-09-07T06:19:56.000Z | 2022-02-22T20:56:33.000Z | defmodule ExKeccak do
@external_resource "README.md"
@moduledoc "README.md"
|> File.read!()
use Rustler, otp_app: :ex_keccak, crate: :exkeccak, path: "native/exkeccak"
def hash_256(_data), do: :erlang.nif_error(:nif_not_loaded)
end
| 25.5 | 77 | 0.690196 |
5a58617cdaafdaf7b126ba5e0e8dd7c989e83f3d | 3,020 | ex | Elixir | clients/admin/lib/google_api/admin/reports_v1/api/channels.ex | kolorahl/elixir-google-api | 46bec1e092eb84c6a79d06c72016cb1a13777fa6 | [
"Apache-2.0"
] | null | null | null | clients/admin/lib/google_api/admin/reports_v1/api/channels.ex | kolorahl/elixir-google-api | 46bec1e092eb84c6a79d06c72016cb1a13777fa6 | [
"Apache-2.0"
] | null | null | null | clients/admin/lib/google_api/admin/reports_v1/api/channels.ex | kolorahl/elixir-google-api | 46bec1e092eb84c6a79d06c72016cb1a13777fa6 | [
"Apache-2.0"
] | null | null | null | # Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, s... | 39.736842 | 187 | 0.661258 |
5a58787ec3dff2c10ea52300d74b3854a5aca2bb | 2,011 | ex | Elixir | clients/compute/lib/google_api/compute/v1/model/operations_scoped_list_warning_data.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/compute/lib/google_api/compute/v1/model/operations_scoped_list_warning_data.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | 1 | 2020-12-18T09:25:12.000Z | 2020-12-18T09:25:12.000Z | clients/compute/lib/google_api/compute/v1/model/operations_scoped_list_warning_data.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | 1 | 2020-10-04T10:12:44.000Z | 2020-10-04T10:12:44.000Z | # Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, s... | 40.22 | 527 | 0.742914 |
5a589370094ec6264eafd74f8439fb5757e15127 | 5,717 | ex | Elixir | apps/omg/lib/omg/state/transaction.ex | boolafish/elixir-omg | 46b568404972f6e4b4da3195d42d4fb622edb934 | [
"Apache-2.0"
] | null | null | null | apps/omg/lib/omg/state/transaction.ex | boolafish/elixir-omg | 46b568404972f6e4b4da3195d42d4fb622edb934 | [
"Apache-2.0"
] | null | null | null | apps/omg/lib/omg/state/transaction.ex | boolafish/elixir-omg | 46b568404972f6e4b4da3195d42d4fb622edb934 | [
"Apache-2.0"
] | null | null | null | # Copyright 2019-2020 OmiseGO Pte Ltd
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in ... | 33.629412 | 117 | 0.713486 |
5a58bfbdcfe8bb162ac57ec8fe0625a9e38075f0 | 3,435 | exs | Elixir | test/course_planner/attendances/attendance_test.exs | digitalnatives/course_planner | 27b1c8067edc262685e9c4dcbfcf82633bc8b8dc | [
"MIT"
] | 38 | 2017-04-11T13:37:38.000Z | 2021-05-22T19:35:36.000Z | test/course_planner/attendances/attendance_test.exs | digitalnatives/course_planner | 27b1c8067edc262685e9c4dcbfcf82633bc8b8dc | [
"MIT"
] | 226 | 2017-04-07T13:14:14.000Z | 2018-03-08T16:50:11.000Z | test/course_planner/attendances/attendance_test.exs | digitalnatives/course_planner | 27b1c8067edc262685e9c4dcbfcf82633bc8b8dc | [
"MIT"
] | 7 | 2017-08-30T23:58:13.000Z | 2021-03-28T11:50:45.000Z | defmodule CoursePlanner.AttendanceTest do
use CoursePlannerWeb.ModelCase
alias CoursePlanner.{Attendances.Attendance}
import CoursePlanner.Factory
@valid_class_attrs %{offered_course: nil, date: %{day: 17, month: 4, year: 2010}, finishes_at: %{hour: 14, min: 0, sec: 0}, starting_at: %{hour: 15, min: 0, sec: 0... | 47.054795 | 167 | 0.699563 |
5a58cb6edb75875e61c8c7da8700d48320526654 | 3,630 | ex | Elixir | clients/chat/lib/google_api/chat/v1/model/deprecated_event.ex | leandrocp/elixir-google-api | a86e46907f396d40aeff8668c3bd81662f44c71e | [
"Apache-2.0"
] | null | null | null | clients/chat/lib/google_api/chat/v1/model/deprecated_event.ex | leandrocp/elixir-google-api | a86e46907f396d40aeff8668c3bd81662f44c71e | [
"Apache-2.0"
] | null | null | null | clients/chat/lib/google_api/chat/v1/model/deprecated_event.ex | leandrocp/elixir-google-api | a86e46907f396d40aeff8668c3bd81662f44c71e | [
"Apache-2.0"
] | 1 | 2020-11-10T16:58:27.000Z | 2020-11-10T16:58:27.000Z | # Copyright 2018 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... | 49.726027 | 327 | 0.727824 |
5a58e06ed602e168075a95e2d3fe3696f1e11270 | 1,156 | exs | Elixir | test/event/handler_init_test.exs | jwilger/commanded | 2d9950fd3ce76a23a3c410c99857b812f5705d66 | [
"MIT"
] | 1 | 2020-02-19T01:07:32.000Z | 2020-02-19T01:07:32.000Z | test/event/handler_init_test.exs | jwilger/commanded | 2d9950fd3ce76a23a3c410c99857b812f5705d66 | [
"MIT"
] | null | null | null | test/event/handler_init_test.exs | jwilger/commanded | 2d9950fd3ce76a23a3c410c99857b812f5705d66 | [
"MIT"
] | 1 | 2020-02-18T20:53:39.000Z | 2020-02-18T20:53:39.000Z | defmodule Commanded.Event.HandlerInitTest do
use Commanded.MockEventStoreCase
import Mox
alias Commanded.Event.InitHandler
alias Commanded.EventStore.Adapters.Mock, as: MockEventStore
setup do
reply_to = self()
subscribe_to = fn _event_store, :all, handler_name, handler, _subscribe_from ->
a... | 23.591837 | 83 | 0.700692 |
5a58edebde40f9aeeb976f478a4ba1dc83ff3f00 | 1,803 | exs | Elixir | rel/config.exs | TDogVoid/rain_alert | cf0a14e14bd2a62ea8baae6f5fe440358f6265aa | [
"MIT"
] | null | null | null | rel/config.exs | TDogVoid/rain_alert | cf0a14e14bd2a62ea8baae6f5fe440358f6265aa | [
"MIT"
] | null | null | null | rel/config.exs | TDogVoid/rain_alert | cf0a14e14bd2a62ea8baae6f5fe440358f6265aa | [
"MIT"
] | null | null | null | # 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 Mix.Releases.Config,
# Thi... | 32.196429 | 81 | 0.731559 |
5a59178969047cb31e119ba18a6a332c9674dc89 | 1,786 | ex | Elixir | lib/aoc/helpers.ex | mathsaey/advent_of_code_utils | 08081608e341136294d4454df3af2c20373592fd | [
"MIT"
] | 5 | 2020-12-04T00:49:46.000Z | 2021-12-17T11:48:36.000Z | lib/aoc/helpers.ex | mathsaey/advent_of_code_utils | 08081608e341136294d4454df3af2c20373592fd | [
"MIT"
] | 1 | 2020-12-05T00:55:05.000Z | 2020-12-05T00:55:05.000Z | lib/aoc/helpers.ex | mathsaey/advent_of_code_utils | 08081608e341136294d4454df3af2c20373592fd | [
"MIT"
] | 1 | 2020-12-04T03:03:27.000Z | 2020-12-04T03:03:27.000Z | defmodule AOC.Helpers do
@moduledoc false
def day, do: Application.get_env(:advent_of_code_utils, :day, NaiveDateTime.local_now().day)
def year, do: Application.get_env(:advent_of_code_utils, :year, NaiveDateTime.local_now().year)
def module_name(year, day) do
mod_year = "Y#{year}" |> String.to_atom()
... | 33.698113 | 108 | 0.663494 |
5a5978915d871fd1806487205e8d437a69655da3 | 13,888 | exs | Elixir | test/elixir/test/partition_mango_test.exs | aogier/couchdb | 0c7111c49932e742981145b88389f7bdcfda5ee6 | [
"Apache-2.0"
] | null | null | null | test/elixir/test/partition_mango_test.exs | aogier/couchdb | 0c7111c49932e742981145b88389f7bdcfda5ee6 | [
"Apache-2.0"
] | null | null | null | test/elixir/test/partition_mango_test.exs | aogier/couchdb | 0c7111c49932e742981145b88389f7bdcfda5ee6 | [
"Apache-2.0"
] | null | null | null | defmodule PartitionMangoTest do
use CouchTestCase
import PartitionHelpers, except: [get_partitions: 1]
@moduledoc """
Test Partition functionality for mango
"""
def create_index(db_name, fields \\ ["some"], opts \\ %{}) do
default_index = %{
index: %{
fields: fields
}
}
ind... | 21.802198 | 86 | 0.53233 |
5a59ac9ec7f0ac7eacaadf5cad49c7aacf038496 | 1,170 | ex | Elixir | apps/banking_api_challenge/lib/banking_api_challenge/operations/withdrawals.ex | jhonndabi/banking-api-challenge | 1e13c675b02c8e62a76e82b0a0dd6a44306a211e | [
"Apache-2.0"
] | null | null | null | apps/banking_api_challenge/lib/banking_api_challenge/operations/withdrawals.ex | jhonndabi/banking-api-challenge | 1e13c675b02c8e62a76e82b0a0dd6a44306a211e | [
"Apache-2.0"
] | null | null | null | apps/banking_api_challenge/lib/banking_api_challenge/operations/withdrawals.ex | jhonndabi/banking-api-challenge | 1e13c675b02c8e62a76e82b0a0dd6a44306a211e | [
"Apache-2.0"
] | 1 | 2021-04-20T19:05:48.000Z | 2021-04-20T19:05:48.000Z | defmodule BankingApiChallenge.Operations.Withdrawals do
alias BankingApiChallenge.Operations.Inputs.WithdrawalInput
alias BankingApiChallenge.Accounts.Schemas.Account
alias BankingApiChallenge.Operations.Schemas.Operation
alias BankingApiChallenge.Accounts
alias BankingApiChallenge.Repo
require Logger
d... | 28.536585 | 82 | 0.675214 |
5a59b445a77e139ae88137905ea7f7c12ef58b87 | 439 | exs | Elixir | test/quark_test.exs | doma-engineering/quark | 16af5e00f9048053678cbaf6fb770969446e0d1e | [
"MIT"
] | 80 | 2019-06-07T00:02:56.000Z | 2022-03-14T19:33:27.000Z | test/quark_test.exs | doma-engineering/quark | 16af5e00f9048053678cbaf6fb770969446e0d1e | [
"MIT"
] | 11 | 2019-07-08T09:56:54.000Z | 2021-11-29T09:57:16.000Z | test/quark_test.exs | doma-engineering/quark | 16af5e00f9048053678cbaf6fb770969446e0d1e | [
"MIT"
] | 7 | 2019-09-18T14:56:57.000Z | 2021-05-25T17:16:43.000Z | defmodule QuarkTest do
use ExUnit.Case, async: false # true
doctest Quark, import: true
doctest Quark.BCKW, import: true
doctest Quark.Compose, import: true
doctest Quark.Curry, import: true
doctest Quark.FixedPoint, import: true
doctest Quark.M, import: true
doctest Quark.Partial, import: true
doct... | 27.4375 | 46 | 0.753986 |
5a59d089094c52fa6ff7456d27c745d77887370c | 323 | ex | Elixir | lib/new_relic/span/reporter.ex | tpitale/elixir_agent | f356b588fe9d7cc3b9db00d9a251e009a20b3e0e | [
"Apache-2.0"
] | 227 | 2018-09-05T15:33:23.000Z | 2022-02-25T18:12:06.000Z | lib/new_relic/span/reporter.ex | tpitale/elixir_agent | f356b588fe9d7cc3b9db00d9a251e009a20b3e0e | [
"Apache-2.0"
] | 211 | 2018-09-05T21:42:41.000Z | 2022-03-25T17:51:56.000Z | lib/new_relic/span/reporter.ex | tpitale/elixir_agent | f356b588fe9d7cc3b9db00d9a251e009a20b3e0e | [
"Apache-2.0"
] | 84 | 2018-09-05T04:26:26.000Z | 2022-03-09T14:28:14.000Z | defmodule NewRelic.Span.Reporter do
@moduledoc false
def report_span(span) do
case NewRelic.Config.feature(:infinite_tracing) do
:sampling -> NewRelic.Harvest.Collector.SpanEvent.Harvester.report_span(span)
:infinite -> NewRelic.Harvest.TelemetrySdk.Spans.Harvester.report_span(span)
end
end
e... | 29.363636 | 83 | 0.76161 |
5a5a0067ed95aab8c27376bce0c2520f7cf4f20a | 1,136 | exs | Elixir | test/integration/include_resolver_test.exs | dclausen/contentful.ex | 9de10d57e17b0c81eaf1d5bd1a5f232613dedcb5 | [
"MIT"
] | null | null | null | test/integration/include_resolver_test.exs | dclausen/contentful.ex | 9de10d57e17b0c81eaf1d5bd1a5f232613dedcb5 | [
"MIT"
] | null | null | null | test/integration/include_resolver_test.exs | dclausen/contentful.ex | 9de10d57e17b0c81eaf1d5bd1a5f232613dedcb5 | [
"MIT"
] | null | null | null | defmodule Contentful.IncludeResolverTest do
use ExUnit.Case
alias Contentful.Delivery
use ExVCR.Mock, adapter: ExVCR.Adapter.Hackney
@access_token "ACCESS_TOKEN"
@space_id "z3aswf9egfi8"
setup_all do
HTTPoison.start()
end
@tag timeout: 10000
test "entries" do
use_cassette "entries" do
... | 22.27451 | 89 | 0.641725 |
5a5a1e8f149f93534407892d4cad9a20c2decc90 | 7,163 | exs | Elixir | test/goon/driver_test.exs | walkr/porcelain | 4a497495beb8cab7af0d47ae50f720d31a13f039 | [
"MIT"
] | null | null | null | test/goon/driver_test.exs | walkr/porcelain | 4a497495beb8cab7af0d47ae50f720d31a13f039 | [
"MIT"
] | null | null | null | test/goon/driver_test.exs | walkr/porcelain | 4a497495beb8cab7af0d47ae50f720d31a13f039 | [
"MIT"
] | null | null | null | defmodule PorcelainTest.GoonTest do
use ExUnit.Case
import TestUtil
import Porcelain, only: [exec: 2, exec: 3]
alias Porcelain.Result
@moduletag :goon
setup_all do
Porcelain.reinit(Porcelain.Driver.Goon)
end
test "status" do
assert exec("date", [], out: nil) ==
%Result{out: nil... | 30.480851 | 95 | 0.567639 |
5a5a32485238ac96d6b410f9168e4de67f9fdc2a | 3,168 | ex | Elixir | clients/game_services/lib/google_api/game_services/v1beta/model/audit_config.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2021-12-20T03:40:53.000Z | 2021-12-20T03:40:53.000Z | clients/game_services/lib/google_api/game_services/v1beta/model/audit_config.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2020-08-18T00:11:23.000Z | 2020-08-18T00:44:16.000Z | clients/game_services/lib/google_api/game_services/v1beta/model/audit_config.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... | 59.773585 | 1,106 | 0.740846 |
5a5a3f4a9933f92acd6543f32b11b4e3325fbdeb | 1,502 | ex | Elixir | lib/ex_okex/api/private.ex | acuityinnovations/ex_okex | 52acf16e8d00446ca32607ccb2cd75add0acaceb | [
"MIT"
] | null | null | null | lib/ex_okex/api/private.ex | acuityinnovations/ex_okex | 52acf16e8d00446ca32607ccb2cd75add0acaceb | [
"MIT"
] | 4 | 2019-04-12T17:13:00.000Z | 2020-04-06T07:28:47.000Z | lib/ex_okex/api/private.ex | acuityinnovations/ex_okex | 52acf16e8d00446ca32607ccb2cd75add0acaceb | [
"MIT"
] | 5 | 2019-04-10T00:41:17.000Z | 2021-12-23T14:49:02.000Z | defmodule ExOkex.Api.Private do
@moduledoc """
Interface for authenticated HTTP requests
"""
import ExOkex.Api
alias ExOkex.Config
alias ExOkex.Auth
@type path :: String.t()
@type params :: map | [map]
@type config :: map | nil
@type response :: ExOkex.Api.response()
@spec get(path, params, con... | 25.457627 | 83 | 0.641145 |
5a5a4b8f107b50b87c212e67d3fa95aa96f5c86b | 1,572 | exs | Elixir | test/ex_rss_web/plugs/remember_user_test.exs | cruessler/exrss | 6ac17b7533d78460a1c34cabaae86fec317f460a | [
"MIT"
] | 4 | 2020-02-16T07:18:35.000Z | 2021-12-09T14:43:10.000Z | test/ex_rss_web/plugs/remember_user_test.exs | cruessler/exrss | 6ac17b7533d78460a1c34cabaae86fec317f460a | [
"MIT"
] | 27 | 2019-10-16T18:35:19.000Z | 2022-03-13T16:39:57.000Z | test/ex_rss_web/plugs/remember_user_test.exs | cruessler/exrss | 6ac17b7533d78460a1c34cabaae86fec317f460a | [
"MIT"
] | null | null | null | defmodule ExRssWeb.RememberUser do
use ExUnit.Case, async: true
use Plug.Test
alias Ecto.Changeset
alias ExRss.Repo
alias ExRss.{Session, User}
alias ExRssWeb.Plug.RememberUser
@user %User{id: 1}
@plug RememberUser.init(nil)
@session Plug.Session.init(
store: :cookie,
ke... | 23.117647 | 75 | 0.632316 |
5a5a4d55b55b4bdbd4a419701b17e47057275828 | 95 | exs | Elixir | .formatter.exs | whitfin/jumper | ade6e5ec19ff6e2c8cb45e129d11ff3f7b3afb11 | [
"MIT"
] | 4 | 2018-10-14T23:53:22.000Z | 2022-01-03T15:57:33.000Z | .formatter.exs | whitfin/jumper | ade6e5ec19ff6e2c8cb45e129d11ff3f7b3afb11 | [
"MIT"
] | 1 | 2018-08-04T16:37:44.000Z | 2018-08-04T17:17:31.000Z | .formatter.exs | whitfin/jumper | ade6e5ec19ff6e2c8cb45e129d11ff3f7b3afb11 | [
"MIT"
] | null | null | null | # Used by "mix format"
[
inputs: ["mix.exs", "{benchmarks,config,lib,test}/**/*.{ex,exs}"]
]
| 19 | 67 | 0.578947 |
5a5a536bb58c52f9b41f013f989f1ef017dd6e33 | 12,858 | exs | Elixir | apps/nerves_hub_web_core/test/nerves_hub_web_core/accounts/accounts_test.exs | nerves-hub/beamware | 5c239b7125a82d8fcb2b84ff1ad22d3bb0af01eb | [
"Apache-2.0"
] | 10 | 2018-04-12T18:16:40.000Z | 2018-04-14T06:05:42.000Z | apps/nerves_hub_web_core/test/nerves_hub_web_core/accounts/accounts_test.exs | nerves-hub/beamware | 5c239b7125a82d8fcb2b84ff1ad22d3bb0af01eb | [
"Apache-2.0"
] | 13 | 2018-05-25T19:31:49.000Z | 2018-05-31T14:27:43.000Z | apps/nerves_hub_web_core/test/nerves_hub_web_core/accounts/accounts_test.exs | nerves-hub/beamware | 5c239b7125a82d8fcb2b84ff1ad22d3bb0af01eb | [
"Apache-2.0"
] | 2 | 2018-04-12T18:19:47.000Z | 2018-04-12T18:57:46.000Z | defmodule NervesHubWebCore.AccountsTest do
use NervesHubWebCore.DataCase, async: true
alias Ecto.Changeset
alias NervesHubWebCore.Accounts
alias NervesHubWebCore.Accounts.{Org, OrgKey, OrgLimit, OrgUser, User, Invite}
alias NervesHubWebCore.Fixtures
@required_org_params %{name: "Org"}
setup do
use... | 32.064838 | 95 | 0.663711 |
5a5a59b6d73aaf40e085986c5fe4b3e520eef9ad | 963 | exs | Elixir | mix.exs | bmalum/heroicons_elixir | d104591f006e70aae0b6f99b9ca0f6a03629412f | [
"MIT"
] | 1 | 2021-04-11T15:12:10.000Z | 2021-04-11T15:12:10.000Z | mix.exs | bmalum/heroicons_elixir | d104591f006e70aae0b6f99b9ca0f6a03629412f | [
"MIT"
] | null | null | null | mix.exs | bmalum/heroicons_elixir | d104591f006e70aae0b6f99b9ca0f6a03629412f | [
"MIT"
] | null | null | null | defmodule HeroiconsElixir.MixProject do
use Mix.Project
def project do
[
app: :heroicons,
version: "0.2.1",
elixir: "~> 1.11",
start_permanent: Mix.env() == :prod,
deps: deps(),
name: "Heroicons",
source_url: "https://github.com/mveytsman/heroicons_elixir",
descr... | 20.489362 | 86 | 0.582555 |
5a5a98d0fbb7103e6fae4b2bcd20f45f7acd74db | 2,536 | ex | Elixir | lib/day10.ex | erljef/adventofcode-2019 | 7de8cb502fa2b29181243ca6444aa5a26d085175 | [
"WTFPL"
] | null | null | null | lib/day10.ex | erljef/adventofcode-2019 | 7de8cb502fa2b29181243ca6444aa5a26d085175 | [
"WTFPL"
] | null | null | null | lib/day10.ex | erljef/adventofcode-2019 | 7de8cb502fa2b29181243ca6444aa5a26d085175 | [
"WTFPL"
] | null | null | null | defmodule Day10 do
def from_file(path) do
Helper.read_file(path)
|> Enum.to_list
|> List.flatten
end
def new_map(input) do
input
|> Enum.map(&String.graphemes/1)
|> Enum.with_index
|> Enum.map(fn {row, ix} -> row |> to_coordinates(ix) end)
|> List.flatten
end
def to_coordina... | 26.416667 | 89 | 0.577681 |
5a5ac89905452652345210bed023f76ac9c0d8bf | 1,807 | ex | Elixir | lib/coherence/plugs/authorization/utils.ex | harmon25/coherence | 5c4f26d3c87f6a16638adf623d041e2723ccf2b8 | [
"MIT"
] | 1 | 2022-03-06T16:30:21.000Z | 2022-03-06T16:30:21.000Z | lib/coherence/plugs/authorization/utils.ex | ysbaddaden/coherence | 5c4f26d3c87f6a16638adf623d041e2723ccf2b8 | [
"MIT"
] | null | null | null | lib/coherence/plugs/authorization/utils.ex | ysbaddaden/coherence | 5c4f26d3c87f6a16638adf623d041e2723ccf2b8 | [
"MIT"
] | 2 | 2017-09-22T16:54:36.000Z | 2021-11-09T20:55:58.000Z | defmodule Coherence.Authentication.Utils do
@moduledoc false
import Plug.Conn
alias Coherence.Config
@type conn :: Plug.Conn.t
@type t :: Map.t
@param_key Application.get_env :coherence, :token_param_key, "param_key"
@spec param_key() :: String.t
def param_key, do: @param_key
@spec assign_user_dat... | 27.378788 | 87 | 0.686774 |
5a5afd0ce3f4cb1428fafa8e56c17b4c8bfd0dff | 413 | exs | Elixir | machine_translation/MorpHIN/Learned/Resources/Set3/TrainingInstances/92.exs | AdityaPrasadMishra/NLP--Project-Group-16 | fb62cc6a1db4a494058171f11c14a2be3933a9a1 | [
"MIT"
] | null | null | null | machine_translation/MorpHIN/Learned/Resources/Set3/TrainingInstances/92.exs | AdityaPrasadMishra/NLP--Project-Group-16 | fb62cc6a1db4a494058171f11c14a2be3933a9a1 | [
"MIT"
] | null | null | null | machine_translation/MorpHIN/Learned/Resources/Set3/TrainingInstances/92.exs | AdityaPrasadMishra/NLP--Project-Group-16 | fb62cc6a1db4a494058171f11c14a2be3933a9a1 | [
"MIT"
] | null | null | null | **EXAMPLE FILE**
verb_aux SYM noun cm quantifier;
conj demonstrative noun cm quantifier;
verb conj cardinal noun quantifier;
pnoun cm cardinal noun quantifier;
pnoun cm cardinal adjective quantifier;
noun cm quantifier adjective quantifier;
verb conj noun noun quantifier;
pn cm cm noun pn;
cm particle cm noun... | 29.5 | 45 | 0.79661 |
5a5b0cba65d7f4567e604591a5d5374a2f49b0e0 | 759 | exs | Elixir | priv/repo/seeds.exs | llxff/projects_statistics | 343508fc8fc8e9238a546f5230fff50e21126417 | [
"Unlicense"
] | null | null | null | priv/repo/seeds.exs | llxff/projects_statistics | 343508fc8fc8e9238a546f5230fff50e21126417 | [
"Unlicense"
] | null | null | null | priv/repo/seeds.exs | llxff/projects_statistics | 343508fc8fc8e9238a546f5230fff50e21126417 | [
"Unlicense"
] | null | null | null | # Script for populating the database. You can run it as:
#
# mix run priv/repo/seeds.exs
#
# Inside the script, you can read and write to any of your
# repositories directly:
#
# ProjectsStatistics.Repo.insert!(%ProjectsStatistics.SomeModel{})
#
# We recommend using the bang functions (`insert!`, `update!`
# an... | 42.166667 | 81 | 0.770751 |
5a5b22cb0aeb4a24ce325f43306490f14c4053e6 | 2,435 | ex | Elixir | lib/cadet_web/controllers/answer_controller.ex | source-academy/cadet | c447552453f78799755de73f66999e4c9d20383c | [
"Apache-2.0"
] | 27 | 2018-01-20T05:56:24.000Z | 2021-05-24T03:21:55.000Z | lib/cadet_web/controllers/answer_controller.ex | source-academy/cadet | c447552453f78799755de73f66999e4c9d20383c | [
"Apache-2.0"
] | 731 | 2018-04-16T13:25:49.000Z | 2021-06-22T07:16:12.000Z | lib/cadet_web/controllers/answer_controller.ex | source-academy/cadet | c447552453f78799755de73f66999e4c9d20383c | [
"Apache-2.0"
] | 43 | 2018-01-20T06:35:46.000Z | 2021-05-05T03:22:35.000Z | defmodule CadetWeb.AnswerController do
use CadetWeb, :controller
use PhoenixSwagger
alias Cadet.Assessments
# These roles can save and finalise answers for
# closed assessments and submitted answers
@bypass_closed_roles ~w(staff admin)a
def submit(conn, %{"questionid" => question_id, "answer" => answe... | 28.313953 | 117 | 0.628337 |
5a5b3109a826346354a8c59e5502d025f3840a99 | 1,014 | ex | Elixir | lib/glimesh_web/live/components/tagify_component.ex | Megami-Studios/glimesh.tv | 57dde3a328fabdcc3305be48ae1b82df27b83c9b | [
"MIT"
] | 328 | 2020-07-23T22:13:49.000Z | 2022-03-31T21:22:28.000Z | lib/glimesh_web/live/components/tagify_component.ex | Megami-Studios/glimesh.tv | 57dde3a328fabdcc3305be48ae1b82df27b83c9b | [
"MIT"
] | 362 | 2020-07-23T22:38:38.000Z | 2022-03-24T02:11:16.000Z | lib/glimesh_web/live/components/tagify_component.ex | Megami-Studios/glimesh.tv | 57dde3a328fabdcc3305be48ae1b82df27b83c9b | [
"MIT"
] | 72 | 2020-07-23T22:50:46.000Z | 2022-02-02T11:59:32.000Z | defmodule GlimeshWeb.TagifyComponent do
use GlimeshWeb, :live_component
def render(assigns) do
~L"""
<%= text_input @form, @field,
id: @id,
value: @value,
class: "tagify",
"data-suggestions-event": "suggestions-#{@id}",
"data-category": @category.id,
"data-cr... | 25.35 | 95 | 0.571992 |
5a5b4f589ebc7171905ce924496fd18b3ce9a518 | 610 | ex | Elixir | lib/progress_bar.ex | varsill/progress_bar | 123536f5af4c86f332a77e027fe7c489731eafea | [
"MIT"
] | 318 | 2015-09-19T14:02:22.000Z | 2022-03-10T21:27:53.000Z | lib/progress_bar.ex | varsill/progress_bar | 123536f5af4c86f332a77e027fe7c489731eafea | [
"MIT"
] | 26 | 2015-09-19T10:48:44.000Z | 2021-11-16T17:11:21.000Z | lib/progress_bar.ex | varsill/progress_bar | 123536f5af4c86f332a77e027fe7c489731eafea | [
"MIT"
] | 26 | 2015-09-30T02:01:54.000Z | 2022-03-18T13:58:12.000Z | defmodule ProgressBar do
def render(current, total) do
ProgressBar.Determinate.render(current, total)
end
def render(current, total, custom_format) do
ProgressBar.Determinate.render(current, total, custom_format)
end
def render_indeterminate(fun) do
ProgressBar.Indeterminate.render(fun)
end
... | 23.461538 | 65 | 0.765574 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.