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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
1ad58f620500563532d03d212e8f2c4f8aa6a47c | 1,613 | ex | Elixir | app/lib/noodl_web/live/accounts/forgot_password/forgot_password.ex | nathanjohnson320/noodl | 2e449aab15b54fc5a1dc45ebf4b79e7b64b7c967 | [
"MIT"
] | 1 | 2021-01-20T20:00:50.000Z | 2021-01-20T20:00:50.000Z | app/lib/noodl_web/live/accounts/forgot_password/forgot_password.ex | nathanjohnson320/noodl | 2e449aab15b54fc5a1dc45ebf4b79e7b64b7c967 | [
"MIT"
] | null | null | null | app/lib/noodl_web/live/accounts/forgot_password/forgot_password.ex | nathanjohnson320/noodl | 2e449aab15b54fc5a1dc45ebf4b79e7b64b7c967 | [
"MIT"
] | null | null | null | defmodule NoodlWeb.Live.Accounts.ForgotPassword do
@moduledoc ~S"""
LiveView for the forgot password page.
"""
use NoodlWeb, :bare_view
alias Noodl.Accounts
alias Noodl.Accounts.User
alias Noodl.Emails.Mailer
alias NoodlWeb.Email
@timeout :timer.seconds(5)
def mount(_params, _session, socket) do
... | 28.298246 | 96 | 0.646001 |
1ad59032a87541a364b5b383e289a5af71b531a0 | 984 | ex | Elixir | memory-master/lib/memory/application.ex | Wycode-fish/WEBDEV-MEMORY-GAME | 1b04f995fb1a545781206a7fd01de0a1bb75d86c | [
"MIT"
] | null | null | null | memory-master/lib/memory/application.ex | Wycode-fish/WEBDEV-MEMORY-GAME | 1b04f995fb1a545781206a7fd01de0a1bb75d86c | [
"MIT"
] | null | null | null | memory-master/lib/memory/application.ex | Wycode-fish/WEBDEV-MEMORY-GAME | 1b04f995fb1a545781206a7fd01de0a1bb75d86c | [
"MIT"
] | null | null | null | defmodule Memory.Application do
use Application
# See https://hexdocs.pm/elixir/Application.html
# for more information on OTP Applications
def start(_type, _args) do
import Supervisor.Spec
# Define workers and child supervisors to be supervised
children = [
# Start the endpoint when the app... | 31.741935 | 84 | 0.714431 |
1ad5afd60c60e230b96fd161566c80e8e99ffc47 | 2,561 | ex | Elixir | clients/slides/lib/google_api/slides/v1/model/update_table_cell_properties_request.ex | GoNZooo/elixir-google-api | cf3ad7392921177f68091f3d9001f1b01b92f1cc | [
"Apache-2.0"
] | null | null | null | clients/slides/lib/google_api/slides/v1/model/update_table_cell_properties_request.ex | GoNZooo/elixir-google-api | cf3ad7392921177f68091f3d9001f1b01b92f1cc | [
"Apache-2.0"
] | null | null | null | clients/slides/lib/google_api/slides/v1/model/update_table_cell_properties_request.ex | GoNZooo/elixir-google-api | cf3ad7392921177f68091f3d9001f1b01b92f1cc | [
"Apache-2.0"
] | 1 | 2018-07-28T20:50:50.000Z | 2018-07-28T20:50:50.000Z | # Copyright 2017 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in... | 46.563636 | 562 | 0.755955 |
1ad5c9789a227adabf597a72df3d505e6c7efab6 | 1,053 | exs | Elixir | mix.exs | workpathco/firebase-admin-ex | 83305a4bfcc5b1cc7b692eee9d4c93fa080759f2 | [
"MIT"
] | 1 | 2019-07-17T01:09:37.000Z | 2019-07-17T01:09:37.000Z | mix.exs | workpathco/firebase-admin-ex | 83305a4bfcc5b1cc7b692eee9d4c93fa080759f2 | [
"MIT"
] | null | null | null | mix.exs | workpathco/firebase-admin-ex | 83305a4bfcc5b1cc7b692eee9d4c93fa080759f2 | [
"MIT"
] | null | null | null | defmodule FirebaseAdminEx.MixProject do
use Mix.Project
def project do
[
app: :firebase_admin_ex,
version: "0.1.0",
elixir: "~> 1.6",
start_permanent: Mix.env() == :prod,
deps: deps(),
description: description(),
package: package(),
source_url: "https://github.co... | 22.404255 | 75 | 0.573599 |
1ad5d33dd99dfad29095c5c3c158d45aa64b5da1 | 1,208 | ex | Elixir | lib/bamboo/plug/sent_email_viewer/helper.ex | mrcasals/bamboo | c3b82436d9594d7838775fcc906cd4bd8516690e | [
"MIT"
] | 1,845 | 2016-03-29T23:36:36.000Z | 2022-03-31T19:23:38.000Z | lib/bamboo/plug/sent_email_viewer/helper.ex | mrcasals/bamboo | c3b82436d9594d7838775fcc906cd4bd8516690e | [
"MIT"
] | 407 | 2016-03-29T14:55:19.000Z | 2022-02-02T13:53:50.000Z | lib/bamboo/plug/sent_email_viewer/helper.ex | mrcasals/bamboo | c3b82436d9594d7838775fcc906cd4bd8516690e | [
"MIT"
] | 361 | 2016-03-31T13:33:22.000Z | 2022-02-25T12:38:43.000Z | defmodule Bamboo.SentEmailViewerPlug.Helper do
import Bamboo.SentEmail
alias Plug.HTML
@moduledoc false
def selected_email_class(email, selected_email) do
if get_id(email) == get_id(selected_email) do
"selected-email"
else
""
end
end
def email_addresses(email) do
Bamboo.Email.... | 20.827586 | 56 | 0.684603 |
1ad5e23b7bd3b4e262327028fe8f3b450e50137c | 981 | exs | Elixir | test/support/blog.exs | altenwald/lambdapad | bf7807825b8c9b049d966e0cb9aece03144d02be | [
"Apache-2.0"
] | 11 | 2021-04-09T09:35:03.000Z | 2022-03-03T20:31:52.000Z | test/support/blog.exs | altenwald/lambdapad | bf7807825b8c9b049d966e0cb9aece03144d02be | [
"Apache-2.0"
] | null | null | null | test/support/blog.exs | altenwald/lambdapad | bf7807825b8c9b049d966e0cb9aece03144d02be | [
"Apache-2.0"
] | 2 | 2021-04-09T15:44:44.000Z | 2021-04-22T21:11:47.000Z | import Lambdapad
blog do
config do
set format: :eterm
set from: "blog.config"
set var_name: "blog"
end
assets "files" do
set from: "assets/*.css"
set to: "site/css"
end
source posts: "posts/**/*.md"
widget "recent posts" do
set from: :posts
set var_name: "posts"
set index... | 16.913793 | 37 | 0.559633 |
1ad5e7ad6011092faf9175aa9a4384e658bc3c9b | 1,936 | ex | Elixir | test/support/parent_schema.ex | annatel/antl_utils_ecto | 494af10a3331c46809c7295bfc674fe42ba5c064 | [
"MIT"
] | 3 | 2020-10-30T13:57:58.000Z | 2022-03-03T15:21:53.000Z | test/support/parent_schema.ex | annatel/antl_utils_ecto | 494af10a3331c46809c7295bfc674fe42ba5c064 | [
"MIT"
] | 1 | 2020-12-30T11:36:33.000Z | 2020-12-30T11:36:33.000Z | test/support/parent_schema.ex | annatel/antl_utils_ecto | 494af10a3331c46809c7295bfc674fe42ba5c064 | [
"MIT"
] | null | null | null | defmodule Parent do
use Ecto.Schema
use AntlUtilsEcto.Queryable
embedded_schema do
field(:field1, :string)
has_many(:childs, Child)
end
defp include_assoc(queryable, :childs) do
queryable |> Ecto.Query.preload(:childs)
end
end
defmodule ParentWithQueryableOverrided do
use Ecto.Schema
use... | 20.378947 | 74 | 0.72624 |
1ad60019deb77c3c5db0a63dcd66df446962ca40 | 2,851 | ex | Elixir | clients/datastream/lib/google_api/datastream/v1/model/stream_object.ex | renovate-bot/elixir-google-api | 1da34cd39b670c99f067011e05ab90af93fef1f6 | [
"Apache-2.0"
] | 1 | 2021-12-20T03:40:53.000Z | 2021-12-20T03:40:53.000Z | clients/datastream/lib/google_api/datastream/v1/model/stream_object.ex | swansoffiee/elixir-google-api | 9ea6d39f273fb430634788c258b3189d3613dde0 | [
"Apache-2.0"
] | 1 | 2020-08-18T00:11:23.000Z | 2020-08-18T00:44:16.000Z | clients/datastream/lib/google_api/datastream/v1/model/stream_object.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... | 43.861538 | 161 | 0.701859 |
1ad61a36ae6a75d643ec438ac136565824a675e6 | 571 | ex | Elixir | web/view.ex | spreedly/sample-hyperdrives | ab6d2ff055c574bfb215531d3c523242666c52d9 | [
"MIT"
] | null | null | null | web/view.ex | spreedly/sample-hyperdrives | ab6d2ff055c574bfb215531d3c523242666c52d9 | [
"MIT"
] | null | null | null | web/view.ex | spreedly/sample-hyperdrives | ab6d2ff055c574bfb215531d3c523242666c52d9 | [
"MIT"
] | null | null | null | defmodule Hyperdrives.View do
use Phoenix.View, root: "web/templates"
# The quoted expression returned by this block is applied
# to this module and all other views that use this module.
using do
quote do
# Import common functionality
import Hyperdrives.I18n
import Hyperdrives.Router.Help... | 25.954545 | 72 | 0.712785 |
1ad638fd8bbc4726b09e4e4c5a85b08cb533091e | 1,206 | exs | Elixir | apps/realtime/mix.exs | bus-detective/bus_detective_ng | ef54684d4f640384bd20a4d5550ff51ab440190b | [
"MIT"
] | 8 | 2018-07-06T14:44:10.000Z | 2021-08-19T17:24:25.000Z | apps/realtime/mix.exs | bus-detective/bus_detective_ng | ef54684d4f640384bd20a4d5550ff51ab440190b | [
"MIT"
] | 12 | 2018-07-15T18:43:04.000Z | 2022-02-10T16:07:47.000Z | apps/realtime/mix.exs | bus-detective/bus_detective_ng | ef54684d4f640384bd20a4d5550ff51ab440190b | [
"MIT"
] | 1 | 2018-07-13T17:30:20.000Z | 2018-07-13T17:30:20.000Z | defmodule Realtime.MixProject do
use Mix.Project
def project do
[
aliases: aliases(Mix.env()),
app: :realtime,
build_path: "../../_build",
config_path: "../../config/config.exs",
deps: deps(),
deps_path: "../../deps",
elixir: "~> 1.6",
elixirc_paths: elixirc_path... | 22.754717 | 59 | 0.559701 |
1ad63b97589e282b416075da4f59c5e1ffec6bc4 | 7,500 | ex | Elixir | lib/services/authenticator.ex | kevinbaisas/oauth2_server | b622bb2c3f5f6e930a014d7ead7e3bfe14baed22 | [
"MIT"
] | 13 | 2016-05-16T13:27:42.000Z | 2017-03-14T19:57:33.000Z | lib/services/authenticator.ex | kvnbai/oauth2_server | b622bb2c3f5f6e930a014d7ead7e3bfe14baed22 | [
"MIT"
] | null | null | null | lib/services/authenticator.ex | kvnbai/oauth2_server | b622bb2c3f5f6e930a014d7ead7e3bfe14baed22 | [
"MIT"
] | 1 | 2016-06-23T18:14:53.000Z | 2016-06-23T18:14:53.000Z | defmodule Oauth2Server.Authenticator do
alias Oauth2Server.Repo
alias Oauth2Server.OauthClient
alias Oauth2Server.OauthAccessToken
alias Oauth2Server.OauthRefreshToken
alias Oauth2Server.User
# validates request
def validate(params) do
Repo.start_link
if validate_oauth_params(params) === true d... | 35.377358 | 157 | 0.646133 |
1ad6466ccb1b2266f4ff88edf2b998b498bc966e | 13,019 | ex | Elixir | clients/service_management/lib/google_api/service_management/v1/model/http_rule.ex | GoNZooo/elixir-google-api | cf3ad7392921177f68091f3d9001f1b01b92f1cc | [
"Apache-2.0"
] | null | null | null | clients/service_management/lib/google_api/service_management/v1/model/http_rule.ex | GoNZooo/elixir-google-api | cf3ad7392921177f68091f3d9001f1b01b92f1cc | [
"Apache-2.0"
] | null | null | null | clients/service_management/lib/google_api/service_management/v1/model/http_rule.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... | 178.342466 | 8,870 | 0.704355 |
1ad65811a89196028b08fbfd64e6f930efda7baa | 659 | ex | Elixir | lib/ex_raja_ongkir/city.ex | giraphme/ex_raja_ongkir | 6c7e7a811879d0adfd7eb574d0bbc665f1b7084d | [
"MIT"
] | null | null | null | lib/ex_raja_ongkir/city.ex | giraphme/ex_raja_ongkir | 6c7e7a811879d0adfd7eb574d0bbc665f1b7084d | [
"MIT"
] | 1 | 2018-04-24T08:27:20.000Z | 2018-04-24T08:27:20.000Z | lib/ex_raja_ongkir/city.ex | giraphme/ex_raja_ongkir | 6c7e7a811879d0adfd7eb574d0bbc665f1b7084d | [
"MIT"
] | null | null | null | defmodule ExRajaOngkir.City do
alias ExRajaOngkir.Request
defstruct [:id, :name, :province_id, :province_name, :type, :postal_code]
def get!(id \\ nil) do
{:ok, result} = get(id)
result
end
def get(id \\ nil)
def get(nil) do
"city"
|> Request.get()
|> Request.cast_to(__MODULE__)
end... | 18.305556 | 75 | 0.60091 |
1ad65ad3fd2b132f187e2ed9f1fe41d36c604d3b | 341 | exs | Elixir | config/test.exs | athonet-open/ex_sieve | 19d4e977f60d032f2267f1324bb5643b4deb3bf3 | [
"MIT"
] | null | null | null | config/test.exs | athonet-open/ex_sieve | 19d4e977f60d032f2267f1324bb5643b4deb3bf3 | [
"MIT"
] | null | null | null | config/test.exs | athonet-open/ex_sieve | 19d4e977f60d032f2267f1324bb5643b4deb3bf3 | [
"MIT"
] | null | null | null | use Mix.Config
config :ex_sieve, ecto_repos: [ExSieve.Repo]
config :ex_sieve, ExSieve.Repo,
adapter: Ecto.Adapters.Postgres,
pool: Ecto.Adapters.SQL.Sandbox,
database: "ex_sieve_test",
username: System.get_env("DB_USER") || System.get_env("USER"),
password: System.get_env("DB_PASSWORD")
config :logger, :co... | 26.230769 | 64 | 0.739003 |
1ad665b27839c951af75c54aa570d5a428279c7f | 74 | exs | Elixir | test/views/layout_view_test.exs | Around25/active | 8b301532fb79dca368cdabaf1bd7ade315abff99 | [
"MIT"
] | null | null | null | test/views/layout_view_test.exs | Around25/active | 8b301532fb79dca368cdabaf1bd7ade315abff99 | [
"MIT"
] | 1 | 2017-03-03T20:32:55.000Z | 2017-03-03T20:32:55.000Z | test/views/layout_view_test.exs | Around25/active | 8b301532fb79dca368cdabaf1bd7ade315abff99 | [
"MIT"
] | null | null | null | defmodule Active.LayoutViewTest do
use Active.ConnCase, async: true
end
| 18.5 | 34 | 0.810811 |
1ad6717fe7141f5e4cf3adee64e868949ffedf18 | 28,498 | exs | Elixir | apps/omg_watcher/test/omg_watcher/exit_processor/piggyback_test.exs | PinkDiamond1/elixir-omg | 70dfd24a0a1ddf5d1d9d71aab61ea25300f889f7 | [
"Apache-2.0"
] | 1 | 2020-05-01T12:30:09.000Z | 2020-05-01T12:30:09.000Z | apps/omg_watcher/test/omg_watcher/exit_processor/piggyback_test.exs | PinkDiamond1/elixir-omg | 70dfd24a0a1ddf5d1d9d71aab61ea25300f889f7 | [
"Apache-2.0"
] | null | null | null | apps/omg_watcher/test/omg_watcher/exit_processor/piggyback_test.exs | PinkDiamond1/elixir-omg | 70dfd24a0a1ddf5d1d9d71aab61ea25300f889f7 | [
"Apache-2.0"
] | 1 | 2021-12-04T00:37:46.000Z | 2021-12-04T00:37:46.000Z | # Copyright 2019 OmiseGO Pte Ltd
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writi... | 42.78979 | 120 | 0.642817 |
1ad6ba2889504343d160def5bcce80c4230db053 | 342 | ex | Elixir | lib/plate_slate/ordering/item.ex | conradwt/crafting-graphql-apis-in-elixir-with-absinthe | b26d050a350425ac189ea6d205834da1e47d4f90 | [
"MIT"
] | 1 | 2019-05-11T21:50:09.000Z | 2019-05-11T21:50:09.000Z | lib/plate_slate/ordering/item.ex | conradwt/crafting-graphql-apis-in-elixir-with-absinthe | b26d050a350425ac189ea6d205834da1e47d4f90 | [
"MIT"
] | null | null | null | lib/plate_slate/ordering/item.ex | conradwt/crafting-graphql-apis-in-elixir-with-absinthe | b26d050a350425ac189ea6d205834da1e47d4f90 | [
"MIT"
] | null | null | null | defmodule PlateSlate.Ordering.Item do
use Ecto.Schema
import Ecto.Changeset
embedded_schema do
field :price, :decimal
field :name, :string
field :quantity, :integer
end
def changeset(item, attrs) do
item
|> cast(attrs, [:price, :name, :quantity])
|> validate_required([:price, :name, ... | 20.117647 | 52 | 0.672515 |
1ad6d5f959e4371e9b8a3ff773d22184000b5008 | 47,780 | ex | Elixir | lib/elixir/lib/file.ex | evalphobia/elixir | a07a2362e5827b09d8b27be2c1ad2980d25b9768 | [
"Apache-2.0"
] | null | null | null | lib/elixir/lib/file.ex | evalphobia/elixir | a07a2362e5827b09d8b27be2c1ad2980d25b9768 | [
"Apache-2.0"
] | null | null | null | lib/elixir/lib/file.ex | evalphobia/elixir | a07a2362e5827b09d8b27be2c1ad2980d25b9768 | [
"Apache-2.0"
] | null | null | null | 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 ... | 32.261985 | 121 | 0.639577 |
1ad6e436b604c2d1cfeaa88157a222e569c9feef | 728 | ex | Elixir | apps/discordbot/lib/discordbot/entity/guild_record.ex | alexweav/discordbot | 1ee138f7c42a6901ab769e2ce59a6878bf603290 | [
"MIT"
] | 4 | 2018-11-19T06:10:52.000Z | 2022-02-03T01:50:23.000Z | apps/discordbot/lib/discordbot/entity/guild_record.ex | alexweav/discordbot | 1ee138f7c42a6901ab769e2ce59a6878bf603290 | [
"MIT"
] | 254 | 2018-11-19T06:08:51.000Z | 2021-07-22T13:47:26.000Z | apps/discordbot/lib/discordbot/entity/guild_record.ex | alexweav/discordbot | 1ee138f7c42a6901ab769e2ce59a6878bf603290 | [
"MIT"
] | null | null | null | defmodule DiscordBot.Entity.GuildRecord do
@moduledoc """
Represents a cached guild, plus metadata.
"""
defstruct [
:shard_connection,
:guild
]
@typedoc """
The PID of the `DiscordBot.Gateway.Connection` from which
this guild originated.
"""
@type shard_connection :: pid
@typedoc """
... | 19.157895 | 62 | 0.630495 |
1ad6e6b358c64d2a72a1f1c48a5d3ea2a22b5a99 | 156 | exs | Elixir | test/elixir_weather_test.exs | adrianomota/elixir_weather | 99aa6305ca4a7807f35c56ecf016a71a2baa6f2e | [
"MIT"
] | null | null | null | test/elixir_weather_test.exs | adrianomota/elixir_weather | 99aa6305ca4a7807f35c56ecf016a71a2baa6f2e | [
"MIT"
] | null | null | null | test/elixir_weather_test.exs | adrianomota/elixir_weather | 99aa6305ca4a7807f35c56ecf016a71a2baa6f2e | [
"MIT"
] | null | null | null | defmodule ElixirWeatherTest do
use ExUnit.Case
doctest ElixirWeather
test "greets the world" do
assert ElixirWeather.hello() == :world
end
end
| 17.333333 | 42 | 0.74359 |
1ad71547d7052814fd569a03d1d5789acbb8d549 | 2,660 | exs | Elixir | test/ets_lock_test.exs | appcues/ets_lock | 198fb9cfe5232504ca8d218ed5fca7afd4a74d6c | [
"MIT"
] | 1 | 2019-10-15T20:05:06.000Z | 2019-10-15T20:05:06.000Z | test/ets_lock_test.exs | appcues/ets_lock | 198fb9cfe5232504ca8d218ed5fca7afd4a74d6c | [
"MIT"
] | null | null | null | test/ets_lock_test.exs | appcues/ets_lock | 198fb9cfe5232504ca8d218ed5fca7afd4a74d6c | [
"MIT"
] | null | null | null | defmodule EtsLockTest do
use ExUnit.Case
import EtsLock
doctest EtsLock
test "exec_timeout" do
table = :ets.new(:exec_timeout_test, [:duplicate_bag, :public])
key = :key
spawn(fn ->
assert {:error, :exec_timeout} =
with_ets_lock(
table,
key,
... | 21.983471 | 83 | 0.460902 |
1ad72a602f3e36f7ea12055bbb3da76dd2254884 | 8,785 | ex | Elixir | lib/hubspot/mock_server.ex | jrissler/ex_hubspot | 1f9f48e499c090e3fd20e991fe88e74b1ed9aedb | [
"MIT"
] | null | null | null | lib/hubspot/mock_server.ex | jrissler/ex_hubspot | 1f9f48e499c090e3fd20e991fe88e74b1ed9aedb | [
"MIT"
] | null | null | null | lib/hubspot/mock_server.ex | jrissler/ex_hubspot | 1f9f48e499c090e3fd20e991fe88e74b1ed9aedb | [
"MIT"
] | null | null | null | defmodule ExHubspot.MockServer do
@moduledoc """
Mock Server to run tests
"""
use Plug.Router
plug Plug.Parsers, parsers: [:json], pass: ["text/*"], json_decoder: Jason
plug :match
plug :dispatch
get "/owners/v2/owners" do
response = [
%{
activeUserId: 1,
createdAt: 1_532_... | 26.783537 | 132 | 0.451793 |
1ad730654c40c31a7ea90b61d29c0c0c3e8ac097 | 1,699 | exs | Elixir | mix.exs | criticalbh/horde | 23e57b444e5c8503198a5cf5bb2df47d05352598 | [
"MIT"
] | null | null | null | mix.exs | criticalbh/horde | 23e57b444e5c8503198a5cf5bb2df47d05352598 | [
"MIT"
] | null | null | null | mix.exs | criticalbh/horde | 23e57b444e5c8503198a5cf5bb2df47d05352598 | [
"MIT"
] | null | null | null | defmodule Horde.MixProject do
use Mix.Project
def project do
[
app: :horde,
version: "0.7.0",
elixir: "~> 1.7",
start_permanent: Mix.env() == :prod,
elixirc_paths: elixirc_paths(Mix.env()),
deps: deps(),
docs: docs(),
package: package(),
name: "Horde",
... | 24.271429 | 82 | 0.557975 |
1ad737bf2ace26048c021d7abbe8b9658f570b1b | 4,978 | ex | Elixir | lib/rollbax/item.ex | maxbeizer/rollbax | c192d1c4bf7b550d4debc07292913521cc0dccd0 | [
"ISC"
] | null | null | null | lib/rollbax/item.ex | maxbeizer/rollbax | c192d1c4bf7b550d4debc07292913521cc0dccd0 | [
"ISC"
] | null | null | null | lib/rollbax/item.ex | maxbeizer/rollbax | c192d1c4bf7b550d4debc07292913521cc0dccd0 | [
"ISC"
] | null | null | null | defmodule Rollbax.Item do
@moduledoc false
# This module is responsible for building the payload for a Rollbar "Item".
# Refer to https://rollbar.com/docs/api/items_post for documentation on such
# payload.
@spec draft(String.t() | nil, String.t() | nil, map) :: map
def draft(token, environment, custom)
... | 29.282353 | 102 | 0.641623 |
1ad74fa37f3a567b72f99faf3822bc90843339b3 | 604 | exs | Elixir | exercises/02-higher-order-functions/reduce/length/tests.exs | DennisWinnepenninckx/distributed-applications | 06743e4e2a09dc52ff52be831e486bb073916173 | [
"BSD-3-Clause"
] | 1 | 2021-09-22T09:52:11.000Z | 2021-09-22T09:52:11.000Z | exercises/02-higher-order-functions/reduce/length/tests.exs | DennisWinnepenninckx/distributed-applications | 06743e4e2a09dc52ff52be831e486bb073916173 | [
"BSD-3-Clause"
] | 22 | 2019-06-19T18:58:13.000Z | 2020-03-16T14:43:06.000Z | exercises/02-higher-order-functions/reduce/length/tests.exs | DennisWinnepenninckx/distributed-applications | 06743e4e2a09dc52ff52be831e486bb073916173 | [
"BSD-3-Clause"
] | 32 | 2019-09-19T03:25:11.000Z | 2020-10-06T15:01:47.000Z | defmodule Setup do
@script "shared.exs"
def setup(directory \\ ".") do
path = Path.join(directory, @script)
if File.exists?(path) do
Code.require_file(path)
Shared.setup(__DIR__)
else
setup(Path.join(directory, ".."))
end
end
end
Setup.setup
defmodule Tests do
use ExUnit.C... | 20.827586 | 55 | 0.63245 |
1ad76bea610fe71b60d7829297a298f1ee0a06b9 | 861 | ex | Elixir | apps/bouncer/lib/bouncer.ex | norbu09/e_no_time | 16a0db136dd91cdcf38d4aab5f11b0684dae289d | [
"BSD-2-Clause"
] | null | null | null | apps/bouncer/lib/bouncer.ex | norbu09/e_no_time | 16a0db136dd91cdcf38d4aab5f11b0684dae289d | [
"BSD-2-Clause"
] | null | null | null | apps/bouncer/lib/bouncer.ex | norbu09/e_no_time | 16a0db136dd91cdcf38d4aab5f11b0684dae289d | [
"BSD-2-Clause"
] | null | null | null | defmodule Bouncer do
@moduledoc """
This is the central registry that handles process registration in Consul
"""
@doc """
Registering a worker is simple:
## Examples
iex> Bouncer.add("foo")
{:ok, %{"status" => "success"}}
"""
def add(name) do
Exconsul.add_service(%{"Name" => name})
... | 17.571429 | 74 | 0.584204 |
1ad7a566a1d41cfd9dfcfe33b460f18986969887 | 2,442 | exs | Elixir | mix.exs | duksis/elixir_jobs | e4715cdb6ad2e5a067396358c576992b1e0212e3 | [
"MIT"
] | null | null | null | mix.exs | duksis/elixir_jobs | e4715cdb6ad2e5a067396358c576992b1e0212e3 | [
"MIT"
] | null | null | null | mix.exs | duksis/elixir_jobs | e4715cdb6ad2e5a067396358c576992b1e0212e3 | [
"MIT"
] | null | null | null | defmodule ElixirJobs.Mixfile do
use Mix.Project
def project do
[
app: :elixir_jobs,
version: "0.0.1",
elixir: "~> 1.5",
elixirc_paths: elixirc_paths(Mix.env()),
compilers: [:phoenix, :gettext] ++ Mix.compilers(),
build_embedded: Mix.env() == :prod,
start_permanent: Mix... | 26.258065 | 80 | 0.525389 |
1ad7c811f0f776d53cae09493dcc984fed964f8b | 1,484 | exs | Elixir | rel/config.exs | adammcfadden/raptor | 4ee7ee2ec2e0d9e08b30a9c6c8d14c9bc19e80d5 | [
"Unlicense"
] | 1 | 2017-05-11T21:09:44.000Z | 2017-05-11T21:09:44.000Z | rel/config.exs | adammcfadden/raptor | 4ee7ee2ec2e0d9e08b30a9c6c8d14c9bc19e80d5 | [
"Unlicense"
] | 1 | 2017-05-12T00:50:58.000Z | 2017-05-12T19:00:22.000Z | rel/config.exs | adammcfadden/raptor | 4ee7ee2ec2e0d9e08b30a9c6c8d14c9bc19e80d5 | [
"Unlicense"
] | 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.
Path.join(["rel", "plugins", "*.exs"])
|> Path.wildcard()
|> Enum.map(&Code.eval_file(&1))
use Mix.Releases.Config,
# T... | 30.916667 | 81 | 0.736523 |
1ad7d3e5069205db75421cf5f3f05d9cf11f22db | 802 | ex | Elixir | lib/rate_limit_sup.ex | tmcgilchrist/rate_limit | 11fccefc000cc8dfd731c192d486f9626e1d716f | [
"BSD-3-Clause"
] | null | null | null | lib/rate_limit_sup.ex | tmcgilchrist/rate_limit | 11fccefc000cc8dfd731c192d486f9626e1d716f | [
"BSD-3-Clause"
] | null | null | null | lib/rate_limit_sup.ex | tmcgilchrist/rate_limit | 11fccefc000cc8dfd731c192d486f9626e1d716f | [
"BSD-3-Clause"
] | null | null | null | defmodule RateLimitSup do
@moduledoc """
Dynamic supervisor for Rate Limit GenServers
A new RateLimit GenServer is started for each RateLimit.setup/3
"""
use DynamicSupervisor
def start_link() do
DynamicSupervisor.start_link( __MODULE__, [], name: __MODULE__)
end
@doc """
Starts a supervised Ra... | 25.0625 | 77 | 0.714464 |
1ad7d72e48ba6cf3d797a6d131d1f1ee2e352705 | 73 | exs | Elixir | test/test_helper.exs | dannielb/blog-post-api | 214520beb57164375bc6596e85cbc42be67c0fb9 | [
"MIT"
] | null | null | null | test/test_helper.exs | dannielb/blog-post-api | 214520beb57164375bc6596e85cbc42be67c0fb9 | [
"MIT"
] | null | null | null | test/test_helper.exs | dannielb/blog-post-api | 214520beb57164375bc6596e85cbc42be67c0fb9 | [
"MIT"
] | null | null | null | ExUnit.start()
Ecto.Adapters.SQL.Sandbox.mode(BlogPostApi.Repo, :manual)
| 24.333333 | 57 | 0.794521 |
1ad7d7a9bfa7133e1c451346720ec2923843c42c | 9,706 | ex | Elixir | lib/mppm/broker/method_call.ex | QBonaventure/mppm | 06047083e3f56e750b60a2c2bd2c430228066e63 | [
"MIT"
] | 6 | 2020-11-18T10:10:51.000Z | 2021-03-17T14:28:36.000Z | lib/mppm/broker/method_call.ex | QBonaventure/mppm | 06047083e3f56e750b60a2c2bd2c430228066e63 | [
"MIT"
] | 6 | 2020-11-10T21:50:43.000Z | 2021-03-04T09:41:22.000Z | lib/mppm/broker/method_call.ex | QBonaventure/mppm | 06047083e3f56e750b60a2c2bd2c430228066e63 | [
"MIT"
] | null | null | null | defmodule Mppm.Broker.MethodCall do
def dispatch(server_login, %XMLRPC.MethodCall{method_name: "ManiaPlanet.ModeScriptCallbackArray", params: [callback_name, [raw_data]]}) do
{:ok, data} = Jason.decode(raw_data)
dispatch_script_callback(server_login, callback_name, data)
end
def dispatch(server_login, ... | 37.474903 | 140 | 0.706985 |
1ad7dda158e18781fac81c5e899fb9245b1d94a3 | 489 | ex | Elixir | lib/namedb_web/views/error_view.ex | empex2019liveview/namedb | fd01151dd293f9740204435fed524bc364f81069 | [
"MIT"
] | null | null | null | lib/namedb_web/views/error_view.ex | empex2019liveview/namedb | fd01151dd293f9740204435fed524bc364f81069 | [
"MIT"
] | null | null | null | lib/namedb_web/views/error_view.ex | empex2019liveview/namedb | fd01151dd293f9740204435fed524bc364f81069 | [
"MIT"
] | null | null | null | defmodule NamedbWeb.ErrorView do
use NamedbWeb, :view
# If you want to customize a particular status code
# for a certain format, you may uncomment below.
# def render("500.html", _assigns) do
# "Internal Server Error"
# end
# By default, Phoenix returns the status message from
# the template name. ... | 28.764706 | 61 | 0.734151 |
1ad821d67a8d3bda8ed054cc35eb42abf0a7baa1 | 1,976 | exs | Elixir | test/commodity_api/iam/user/personal_information/personal_information_policy_test.exs | akdilsiz/commodity-cloud | 08c366c9fc95fbb3565131672db4cc52f8b870c9 | [
"Apache-2.0"
] | 7 | 2019-04-11T21:12:49.000Z | 2021-04-14T12:56:42.000Z | test/commodity_api/iam/user/personal_information/personal_information_policy_test.exs | akdilsiz/commodity-cloud | 08c366c9fc95fbb3565131672db4cc52f8b870c9 | [
"Apache-2.0"
] | null | null | null | test/commodity_api/iam/user/personal_information/personal_information_policy_test.exs | akdilsiz/commodity-cloud | 08c366c9fc95fbb3565131672db4cc52f8b870c9 | [
"Apache-2.0"
] | 2 | 2019-06-06T18:05:33.000Z | 2019-07-16T08:49:45.000Z | ##
# Copyright 2018 Abdulkadir DILSIZ
#
# 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... | 37.283019 | 78 | 0.733806 |
1ad83b17b4942a7ac06fe04a92de342052a9b9a0 | 1,199 | exs | Elixir | test/configuration/config_finally_error_test.exs | MeneDev/espec | ec4b3d579c5192999e930224a8a2650bb1fdf0bc | [
"Apache-2.0"
] | 807 | 2015-03-25T14:00:19.000Z | 2022-03-24T08:08:15.000Z | test/configuration/config_finally_error_test.exs | MeneDev/espec | ec4b3d579c5192999e930224a8a2650bb1fdf0bc | [
"Apache-2.0"
] | 254 | 2015-03-27T10:12:25.000Z | 2021-07-12T01:40:15.000Z | test/configuration/config_finally_error_test.exs | MeneDev/espec | ec4b3d579c5192999e930224a8a2650bb1fdf0bc | [
"Apache-2.0"
] | 85 | 2015-04-02T10:25:19.000Z | 2021-01-30T21:30:43.000Z | defmodule ConfigFinallyRaiseTest do
use ExUnit.Case, async: true
defmodule SomeSpec do
use ESpec
it do: "some test"
end
setup_all do
ESpec.configure(fn c ->
c.finally(fn ->
raise "An exception"
end)
end)
on_exit(fn ->
ESpec.configure(fn c -> c.finally(fn -> :ok e... | 20.672414 | 82 | 0.631359 |
1ad847a6d99786e3a630e663a6ef4f2ee19a3630 | 2,922 | exs | Elixir | apps/ello_v2/test/controllers/manage/impression_count_controller_test.exs | ello/apex | 4acb096b3ce172ff4ef9a51e5d068d533007b920 | [
"MIT"
] | 16 | 2017-06-21T21:31:20.000Z | 2021-05-09T03:23:26.000Z | apps/ello_v2/test/controllers/manage/impression_count_controller_test.exs | ello/apex | 4acb096b3ce172ff4ef9a51e5d068d533007b920 | [
"MIT"
] | 25 | 2017-06-07T12:18:28.000Z | 2018-06-08T13:27:43.000Z | apps/ello_v2/test/controllers/manage/impression_count_controller_test.exs | ello/apex | 4acb096b3ce172ff4ef9a51e5d068d533007b920 | [
"MIT"
] | 3 | 2018-06-14T15:34:07.000Z | 2022-02-28T21:06:13.000Z | defmodule Ello.V2.Manage.ImpressionCountControllerTest do
use Ello.V2.ConnCase
alias Ello.Grandstand
setup %{conn: conn} do
archer = Script.insert(:archer)
brand = Factory.insert(:user)
staff = Factory.insert(:user, %{is_staff: true})
a_inv1 = Factory.insert(:artist_invite, %{status: "open"})
... | 37.461538 | 133 | 0.638946 |
1ad8685b5083e8b013bf0537a08b142853d55dc0 | 4,697 | ex | Elixir | lib/event_bus/managers/observation.ex | xadhoom/event_bus | 1f466b66dfcd008160fd5c1caa020a29d047afb7 | [
"MIT"
] | null | null | null | lib/event_bus/managers/observation.ex | xadhoom/event_bus | 1f466b66dfcd008160fd5c1caa020a29d047afb7 | [
"MIT"
] | null | null | null | lib/event_bus/managers/observation.ex | xadhoom/event_bus | 1f466b66dfcd008160fd5c1caa020a29d047afb7 | [
"MIT"
] | null | null | null | defmodule EventBus.Manager.Observation do
@moduledoc false
###########################################################################
# Event Observation module is a helper to get info for the events and also an
# organizer for the events happened in time. It automatically deletes
# processed events from th... | 30.5 | 79 | 0.608686 |
1ad873bfc42114a9c810f8286d68b8917815206d | 1,972 | exs | Elixir | apps/xee/test/controllers/registration_controller_test.exs | xeejp/xee | 669e5a8030948e6d37ee0d33d3b37b4abdc34001 | [
"MIT"
] | 11 | 2015-12-24T07:51:45.000Z | 2019-03-05T12:29:31.000Z | apps/xee/test/controllers/registration_controller_test.exs | xeejp/xee | 669e5a8030948e6d37ee0d33d3b37b4abdc34001 | [
"MIT"
] | 62 | 2015-12-25T02:58:20.000Z | 2020-03-04T06:52:11.000Z | apps/xee/test/controllers/registration_controller_test.exs | xeejp/xee | 669e5a8030948e6d37ee0d33d3b37b4abdc34001 | [
"MIT"
] | 1 | 2016-07-19T03:28:08.000Z | 2016-07-19T03:28:08.000Z | defmodule XeeWeb.RegistrationControllerTest do
use XeeWeb.ConnCase
use ExUnit.Case, async: false
use XeeWeb.SessionTestHelper, controller: XeeWeb.RegistrationController
alias Xee.User
alias Xee.Session
@new_user_attrs %{name: "new_user_name", password: "new_user_password"}
@existed_user_attrs %{name: "e... | 31.806452 | 90 | 0.675456 |
1ad8b1edae473933a4bb8a06dace9382fb4688e8 | 240 | ex | Elixir | lib/panda/build.ex | lsimoneau/panda-ci | 24804b310eda9800a721e71e97bcb0304554517d | [
"MIT"
] | null | null | null | lib/panda/build.ex | lsimoneau/panda-ci | 24804b310eda9800a721e71e97bcb0304554517d | [
"MIT"
] | null | null | null | lib/panda/build.ex | lsimoneau/panda-ci | 24804b310eda9800a721e71e97bcb0304554517d | [
"MIT"
] | null | null | null | defmodule Panda.Build do
def start(build) do
[repo_name|_] = Regex.run(~r/\/(.*)\.git/, build.git, capture: :all_but_first)
System.cmd("git", ["clone", build.git, Path.expand("~/panda-builds/#{repo_name}/#{build.id}")])
end
end
| 34.285714 | 99 | 0.641667 |
1ad8d2c4f3acdb0ee66dd79a5275ec9f0943dd35 | 664 | ex | Elixir | lib/tint/distance/euclidean.ex | tlux/tint | 742b3cc8ffd5e90bc78fe0413286af8ec593298c | [
"MIT"
] | 14 | 2019-10-09T19:36:04.000Z | 2022-01-28T12:00:56.000Z | lib/tint/distance/euclidean.ex | tlux/tint | 742b3cc8ffd5e90bc78fe0413286af8ec593298c | [
"MIT"
] | null | null | null | lib/tint/distance/euclidean.ex | tlux/tint | 742b3cc8ffd5e90bc78fe0413286af8ec593298c | [
"MIT"
] | null | null | null | defmodule Tint.Distance.Euclidean do
@moduledoc """
A module that implements the Euclidean distance algorithm for RGB
colors. (https://en.wikipedia.org/wiki/Color_difference#Euclidean)
"""
@behaviour Tint.Distance
@impl true
def distance(color, other_color, opts) do
color = Tint.to_rgb(color)
ot... | 30.181818 | 73 | 0.685241 |
1ad8f4bc3a410e612b079525c95525a7c0f78f84 | 764 | exs | Elixir | test/messages_test.exs | ayrat-playground/balalaika_bear | bcccdd4a0caf075e133ef4f162eb13e3d28b2d65 | [
"MIT"
] | 5 | 2018-04-30T09:48:17.000Z | 2020-05-01T10:20:15.000Z | test/messages_test.exs | BalalaikaIndustries/balalaika_bear | bcccdd4a0caf075e133ef4f162eb13e3d28b2d65 | [
"MIT"
] | 7 | 2018-04-28T06:39:10.000Z | 2018-04-28T07:31:59.000Z | test/messages_test.exs | ayrat-playground/balalaika_bear | bcccdd4a0caf075e133ef4f162eb13e3d28b2d65 | [
"MIT"
] | 2 | 2018-04-27T19:42:04.000Z | 2020-05-01T10:20:02.000Z | defmodule BalalaikaBear.MessagesTest do
use ExUnit.Case
use ExVCR.Mock, adapter: ExVCR.Adapter.Hackney
test "gets messages" do
use_cassette "messages_get" do
params = %{
access_token:
"d5aa5092f0f9a4fb4456eccce180bb80a8f75af979064e817c54904f3c4c4a8362cf188398703d0e84ed2"
}
... | 25.466667 | 97 | 0.672775 |
1ad9232d9c3933471307c9b06a22c36da8f91e7b | 488 | ex | Elixir | gen_stage/eth_sync/lib/eth_sync.ex | zemuldo/learning | 79595633638982cb1d7f6135070b703bfe60808a | [
"MIT"
] | 1 | 2019-10-26T18:38:13.000Z | 2019-10-26T18:38:13.000Z | gen_stage/eth_sync/lib/eth_sync.ex | zemuldo/learning | 79595633638982cb1d7f6135070b703bfe60808a | [
"MIT"
] | null | null | null | gen_stage/eth_sync/lib/eth_sync.ex | zemuldo/learning | 79595633638982cb1d7f6135070b703bfe60808a | [
"MIT"
] | null | null | null | defmodule EthSync do
alias EthSync.Producer
alias EthSync.Consumer
def start do
IO.puts("Starting processes")
IO.puts("Starting producer")
:timer.sleep(2_000)
{:ok, producer} = GenStage.start_link(Producer, [])
IO.puts("Starting consumer")
:timer.sleep(2_000)
{:ok, consumer} = GenSt... | 23.238095 | 67 | 0.67623 |
1ad92446e9fc56ca3b1041c7c1d2771ea9547134 | 1,404 | ex | Elixir | bidding_poc/lib/bidding_poc_web/telemetry.ex | KeenMate/phoenix-websocket-auction | 412148ad5621b511c0690b9395f4b6c9ce3a3352 | [
"MIT"
] | null | null | null | bidding_poc/lib/bidding_poc_web/telemetry.ex | KeenMate/phoenix-websocket-auction | 412148ad5621b511c0690b9395f4b6c9ce3a3352 | [
"MIT"
] | null | null | null | bidding_poc/lib/bidding_poc_web/telemetry.ex | KeenMate/phoenix-websocket-auction | 412148ad5621b511c0690b9395f4b6c9ce3a3352 | [
"MIT"
] | null | null | null | defmodule BiddingPocWeb.Telemetry do
use Supervisor
import Telemetry.Metrics
def start_link(arg) do
Supervisor.start_link(__MODULE__, arg, name: __MODULE__)
end
@impl true
def init(_arg) do
children = [
# Telemetry poller will execute the given period measurements
# every 10_000ms. Lea... | 28.653061 | 86 | 0.671652 |
1ad9282f11d0bccdd7454fa6effd063895034bb9 | 357 | ex | Elixir | apps/site/lib/hub_stop.ex | noisecapella/dotcom | d5ef869412102d2230fac3dcc216f01a29726227 | [
"MIT"
] | 42 | 2019-05-29T16:05:30.000Z | 2021-08-09T16:03:37.000Z | apps/site/lib/hub_stop.ex | noisecapella/dotcom | d5ef869412102d2230fac3dcc216f01a29726227 | [
"MIT"
] | 872 | 2019-05-29T17:55:50.000Z | 2022-03-30T09:28:43.000Z | apps/site/lib/hub_stop.ex | noisecapella/dotcom | d5ef869412102d2230fac3dcc216f01a29726227 | [
"MIT"
] | 12 | 2019-07-01T18:33:21.000Z | 2022-03-10T02:13:57.000Z | defmodule HubStop do
@moduledoc """
Represents a HubStop, which contains an image path and and a detailedStop
"""
defstruct detailed_stop: %DetailedStop{},
image: "",
alt_text: ""
@type t :: %__MODULE__{
detailed_stop: DetailedStop.t(),
image: String.t(),
... | 22.3125 | 75 | 0.577031 |
1ad935e586db2440e84d28fd76e62499391d6ca7 | 2,352 | ex | Elixir | clients/security_center/lib/google_api/security_center/v1/model/google_cloud_securitycenter_v1p1beta1_resource.ex | MasashiYokota/elixir-google-api | 975dccbff395c16afcb62e7a8e411fbb58e9ab01 | [
"Apache-2.0"
] | null | null | null | clients/security_center/lib/google_api/security_center/v1/model/google_cloud_securitycenter_v1p1beta1_resource.ex | MasashiYokota/elixir-google-api | 975dccbff395c16afcb62e7a8e411fbb58e9ab01 | [
"Apache-2.0"
] | null | null | null | clients/security_center/lib/google_api/security_center/v1/model/google_cloud_securitycenter_v1p1beta1_resource.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... | 36.75 | 169 | 0.715561 |
1ad93ee3e0a01cd2a8cd8439df7372482bbc165d | 699 | ex | Elixir | lib/fexr_web/gettext.ex | Schultzer/fexr | f64d67b78bc785ae967f4c1193491a1d9cf33279 | [
"MIT",
"Unlicense"
] | 4 | 2017-08-13T09:03:24.000Z | 2018-06-19T06:32:07.000Z | lib/fexr_web/gettext.ex | Schultzer/fexr | f64d67b78bc785ae967f4c1193491a1d9cf33279 | [
"MIT",
"Unlicense"
] | null | null | null | lib/fexr_web/gettext.ex | Schultzer/fexr | f64d67b78bc785ae967f4c1193491a1d9cf33279 | [
"MIT",
"Unlicense"
] | null | null | null | defmodule FexrWeb.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 FexrWeb.Gettext
# Simple translation
gettext "Here is the str... | 27.96 | 72 | 0.676681 |
1ad948c78353d8abfcaa4615389a5d03aac49395 | 1,274 | exs | Elixir | apps/site/test/site_web/views/error_view_test.exs | noisecapella/dotcom | d5ef869412102d2230fac3dcc216f01a29726227 | [
"MIT"
] | 42 | 2019-05-29T16:05:30.000Z | 2021-08-09T16:03:37.000Z | apps/site/test/site_web/views/error_view_test.exs | noisecapella/dotcom | d5ef869412102d2230fac3dcc216f01a29726227 | [
"MIT"
] | 872 | 2019-05-29T17:55:50.000Z | 2022-03-30T09:28:43.000Z | apps/site/test/site_web/views/error_view_test.exs | noisecapella/dotcom | d5ef869412102d2230fac3dcc216f01a29726227 | [
"MIT"
] | 12 | 2019-07-01T18:33:21.000Z | 2022-03-10T02:13:57.000Z | defmodule SiteWeb.ErrorViewTest do
use SiteWeb.ConnCase, async: false
import Phoenix.View, only: [render_to_string: 3]
import Phoenix.Controller
test "adds 'not-found' to body class on 404 pages" do
conn = get(default_conn(), "/not-found")
assert html_response(conn, 404) =~ "not-found"
end
test "... | 30.333333 | 73 | 0.650706 |
1ad97251f66de548eea7575dca0ec1053921a904 | 2,333 | ex | Elixir | lib/oli_web/plugs/maybe_enroll_open_and_free_user.ex | chrislawson/oli-torus | 94165b211ab74fac3e7c8a14110a394fa9a6f320 | [
"MIT"
] | null | null | null | lib/oli_web/plugs/maybe_enroll_open_and_free_user.ex | chrislawson/oli-torus | 94165b211ab74fac3e7c8a14110a394fa9a6f320 | [
"MIT"
] | null | null | null | lib/oli_web/plugs/maybe_enroll_open_and_free_user.ex | chrislawson/oli-torus | 94165b211ab74fac3e7c8a14110a394fa9a6f320 | [
"MIT"
] | null | null | null | defmodule Oli.Plugs.MaybeEnrollOpenAndFreeUser do
import Plug.Conn
import Phoenix.Controller
import Oli.Utils
alias Oli.Accounts
alias Oli.Delivery.Sections
alias Oli.Delivery.Sections.Section
alias OliWeb.Router.Helpers, as: Routes
alias Lti_1p3.Tool.ContextRoles
def init(opts), do: opts
def cal... | 26.213483 | 89 | 0.654522 |
1ad9781b499fcbb02d13227660def761fee6c616 | 2,607 | ex | Elixir | clients/sheets/lib/google_api/sheets/v4/model/update_developer_metadata_request.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/sheets/lib/google_api/sheets/v4/model/update_developer_metadata_request.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/sheets/lib/google_api/sheets/v4/model/update_developer_metadata_request.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... | 43.45 | 179 | 0.745685 |
1ad9ca7b721f341c4d6a42d35812bb9a80c6dbd3 | 86,232 | exs | Elixir | priv/endpoints.exs | phanmn/ex_aws | cb89de68173fd2175c5b6587eef9b0ef3f43fd0b | [
"MIT"
] | null | null | null | priv/endpoints.exs | phanmn/ex_aws | cb89de68173fd2175c5b6587eef9b0ef3f43fd0b | [
"MIT"
] | null | null | null | priv/endpoints.exs | phanmn/ex_aws | cb89de68173fd2175c5b6587eef9b0ef3f43fd0b | [
"MIT"
] | null | null | null | %{
"partitions" => [
%{
"defaults" => %{
"hostname" => "{service}.{region}.{dnsSuffix}",
"protocols" => ["https"],
"signatureVersions" => ["v4"]
},
"dnsSuffix" => "amazonaws.com",
"partition" => "aws",
"partitionName" => "AWS Standard",
"regionRegex" => ... | 34.003155 | 98 | 0.309178 |
1ad9d661414af9ec8cf3bebbcdd9efb4d4d1dc4e | 3,670 | ex | Elixir | lib/glimesh_web/live/platform_subscription_live/index.ex | itsUnsmart/glimesh.tv | 22c532184bb5046f6c6d8232e8bd66ba534c01c1 | [
"MIT"
] | null | null | null | lib/glimesh_web/live/platform_subscription_live/index.ex | itsUnsmart/glimesh.tv | 22c532184bb5046f6c6d8232e8bd66ba534c01c1 | [
"MIT"
] | null | null | null | lib/glimesh_web/live/platform_subscription_live/index.ex | itsUnsmart/glimesh.tv | 22c532184bb5046f6c6d8232e8bd66ba534c01c1 | [
"MIT"
] | null | null | null | defmodule GlimeshWeb.PlatformSubscriptionLive.Index do
use GlimeshWeb, :live_view
alias Glimesh.Accounts
alias Glimesh.Payments
alias Payments
@impl true
def mount(_params, session, socket) do
user = Accounts.get_user_by_session_token(session["user_token"])
# If the viewer is logged in set their l... | 34.952381 | 98 | 0.686649 |
1ad9e8294c00b1124b51b917d81e28ac6a2547f9 | 333 | exs | Elixir | config/config.exs | andykingking/spell | fc7f3c5235bc45017e7a8a51b6fb3159b2d750e2 | [
"Apache-2.0"
] | 76 | 2015-05-14T20:44:55.000Z | 2022-03-25T02:24:27.000Z | config/config.exs | andykingking/spell | fc7f3c5235bc45017e7a8a51b6fb3159b2d750e2 | [
"Apache-2.0"
] | 46 | 2015-05-09T19:46:49.000Z | 2019-08-02T04:01:46.000Z | config/config.exs | andykingking/spell | fc7f3c5235bc45017e7a8a51b6fb3159b2d750e2 | [
"Apache-2.0"
] | 27 | 2015-06-23T11:32:34.000Z | 2020-09-21T15:36:42.000Z | use Mix.Config
log_level = :info
config :logger,
# handle_otp_reports: true,
# handle_sasl_reports: true,
level: log_level
config :logger, :console,
level: log_level
# Import env config
config_file = "#{Mix.env}.exs"
if Path.join("config", config_file) |> Path.expand |> File.exists? do
import_config(conf... | 17.526316 | 69 | 0.720721 |
1ada0a4b74d9dac2310d868029906b6bdfed2564 | 1,596 | ex | Elixir | clients/compute/lib/google_api/compute/v1/model/named_port.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2021-12-20T03:40:53.000Z | 2021-12-20T03:40:53.000Z | clients/compute/lib/google_api/compute/v1/model/named_port.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2020-08-18T00:11:23.000Z | 2020-08-18T00:44:16.000Z | clients/compute/lib/google_api/compute/v1/model/named_port.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... | 31.92 | 147 | 0.706767 |
1ada4d8cdfbe658cf40a00b567b96c1910fd9e7b | 5,522 | ex | Elixir | lib/changelog_web/helpers/shared_helpers.ex | theafricanengineer/changelog.com | 4954d0df516c0a325667ec6c1fbbf02d68c9b953 | [
"MIT"
] | null | null | null | lib/changelog_web/helpers/shared_helpers.ex | theafricanengineer/changelog.com | 4954d0df516c0a325667ec6c1fbbf02d68c9b953 | [
"MIT"
] | null | null | null | lib/changelog_web/helpers/shared_helpers.ex | theafricanengineer/changelog.com | 4954d0df516c0a325667ec6c1fbbf02d68c9b953 | [
"MIT"
] | null | null | null | defmodule ChangelogWeb.Helpers.SharedHelpers do
use Phoenix.HTML
alias Changelog.{ListKit, Regexp}
alias Phoenix.{Controller, Naming}
@doc """
Returns `class_name` for a given connection if it matches any of the provided
'matchers'. A 'matcher' could be a string representation of a controller/
action co... | 33.466667 | 119 | 0.672582 |
1ada8c1f7355bb50de52db9a290e339ccd4e63bb | 12,102 | ex | Elixir | apps/cashtrail/lib/cashtrail/contacts.ex | maxmaccari/cashtrail | 74ec7ff1f8a41299a6086dc98719a32cbfbe9ee7 | [
"MIT"
] | 6 | 2020-05-02T01:12:24.000Z | 2020-06-23T12:31:32.000Z | apps/cashtrail/lib/cashtrail/contacts.ex | maxmaccari/cashtrail | 74ec7ff1f8a41299a6086dc98719a32cbfbe9ee7 | [
"MIT"
] | 16 | 2020-05-02T00:07:51.000Z | 2021-06-11T01:54:11.000Z | apps/cashtrail/lib/cashtrail/contacts.ex | maxmaccari/cashtrail | 74ec7ff1f8a41299a6086dc98719a32cbfbe9ee7 | [
"MIT"
] | null | null | null | defmodule Cashtrail.Contacts do
@moduledoc """
The Contacts context manages the contact data of one entity.
See `Cashtrail.Contacts.Contact` to have more info about what contacts mean in
the application.
"""
import Ecto.Query, warn: false
alias Cashtrail.Repo
alias Cashtrail.{Contacts, Entities, Pagi... | 31.931398 | 103 | 0.666915 |
1ada95ef3a71ab554a1521012a55857a15666e76 | 2,247 | exs | Elixir | test/point_polygon_test.exs | codabrink/topo | f1ca4b7fe337a67285ee4c65a34fb521b119342c | [
"MIT"
] | 110 | 2016-05-05T21:09:19.000Z | 2022-03-08T05:22:16.000Z | test/point_polygon_test.exs | codabrink/topo | f1ca4b7fe337a67285ee4c65a34fb521b119342c | [
"MIT"
] | 15 | 2016-12-01T00:32:11.000Z | 2022-01-18T13:56:37.000Z | test/point_polygon_test.exs | codabrink/topo | f1ca4b7fe337a67285ee4c65a34fb521b119342c | [
"MIT"
] | 24 | 2016-09-19T20:06:50.000Z | 2021-06-16T06:41:10.000Z | defmodule PointPolygonTest do
use ExUnit.Case
@convex %Geo.Polygon{coordinates: [[{60, 120}, {60, 40}, {160, 40}, {160, 120}, {60, 120}]]}
@concave Path.join(["test", "fixtures", "poly.geo.json"])
|> File.read!()
|> Poison.decode!()
|> Geo.JSON.decode!()
@with_hole %Geo.Polygon... | 29.96 | 94 | 0.621273 |
1ada9f322375bb72a3a3fc9281e0a61419e20c50 | 621 | exs | Elixir | test/views_test.exs | azohra/BlockBox | 8c957022b381a9ccc187fa090c38bd9d61759687 | [
"MIT"
] | 12 | 2019-11-18T20:46:19.000Z | 2020-12-20T18:55:30.000Z | test/views_test.exs | azohra/BlockBox | 8c957022b381a9ccc187fa090c38bd9d61759687 | [
"MIT"
] | 4 | 2019-11-22T18:54:51.000Z | 2020-04-27T02:01:24.000Z | test/views_test.exs | azohra/BlockBox | 8c957022b381a9ccc187fa090c38bd9d61759687 | [
"MIT"
] | null | null | null | defmodule BlockBox.ViewsTest do
use ExUnit.Case
alias BlockBox.Views, as: Views
test "build_view" do
assert Views.build_view(:modal, "title", []) == %{
blocks: [],
type: :modal,
title: %{text: "title", type: :plain_text}
}
assert Views.build_view(:modal,... | 29.571429 | 88 | 0.508857 |
1adaa1377d31eb76544780291492a09a9e4ca9fc | 252 | ex | Elixir | lib/screens/v2/candidate_generator.ex | mbta/screens | 4b586970f8844b19543bb2ffd4b032a89f6fa40a | [
"MIT"
] | 3 | 2021-07-27T14:11:00.000Z | 2022-01-03T14:16:43.000Z | lib/screens/v2/candidate_generator.ex | mbta/screens | 4b586970f8844b19543bb2ffd4b032a89f6fa40a | [
"MIT"
] | 444 | 2021-03-10T20:57:17.000Z | 2022-03-31T16:00:35.000Z | lib/screens/v2/candidate_generator.ex | mbta/screens | 4b586970f8844b19543bb2ffd4b032a89f6fa40a | [
"MIT"
] | null | null | null | defmodule Screens.V2.CandidateGenerator do
@moduledoc false
alias Screens.V2.ScreenData
@callback screen_template() :: Screens.V2.Template.template()
@callback candidate_instances(ScreenData.config()) :: ScreenData.candidate_instances()
end
| 25.2 | 88 | 0.789683 |
1adaebd0f6cb8c75446af5412ea190689b4f5718 | 882 | ex | Elixir | clients/big_query/lib/google_api/big_query/v2/metadata.ex | myskoach/elixir-google-api | 4f8cbc2fc38f70ffc120fd7ec48e27e46807b563 | [
"Apache-2.0"
] | null | null | null | clients/big_query/lib/google_api/big_query/v2/metadata.ex | myskoach/elixir-google-api | 4f8cbc2fc38f70ffc120fd7ec48e27e46807b563 | [
"Apache-2.0"
] | 1 | 2020-12-18T09:25:12.000Z | 2020-12-18T09:25:12.000Z | clients/big_query/lib/google_api/big_query/v2/metadata.ex | myskoach/elixir-google-api | 4f8cbc2fc38f70ffc120fd7ec48e27e46807b563 | [
"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... | 32.666667 | 74 | 0.758503 |
1adb3d763025ba9eb5ce89a37d7869719dbb9bc8 | 3,835 | ex | Elixir | lib/ex_tectonicdb/connection.ex | yurikoval/ex_tectonicdb | 920444fdf085dc2b7a5cba4ad9fb58654312b4b3 | [
"MIT"
] | 13 | 2020-05-16T15:24:24.000Z | 2022-03-09T20:51:35.000Z | lib/ex_tectonicdb/connection.ex | yurikoval/ex_tectonicdb | 920444fdf085dc2b7a5cba4ad9fb58654312b4b3 | [
"MIT"
] | 8 | 2021-02-19T06:11:10.000Z | 2022-01-13T05:19:58.000Z | lib/ex_tectonicdb/connection.ex | yurikoval/ex_tectonicdb | 920444fdf085dc2b7a5cba4ad9fb58654312b4b3 | [
"MIT"
] | 1 | 2020-05-17T05:05:19.000Z | 2020-05-17T05:05:19.000Z | defmodule ExTectonicdb.Connection do
@moduledoc """
Handles connection to the database socket
`tdb-server` uses first bit in the reply to denote success/failure, so `:gen_tcp` needs to connect with `packet: :raw`.
Incoming message format: 1 byte for success failure, 8 bytes big endian (64 bit) for length n, a... | 29.274809 | 121 | 0.634941 |
1adb67669430bfdd5fce35e828bf89489013d9d1 | 994 | exs | Elixir | test/type/type_function_var/intersection_test.exs | kianmeng/mavis | 6ba154efdfadcce1aca92ac735dadb209380c25b | [
"MIT"
] | null | null | null | test/type/type_function_var/intersection_test.exs | kianmeng/mavis | 6ba154efdfadcce1aca92ac735dadb209380c25b | [
"MIT"
] | null | null | null | test/type/type_function_var/intersection_test.exs | kianmeng/mavis | 6ba154efdfadcce1aca92ac735dadb209380c25b | [
"MIT"
] | null | null | null | defmodule TypeTest.TypeFunctionVar.IntersectionTest do
use ExUnit.Case, async: true
use Type.Operators
@moduletag :intersection
import Type, only: [builtin: 1]
alias Type.Function.Var
@any builtin(:any)
@any_var %Var{name: :foo}
describe "the default variable" do
test "intersects with any and se... | 23.666667 | 58 | 0.632797 |
1adb6d75da69ef0d2e2697431c31045eb929a880 | 1,081 | ex | Elixir | lib/mix/tasks/kinesis_client/load_test_stream.ex | slievr/kcl_ex | c1620ba68b56da1802e6e9fafdb3da14155b90d7 | [
"Apache-2.0"
] | 4 | 2017-12-19T15:27:54.000Z | 2021-06-04T13:04:49.000Z | lib/mix/tasks/kinesis_client/load_test_stream.ex | slievr/kcl_ex | c1620ba68b56da1802e6e9fafdb3da14155b90d7 | [
"Apache-2.0"
] | 2 | 2021-03-05T12:01:24.000Z | 2021-12-03T22:34:24.000Z | lib/mix/tasks/kinesis_client/load_test_stream.ex | slievr/kcl_ex | c1620ba68b56da1802e6e9fafdb3da14155b90d7 | [
"Apache-2.0"
] | 3 | 2021-02-17T16:14:11.000Z | 2021-12-10T05:26:25.000Z | defmodule Mix.Tasks.KinesisClient.LoadTestStream do
@moduledoc "a task"
use Mix.Task
alias ExAws.Kinesis
@stream_name "kcl-ex-test-stream"
@impl Mix.Task
def run(_args) do
{:ok, _} = Application.ensure_all_started(:kinesis_client)
test_data = File.read!(Path.join(:code.priv_dir(:kinesis_client), "... | 30.885714 | 88 | 0.629972 |
1adb85fc0ec91e22e2bdce9770d504d494fc2e0a | 261 | ex | Elixir | lib/polimorfismo.ex | jobsonita/rocketseat-yt-cd-111-elixir-protocols | d5e683ff53fa764dd4b8adae6f75ef1abd010d97 | [
"MIT"
] | null | null | null | lib/polimorfismo.ex | jobsonita/rocketseat-yt-cd-111-elixir-protocols | d5e683ff53fa764dd4b8adae6f75ef1abd010d97 | [
"MIT"
] | null | null | null | lib/polimorfismo.ex | jobsonita/rocketseat-yt-cd-111-elixir-protocols | d5e683ff53fa764dd4b8adae6f75ef1abd010d97 | [
"MIT"
] | null | null | null | defmodule Polimorfismo do
@moduledoc """
Polimorfismo 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
| 26.1 | 66 | 0.762452 |
1adb8ad7d3910c6d532b1e5b8a89280e20f0c438 | 7,293 | ex | Elixir | apps/aecore/lib/aecore/oracle/oracle_state_tree.ex | SingularityMatrix/elixir-node | ad126aa97931165185cf35454718ed2eee40ceed | [
"ISC"
] | null | null | null | apps/aecore/lib/aecore/oracle/oracle_state_tree.ex | SingularityMatrix/elixir-node | ad126aa97931165185cf35454718ed2eee40ceed | [
"ISC"
] | 2 | 2018-10-01T16:46:26.000Z | 2018-10-01T19:45:42.000Z | apps/aecore/lib/aecore/oracle/oracle_state_tree.ex | gspasov/dogs-blockchain | 884c14cfc98de2c3793a204da069630d090bbc90 | [
"0BSD"
] | null | null | null | defmodule Aecore.Oracle.OracleStateTree do
@moduledoc """
Top level oracle state tree.
"""
alias Aecore.Chain.{Chainstate, Identifier}
alias Aecore.Oracle.{Oracle, OracleQuery}
alias Aecore.Oracle.Tx.OracleQueryTx
alias Aeutil.{PatriciaMerkleTree, Serialization}
alias MerklePatriciaTree.Trie
@typedoc... | 29.055777 | 95 | 0.698889 |
1adbae9123f68ac4c7cc4ff9187fa63be71cea9f | 1,539 | ex | Elixir | lib/ex_json_schema/validator/pattern.ex | tinfoil/ex_json_schema | 6836d531c9adcd6abfa3a5e296d3da977f7b7fb1 | [
"MIT"
] | null | null | null | lib/ex_json_schema/validator/pattern.ex | tinfoil/ex_json_schema | 6836d531c9adcd6abfa3a5e296d3da977f7b7fb1 | [
"MIT"
] | null | null | null | lib/ex_json_schema/validator/pattern.ex | tinfoil/ex_json_schema | 6836d531c9adcd6abfa3a5e296d3da977f7b7fb1 | [
"MIT"
] | null | null | null | defmodule ExJsonSchema.Validator.Pattern do
@moduledoc """
`ExJsonSchema.Validator` implementation for `"pattern"` attributes.
See:
"""
alias ExJsonSchema.Validator.Error
@behaviour ExJsonSchema.Validator
@impl ExJsonSchema.Validator
def validate(_, _, {"pattern", pattern}, data, _) do
do_valid... | 19.987013 | 94 | 0.604288 |
1adbcbcb4cb08440683442f4268e1532a943edc7 | 4,477 | exs | Elixir | test/env_test.exs | sobolevn/env | e3ff28a551f7ef5cf48040a2c0a08fe7fe8ae0f6 | [
"Apache-2.0"
] | 28 | 2016-04-10T16:00:14.000Z | 2022-01-23T21:55:04.000Z | test/env_test.exs | sobolevn/env | e3ff28a551f7ef5cf48040a2c0a08fe7fe8ae0f6 | [
"Apache-2.0"
] | 5 | 2016-04-10T19:03:44.000Z | 2019-02-16T13:25:20.000Z | test/env_test.exs | sobolevn/env | e3ff28a551f7ef5cf48040a2c0a08fe7fe8ae0f6 | [
"Apache-2.0"
] | 5 | 2016-04-10T16:59:00.000Z | 2019-03-13T09:52:08.000Z | defmodule EnvTest do
use ExUnit.Case
doctest Env
defmacrop generate_name() do
%Macro.Env{module: mod, function: {fun, arity}} = __CALLER__
String.upcase("#{mod}.#{fun}/#{arity}")
end
setup do
true = :ets.delete_all_objects(Env)
:ok
end
test "fetch/3" do
with_env(:app, %{:bar => :baz... | 28.335443 | 89 | 0.548135 |
1adbcca78ba6e1b2ef3a807d4492fa2894e5a031 | 845 | ex | Elixir | lib/elixir_jobs_web/helpers/date_helper.ex | odarriba/elixir_jobs | 514c0fd849f1579a80a98108d7ae58f76f3a330a | [
"MIT"
] | 86 | 2017-09-22T08:08:23.000Z | 2021-05-28T19:51:17.000Z | lib/elixir_jobs_web/helpers/date_helper.ex | odarriba/elixir_jobs | 514c0fd849f1579a80a98108d7ae58f76f3a330a | [
"MIT"
] | 24 | 2017-09-23T08:23:36.000Z | 2021-09-20T14:36:06.000Z | lib/elixir_jobs_web/helpers/date_helper.ex | odarriba/elixir_jobs | 514c0fd849f1579a80a98108d7ae58f76f3a330a | [
"MIT"
] | 21 | 2017-09-23T18:50:23.000Z | 2019-10-15T19:41:44.000Z | defmodule ElixirJobsWeb.DateHelper do
@moduledoc """
Module with date-related calculation and helper functions.
"""
def diff(date1, date2) do
date1 = date1 |> castin()
date2 = date2 |> castin()
case Calendar.DateTime.diff(date1, date2) do
{:ok, seconds, _, :before} -> -1 * seconds
{:ok... | 21.125 | 60 | 0.616568 |
1adbd838ad0723b6fe9210818e8b0babc80d86ad | 303 | ex | Elixir | lib/arangoex/cluster.ex | alakra/arangoex | 6fbea0335bcc1adeaa4b4299ce8028c2e4080980 | [
"MIT"
] | 24 | 2016-11-02T14:53:55.000Z | 2021-12-25T13:08:09.000Z | lib/arangoex/cluster.ex | alakra/arangoex | 6fbea0335bcc1adeaa4b4299ce8028c2e4080980 | [
"MIT"
] | 22 | 2016-12-06T15:09:50.000Z | 2022-03-24T02:16:20.000Z | lib/arangoex/cluster.ex | alakra/arangoex | 6fbea0335bcc1adeaa4b4299ce8028c2e4080980 | [
"MIT"
] | 8 | 2016-12-12T21:27:25.000Z | 2019-05-24T04:27:30.000Z | defmodule Arangoex.Cluster do
@moduledoc false
# GET /_admin/cluster-test
# POST /_admin/cluster-test
# PUT /_admin/cluster-test
# DELETE /_admin/cluster-test
# PATCH /_admin/cluster-test
# HEAD /_admin/cluster-test
# GET /_admin/clusterCheckPort
# GET /_admin/clusterStatistics
end
| 21.642857 | 33 | 0.729373 |
1adbf90fdda11aeb8d85beaa93bd43665be8d9b1 | 1,686 | ex | Elixir | clients/analytics/lib/google_api/analytics/v3/model/custom_metric_parent_link.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2021-12-20T03:40:53.000Z | 2021-12-20T03:40:53.000Z | clients/analytics/lib/google_api/analytics/v3/model/custom_metric_parent_link.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2020-08-18T00:11:23.000Z | 2020-08-18T00:44:16.000Z | clients/analytics/lib/google_api/analytics/v3/model/custom_metric_parent_link.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.72 | 128 | 0.726572 |
1adbfbbdfd47f55608ae0130fc4c7e102276da37 | 1,991 | ex | Elixir | clients/dfa_reporting/lib/google_api/dfa_reporting/v34/model/activities.ex | MasashiYokota/elixir-google-api | 975dccbff395c16afcb62e7a8e411fbb58e9ab01 | [
"Apache-2.0"
] | null | null | null | clients/dfa_reporting/lib/google_api/dfa_reporting/v34/model/activities.ex | MasashiYokota/elixir-google-api | 975dccbff395c16afcb62e7a8e411fbb58e9ab01 | [
"Apache-2.0"
] | 1 | 2020-12-18T09:25:12.000Z | 2020-12-18T09:25:12.000Z | clients/dfa_reporting/lib/google_api/dfa_reporting/v34/model/activities.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.566038 | 219 | 0.722752 |
1adbfe204cd73f618f0ec2c8f50c34d961e4c7e9 | 316 | exs | Elixir | priv/repo/migrations/20170102025804_create_profile_parameter.exs | rob05c/tox | f54847ca058ad24b909341ad65d595a4069d2471 | [
"Apache-2.0"
] | 2 | 2016-11-16T17:24:21.000Z | 2019-02-15T05:38:27.000Z | priv/repo/migrations/20170102025804_create_profile_parameter.exs | rob05c/tox | f54847ca058ad24b909341ad65d595a4069d2471 | [
"Apache-2.0"
] | null | null | null | priv/repo/migrations/20170102025804_create_profile_parameter.exs | rob05c/tox | f54847ca058ad24b909341ad65d595a4069d2471 | [
"Apache-2.0"
] | null | null | null | defmodule Tox.Repo.Migrations.CreateProfileParameter do
use Ecto.Migration
def change do
create table(:profileparameters) do
add :profile, references(:profiles, column: :name, type: :text)
add :parameter, references(:parameters, column: :name, type: :text)
timestamps()
end
end
end
| 24.307692 | 73 | 0.702532 |
1adbfe8de7eea2b65d1aca040edd2b0f233c15af | 1,790 | ex | Elixir | lib/bible_web/controllers/person_controller.ex | wbotelhos/crud-in-5-minutes-with-phoenix-and-elixir | f3218507d5c2ea7c23170d4316b41979beaa9aa6 | [
"MIT"
] | 2 | 2021-05-28T11:32:22.000Z | 2021-05-28T19:39:03.000Z | lib/bible_web/controllers/person_controller.ex | wbotelhos/crud-in-5-minutes-with-phoenix-and-elixir | f3218507d5c2ea7c23170d4316b41979beaa9aa6 | [
"MIT"
] | null | null | null | lib/bible_web/controllers/person_controller.ex | wbotelhos/crud-in-5-minutes-with-phoenix-and-elixir | f3218507d5c2ea7c23170d4316b41979beaa9aa6 | [
"MIT"
] | null | null | null | defmodule BibleWeb.PersonController do
use BibleWeb, :controller
alias Bible.Persons
alias Bible.Persons.Person
def index(conn, _params) do
persons = Persons.list_persons()
render(conn, "index.html", persons: persons)
end
def new(conn, _params) do
changeset = Persons.change_person(%Person{})
... | 28.412698 | 71 | 0.641899 |
1adc08130010465087afd1d671e94b8803f353e1 | 3,998 | ex | Elixir | lib/changelog_web/controllers/admin/person_controller.ex | boneskull/changelog.com | 2fa2e356bb0e8fcf038c46a4a947fef98822e37d | [
"MIT"
] | null | null | null | lib/changelog_web/controllers/admin/person_controller.ex | boneskull/changelog.com | 2fa2e356bb0e8fcf038c46a4a947fef98822e37d | [
"MIT"
] | null | null | null | lib/changelog_web/controllers/admin/person_controller.ex | boneskull/changelog.com | 2fa2e356bb0e8fcf038c46a4a947fef98822e37d | [
"MIT"
] | null | null | null | defmodule ChangelogWeb.Admin.PersonController do
use ChangelogWeb, :controller
alias Changelog.{Mailer, Episode, NewsItem, Person, Slack}
alias ChangelogWeb.Email
plug :assign_person when action in [:edit, :update, :delete, :slack]
plug Authorize, [Policies.Person, :person]
plug :scrub_params, "person" wh... | 29.397059 | 92 | 0.649825 |
1adc0c7868360c3ed946ab350ba07f6a921421ec | 221 | exs | Elixir | backend/.formatter.exs | danesjenovdan/kjer.si | 185410ede2d42892e4d91c000099283254c5dc7a | [
"Unlicense"
] | 2 | 2019-11-02T21:28:34.000Z | 2019-11-28T18:01:08.000Z | backend/.formatter.exs | danesjenovdan/kjer.si | 185410ede2d42892e4d91c000099283254c5dc7a | [
"Unlicense"
] | 17 | 2019-11-29T16:23:38.000Z | 2022-02-14T05:11:41.000Z | backend/.formatter.exs | danesjenovdan/kjer.si | 185410ede2d42892e4d91c000099283254c5dc7a | [
"Unlicense"
] | null | null | null | [
locals_without_parens: [
# Params
defparams: 1
],
import_deps: [:ecto, :phoenix],
inputs: ["*.{ex,exs}", "priv/*/seeds.exs", "{config,lib,test}/**/*.{ex,exs}"],
subdirectories: ["priv/*/migrations"]
]
| 22.1 | 80 | 0.579186 |
1adc45ffcb50f44f8e6ea5a08044744c3ca43eed | 3,873 | ex | Elixir | day6/lib/day6/part2.ex | ryanbillingsley/advent_of_code | 9219a4b763966b70caed85865bb073a26bb3a705 | [
"MIT"
] | null | null | null | day6/lib/day6/part2.ex | ryanbillingsley/advent_of_code | 9219a4b763966b70caed85865bb073a26bb3a705 | [
"MIT"
] | null | null | null | day6/lib/day6/part2.ex | ryanbillingsley/advent_of_code | 9219a4b763966b70caed85865bb073a26bb3a705 | [
"MIT"
] | null | null | null | defmodule Day6.Part2 do
alias Day6.Brightness
# Only need to report lit lights, but must toggle lights, which could still mean
# only keeping a set of lights that are on. This could also be a good use case
# for an Agent
# Keep a set of on and off lights. Set can do fast finding for a member.
def start(... | 27.664286 | 82 | 0.661761 |
1adc4a18cac904670c92a30d5ae2f5734e6e3220 | 35 | ex | Elixir | 31_karvonen_heart_rate/lib/karvonen_heart_rate.ex | mkchandler/elixir-school | cc08bd723db00cc35cd2d6b07abe519e5d102ca0 | [
"MIT"
] | 1 | 2015-12-15T04:46:41.000Z | 2015-12-15T04:46:41.000Z | 31_karvonen_heart_rate/lib/karvonen_heart_rate.ex | mkchandler/elixir-school | cc08bd723db00cc35cd2d6b07abe519e5d102ca0 | [
"MIT"
] | null | null | null | 31_karvonen_heart_rate/lib/karvonen_heart_rate.ex | mkchandler/elixir-school | cc08bd723db00cc35cd2d6b07abe519e5d102ca0 | [
"MIT"
] | null | null | null | defmodule KarvonenHeartRate do
end
| 11.666667 | 30 | 0.885714 |
1adc507a30b030ac4de2a828c5f7e857136c6407 | 3,099 | ex | Elixir | lib/shamir/shamir.ex | lauragrechenko/keyx | 9b6905a5b8cfefe6faf5abdfd1620e5faf1a0135 | [
"Apache-2.0"
] | null | null | null | lib/shamir/shamir.ex | lauragrechenko/keyx | 9b6905a5b8cfefe6faf5abdfd1620e5faf1a0135 | [
"Apache-2.0"
] | null | null | null | lib/shamir/shamir.ex | lauragrechenko/keyx | 9b6905a5b8cfefe6faf5abdfd1620e5faf1a0135 | [
"Apache-2.0"
] | null | null | null | defmodule KeyX.Shamir do
alias KeyX.Shamir.Arithmetic
require Logger
@spec split_secret(non_neg_integer, non_neg_integer, binary) :: list(binary)
def split_secret(_k, n, _secret) when n > 255, do: raise "too many parts, n <= 255"
def split_secret(k, n, _secret) when k > n, do: raise "k cannot be less than t... | 37.792683 | 120 | 0.65989 |
1adc51f819496ed39ff2da33c57dc0dfafc4b856 | 105 | ex | Elixir | core/src/main/java/site/ycsb/data_gen/Graph_gen/Graph_gen/examples/graphhash/Makefile.ex | qiuhere/Bench | 80f15facb81120b754547586cf3a7e5f46ca1551 | [
"Apache-2.0"
] | 1,805 | 2015-01-06T20:01:35.000Z | 2022-03-29T16:12:51.000Z | examples/graphhash/Makefile.ex | lizhaoqing/snap | 907c34aac6bcddc7c2f8efb64be76e87dd7e4ea5 | [
"BSD-3-Clause"
] | 168 | 2015-01-07T22:57:29.000Z | 2022-03-15T01:20:24.000Z | examples/graphhash/Makefile.ex | lizhaoqing/snap | 907c34aac6bcddc7c2f8efb64be76e87dd7e4ea5 | [
"BSD-3-Clause"
] | 768 | 2015-01-09T02:28:45.000Z | 2022-03-30T00:53:46.000Z | #
# configuration variables for the example
## Main application file
MAIN = graphhash
DEPH =
DEPCPP =
| 11.666667 | 41 | 0.733333 |
1adc5b68b86c407550046402adcf50b5c85f72d1 | 13,647 | ex | Elixir | lib/ex_aws/sqs.ex | bettyblocks/ex_aws | 0c9b43b5a1afbfb5fb26131be7f80f69de4431d1 | [
"MIT",
"Unlicense"
] | null | null | null | lib/ex_aws/sqs.ex | bettyblocks/ex_aws | 0c9b43b5a1afbfb5fb26131be7f80f69de4431d1 | [
"MIT",
"Unlicense"
] | null | null | null | lib/ex_aws/sqs.ex | bettyblocks/ex_aws | 0c9b43b5a1afbfb5fb26131be7f80f69de4431d1 | [
"MIT",
"Unlicense"
] | 1 | 2021-01-22T12:16:23.000Z | 2021-01-22T12:16:23.000Z | defmodule ExAws.SQS do
@moduledoc """
Operations on AWS SQS
"""
@type sqs_permission ::
:send_message |
:receive_message |
:delete_message |
:change_message_visibility |
:get_queue_attributes
@type sqs_acl :: %{ binary => :all | [sqs_permission, ...]}
@type sqs_message_attribute_name ::... | 31.4447 | 149 | 0.677072 |
1adc6191e07c12df672f831162275a9716189c9c | 68 | exs | Elixir | dingen/test/test_helper.exs | rmoorman/dingen-2018011-tenants | 02f3fa618b9a266340d4a4993420dc5641cec08e | [
"MIT"
] | null | null | null | dingen/test/test_helper.exs | rmoorman/dingen-2018011-tenants | 02f3fa618b9a266340d4a4993420dc5641cec08e | [
"MIT"
] | null | null | null | dingen/test/test_helper.exs | rmoorman/dingen-2018011-tenants | 02f3fa618b9a266340d4a4993420dc5641cec08e | [
"MIT"
] | null | null | null | ExUnit.start()
Ecto.Adapters.SQL.Sandbox.mode(Dingen.Repo, :manual)
| 22.666667 | 52 | 0.779412 |
1adc750a7f44386dcbf25aa290d4b1e34fccaad6 | 563 | exs | Elixir | test/views/error_view_test.exs | anamba/webrtc_example | b539101d29ffeb52f551f263128a0884a5d6a7ae | [
"MIT"
] | 44 | 2016-01-16T07:28:43.000Z | 2021-05-05T04:45:19.000Z | test/views/error_view_test.exs | anamba/webrtc_example | b539101d29ffeb52f551f263128a0884a5d6a7ae | [
"MIT"
] | null | null | null | test/views/error_view_test.exs | anamba/webrtc_example | b539101d29ffeb52f551f263128a0884a5d6a7ae | [
"MIT"
] | 6 | 2016-11-11T20:40:34.000Z | 2021-05-05T04:45:24.000Z | defmodule Webrtc.ErrorViewTest do
use Webrtc.ConnCase, async: true
# Bring render/3 and render_to_string/3 for testing custom views
import Phoenix.View
test "renders 404.html" do
assert render_to_string(Webrtc.ErrorView, "404.html", []) ==
"Page not found"
end
test "render 500.html" do
... | 25.590909 | 66 | 0.673179 |
1adc99ceb4d8ec824c6b092c405f88287df6982c | 1,239 | ex | Elixir | lib/plausible/tracking.ex | dukhniav/plausible | dfcbf9cc98637721698b2046eee205b66b204acb | [
"MIT"
] | null | null | null | lib/plausible/tracking.ex | dukhniav/plausible | dfcbf9cc98637721698b2046eee205b66b204acb | [
"MIT"
] | null | null | null | lib/plausible/tracking.ex | dukhniav/plausible | dfcbf9cc98637721698b2046eee205b66b204acb | [
"MIT"
] | null | null | null | defmodule Plausible.Tracking do
@api_host "https://api.amplitude.com"
def event(conn, event, properties \\ %{}) do
Task.start(fn ->
track(Mix.env(), %{
event_type: event,
user_id: extract_user_id(conn),
device_id: extract_device_id(conn),
event_properties: properties,
... | 23.826923 | 107 | 0.623083 |
1adcab584fb62f042505f79d3d5b46a3cbd01e7e | 9,368 | exs | Elixir | test/controllers/book_controller_test.exs | cedretaber/bibliotheca | 642ec9908d6d98f16e25b6a482c52e9cbaa21ad2 | [
"MIT"
] | null | null | null | test/controllers/book_controller_test.exs | cedretaber/bibliotheca | 642ec9908d6d98f16e25b6a482c52e9cbaa21ad2 | [
"MIT"
] | 22 | 2017-05-15T07:34:08.000Z | 2018-02-25T07:26:18.000Z | test/controllers/book_controller_test.exs | cedretaber/bibliotheca | 642ec9908d6d98f16e25b6a482c52e9cbaa21ad2 | [
"MIT"
] | null | null | null | defmodule Bibliotheca.BookControllerTest do
use Bibliotheca.ConnCase, async: true
alias Bibliotheca.{Repo, Account, Book, BookLent, User}
alias Bibliotheca.Api.BookView
@user2 %User{
id: 2,
email: "user2@example.com",
password_digest: "password",
auth_code: "NORMAL"
}
@account1 %Account{i... | 32.755245 | 98 | 0.526793 |
1adcb171e968a1d589181f8a08734822507c431d | 446 | exs | Elixir | test/ua_inspector/short_code_map/device_brands_test.exs | elixir-twister/ua_inspector | 70642c66c9562d6879fd462e2f9993edb8ab4ce1 | [
"Apache-2.0"
] | null | null | null | test/ua_inspector/short_code_map/device_brands_test.exs | elixir-twister/ua_inspector | 70642c66c9562d6879fd462e2f9993edb8ab4ce1 | [
"Apache-2.0"
] | null | null | null | test/ua_inspector/short_code_map/device_brands_test.exs | elixir-twister/ua_inspector | 70642c66c9562d6879fd462e2f9993edb8ab4ce1 | [
"Apache-2.0"
] | 1 | 2020-01-30T18:55:12.000Z | 2020-01-30T18:55:12.000Z | defmodule UAInspector.ShortCodeMap.DeviceBrandsTest do
use ExUnit.Case, async: true
alias UAInspector.ShortCodeMap.DeviceBrands
test "device brand" do
assert "Google" == DeviceBrands.to_long("GO")
assert "GO" == DeviceBrands.to_short("Google")
end
test "device brand not convertible" do
bran... | 24.777778 | 54 | 0.715247 |
1adce230bd8e4aefe2e11d9b955a88304415e932 | 1,607 | ex | Elixir | day12/lib/day12.ex | bjorng/advent-of-code-2021 | 82c22dfa0ba7e9134e39b9dbc95227bb99f62c8d | [
"Apache-2.0"
] | 10 | 2021-12-01T08:49:00.000Z | 2022-03-24T13:24:50.000Z | day12/lib/day12.ex | bjorng/advent-of-code-2021 | 82c22dfa0ba7e9134e39b9dbc95227bb99f62c8d | [
"Apache-2.0"
] | null | null | null | day12/lib/day12.ex | bjorng/advent-of-code-2021 | 82c22dfa0ba7e9134e39b9dbc95227bb99f62c8d | [
"Apache-2.0"
] | 1 | 2021-12-16T07:09:11.000Z | 2021-12-16T07:09:11.000Z | defmodule Day12 do
def part1(input) do
solve(input, 1)
end
def part2(input) do
solve(input, 2)
end
defp solve(input, max_visits) do
pairs = parse(input)
map = Enum.reduce(pairs, pairs, fn {from, to}, acc ->
[{to, from} | acc]
end)
|> Enum.group_by(fn {from, _} -> from end)
... | 24.723077 | 58 | 0.507778 |
1adce793acd2a67591a65208435012202891a328 | 7,020 | ex | Elixir | lib/geotiff.ex | Kalimaha/rosetta | 915beb973582a95429aa20ddaeceb3c2ed559c86 | [
"MIT"
] | 1 | 2018-01-22T18:53:45.000Z | 2018-01-22T18:53:45.000Z | lib/geotiff.ex | Kalimaha/rosetta | 915beb973582a95429aa20ddaeceb3c2ed559c86 | [
"MIT"
] | null | null | null | lib/geotiff.ex | Kalimaha/rosetta | 915beb973582a95429aa20ddaeceb3c2ed559c86 | [
"MIT"
] | null | null | null | defmodule GeoTIFF do
@doc ~S"""
Reads the headers of a GeoTIFF file.
### Examples:
iex> filename = "./test/resources/example_ii.tif"
iex> {:ok, response} = GeoTIFF.read_headers(filename)
iex> response.first_ifd_offset
270_276
iex> ifd = Enum.at response.ifds, 0
iex> Enum.at ifd.tags, 2
... | 29.372385 | 127 | 0.602849 |
1adcf05d867875f8e149f3a229c759a2abc71416 | 2,467 | ex | Elixir | apps/omg_watcher/lib/api/status.ex | hoardexchange/elixir-omg | 423528699d467f1cc0d02c596290ab907af38c2c | [
"Apache-2.0"
] | null | null | null | apps/omg_watcher/lib/api/status.ex | hoardexchange/elixir-omg | 423528699d467f1cc0d02c596290ab907af38c2c | [
"Apache-2.0"
] | null | null | null | apps/omg_watcher/lib/api/status.ex | hoardexchange/elixir-omg | 423528699d467f1cc0d02c596290ab907af38c2c | [
"Apache-2.0"
] | 2 | 2020-06-07T11:14:54.000Z | 2020-08-02T07:36:32.000Z | # Copyright 2018 OmiseGO Pte Ltd
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writi... | 37.378788 | 110 | 0.708958 |
1add06ac4e42e7fd85f3a5a18ceeb4e9acac1b3c | 79 | ex | Elixir | testData/org/elixir_lang/parser_definition/binary_whole_number_parsing_test_case/NoDigits.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/binary_whole_number_parsing_test_case/NoDigits.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/binary_whole_number_parsing_test_case/NoDigits.ex | keyno63/intellij-elixir | 4033e319992c53ddd42a683ee7123a97b5e34f02 | [
"Apache-2.0"
] | 145 | 2015-01-15T11:37:16.000Z | 2021-12-22T05:51:02.000Z | # No digits should recover at EOL
0b
# No digits should recover at ;
0b; 0b01
| 13.166667 | 33 | 0.721519 |
1add1df387f330ed8dd8abc17d3d839e97ce56db | 93 | ex | Elixir | apps/ut_monitor_bench/lib/nerves/network_interface.ex | usertesting/nerves_status_monitors | 18ccc7a3f3787d847a09328cea6c49b51605338a | [
"MIT"
] | 1 | 2017-02-10T17:41:02.000Z | 2017-02-10T17:41:02.000Z | apps/ut_monitor_bench/lib/nerves/network_interface.ex | usertesting/nerves_status_monitors | 18ccc7a3f3787d847a09328cea6c49b51605338a | [
"MIT"
] | null | null | null | apps/ut_monitor_bench/lib/nerves/network_interface.ex | usertesting/nerves_status_monitors | 18ccc7a3f3787d847a09328cea6c49b51605338a | [
"MIT"
] | null | null | null | defmodule Nerves.NetworkInterface do
def status(_) do
{:ok, %{is_up: true}}
end
end
| 13.285714 | 36 | 0.666667 |
1add2c5d209364614097ea35605a23a046b0f7c2 | 1,142 | exs | Elixir | config/config.exs | bdfinlayson/drab | ce11a643ec8fe7e7f622489af5792ef12e69a8c7 | [
"MIT"
] | null | null | null | config/config.exs | bdfinlayson/drab | ce11a643ec8fe7e7f622489af5792ef12e69a8c7 | [
"MIT"
] | null | null | null | config/config.exs | bdfinlayson/drab | ce11a643ec8fe7e7f622489af5792ef12e69a8c7 | [
"MIT"
] | null | null | null | # This file is responsible for configuring your application
# and its dependencies with the aid of the Mix.Config module.
#
# This configuration file is loaded before any dependency and
# is restricted to this project.
use Mix.Config
# Configures the endpoint
config :drab, DrabTestApp.Endpoint,
url: [host: "localhos... | 34.606061 | 86 | 0.765324 |
1add322403484f59d396091f4211a2a6a4b71a54 | 801 | ex | Elixir | samples/client/petstore/elixir/lib/open_api_petstore/model/capitalization.ex | kymbalon/openapi-generator | 8327a920408314aacb7d00f64285ae88e9195633 | [
"Apache-2.0"
] | 2 | 2019-03-26T11:04:18.000Z | 2021-01-03T10:54:10.000Z | samples/client/petstore/elixir/lib/open_api_petstore/model/capitalization.ex | kymbalon/openapi-generator | 8327a920408314aacb7d00f64285ae88e9195633 | [
"Apache-2.0"
] | 7 | 2021-03-01T21:26:03.000Z | 2022-02-27T10:10:20.000Z | samples/client/petstore/elixir/lib/open_api_petstore/model/capitalization.ex | kymbalon/openapi-generator | 8327a920408314aacb7d00f64285ae88e9195633 | [
"Apache-2.0"
] | 4 | 2019-04-08T17:06:09.000Z | 2020-06-09T18:16:08.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.Capitalization do
@moduledoc """
"""
@derive [Poison.Encoder]
defstruct [
:"smallCamel",
:"CapitalCamel",
... | 22.25 | 91 | 0.650437 |
1add36e0ac6af31cc997ec72935ca95f5653c696 | 1,019 | ex | Elixir | lib/bits.ex | piersadrian/cryptex | b654602f4515eef70ed70eb6f23f1303f8ab33a2 | [
"MIT"
] | null | null | null | lib/bits.ex | piersadrian/cryptex | b654602f4515eef70ed70eb6f23f1303f8ab33a2 | [
"MIT"
] | null | null | null | lib/bits.ex | piersadrian/cryptex | b654602f4515eef70ed70eb6f23f1303f8ab33a2 | [
"MIT"
] | null | null | null | defmodule Bits do
require Bitwise
@doc """
Performs a bitwise XOR of the given hex strings and returns the resulting hex string. The given
hex strings must have the same length or an error will be raised.
iex> Bits.xor("1c0111001f010100061a024b53535009181c", "686974207468652062756c6c277320657965")
... | 32.870968 | 99 | 0.677134 |
1add5ee50c19f98fe3a7238faa2a17660499d817 | 1,119 | exs | Elixir | mix.exs | mwmiller/lipmaa | 1b984d47077c384523d80747445b4f0aac1ef09a | [
"MIT"
] | null | null | null | mix.exs | mwmiller/lipmaa | 1b984d47077c384523d80747445b4f0aac1ef09a | [
"MIT"
] | null | null | null | mix.exs | mwmiller/lipmaa | 1b984d47077c384523d80747445b4f0aac1ef09a | [
"MIT"
] | null | null | null | defmodule Lipmaa.MixProject do
use Mix.Project
def project do
[
app: :lipmaa,
version: "0.2.0",
elixir: "~> 1.13",
start_permanent: Mix.env() == :prod,
name: "Lipmaa",
source_url: "https://github.com/mwmiller/lipmaa",
build_embedded: Mix.env() == :prod,
start_per... | 21.941176 | 98 | 0.560322 |
1add73072619e1e66fb1a4ec9c109673410ed0f2 | 850 | exs | Elixir | test/plausible_web/controllers/api/stats_controller/current_visitors_test.exs | pmhoudry/plausible | 454feec36e62b866ae86e07a1f4133d9782d4365 | [
"MIT"
] | 1 | 2020-04-08T16:39:00.000Z | 2020-04-08T16:39:00.000Z | test/plausible_web/controllers/api/stats_controller/current_visitors_test.exs | pmhoudry/plausible | 454feec36e62b866ae86e07a1f4133d9782d4365 | [
"MIT"
] | null | null | null | test/plausible_web/controllers/api/stats_controller/current_visitors_test.exs | pmhoudry/plausible | 454feec36e62b866ae86e07a1f4133d9782d4365 | [
"MIT"
] | null | null | null | defmodule PlausibleWeb.Api.StatsController.CurrentVisitorsTest do
use PlausibleWeb.ConnCase
import Plausible.TestUtils
describe "GET /api/stats/:domain/current-visitors" do
setup [:create_user, :log_in, :create_site]
test "returns unique users in the last 5 minutes", %{conn: conn, site: site} do
i... | 42.5 | 129 | 0.704706 |
1add731dd52d85618c940a0aa51365d7e0954359 | 4,465 | exs | Elixir | test/iso_8583/bitmap/bitmap_test.exs | zemuldo/iso_8583_elixir | bc8782a20cd9bc5fa78c9c57338a68f459f9929c | [
"MIT"
] | 7 | 2020-03-02T07:12:49.000Z | 2022-03-15T02:03:30.000Z | test/iso_8583/bitmap/bitmap_test.exs | zemuldo/iso_8583_elixir | bc8782a20cd9bc5fa78c9c57338a68f459f9929c | [
"MIT"
] | 1 | 2020-10-21T05:19:44.000Z | 2020-10-24T20:11:47.000Z | test/iso_8583/bitmap/bitmap_test.exs | zemuldo/iso_8583_elixir | bc8782a20cd9bc5fa78c9c57338a68f459f9929c | [
"MIT"
] | 2 | 2020-03-02T07:14:50.000Z | 2022-03-15T17:18:57.000Z | defmodule BitmapTest do
use ExUnit.Case
alias ISO8583.Bitmap
doctest Bitmap
use ISO8583.Test.Setup
import ISO8583.Test.Fixtures
test "should encode bitmap case 0" do
assert Bitmap.fields_0_127(fixture_message(:"0100")) == "F21C46C1A0E091000000000000000022"
end
test "should create the right bitma... | 32.830882 | 223 | 0.630907 |
1addcd850ca136dfc006035203565dfda5905ee4 | 1,058 | exs | Elixir | test/test_helper.exs | dweremeichik/pow | 8c45624c1bf40487680abf5a077549fad2de2141 | [
"MIT"
] | null | null | null | test/test_helper.exs | dweremeichik/pow | 8c45624c1bf40487680abf5a077549fad2de2141 | [
"MIT"
] | null | null | null | test/test_helper.exs | dweremeichik/pow | 8c45624c1bf40487680abf5a077549fad2de2141 | [
"MIT"
] | 1 | 2020-07-13T01:11:17.000Z | 2020-07-13T01:11:17.000Z | Logger.configure(level: :warn)
ExUnit.start()
# Ensure that symlink to custom ecto priv directory exists
source = Pow.Test.Ecto.Repo.config()[:priv]
target = Application.app_dir(:pow, source)
File.rm_rf(target)
File.mkdir_p(target)
File.rmdir(target)
:ok = :file.make_symlink(Path.expand(source), target)
Mix.Task.run... | 34.129032 | 80 | 0.73913 |
1adde317a62caa58d0f49566803219d70979197b | 718 | ex | Elixir | web/gettext.ex | jchartsell/caesar_cipher | bc23b2d8f55a6e25ecefe6539af7e476f69410fb | [
"MIT"
] | null | null | null | web/gettext.ex | jchartsell/caesar_cipher | bc23b2d8f55a6e25ecefe6539af7e476f69410fb | [
"MIT"
] | null | null | null | web/gettext.ex | jchartsell/caesar_cipher | bc23b2d8f55a6e25ecefe6539af7e476f69410fb | [
"MIT"
] | null | null | null | defmodule CaesarCipher.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 CaesarCipher.Gettext
# Simple translation
gettext "Here ... | 28.72 | 72 | 0.685237 |
1adde4f8b3dd22e12f3c4e1cbc0d622791f31abf | 8,095 | ex | Elixir | clients/redis/lib/google_api/redis/v1/model/instance.ex | jechol/elixir-google-api | 0290b683dfc6491ca2ef755a80bc329378738d03 | [
"Apache-2.0"
] | null | null | null | clients/redis/lib/google_api/redis/v1/model/instance.ex | jechol/elixir-google-api | 0290b683dfc6491ca2ef755a80bc329378738d03 | [
"Apache-2.0"
] | null | null | null | clients/redis/lib/google_api/redis/v1/model/instance.ex | jechol/elixir-google-api | 0290b683dfc6491ca2ef755a80bc329378738d03 | [
"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... | 73.590909 | 542 | 0.706115 |
1adde55b576efe0db32b70b0942982261922a622 | 4,940 | ex | Elixir | lib/koans/18_genservers.ex | krlsdu/elixir_learning | 05e2be664044689f8b4dfb2081a78009294810ec | [
"MIT"
] | null | null | null | lib/koans/18_genservers.ex | krlsdu/elixir_learning | 05e2be664044689f8b4dfb2081a78009294810ec | [
"MIT"
] | null | null | null | lib/koans/18_genservers.ex | krlsdu/elixir_learning | 05e2be664044689f8b4dfb2081a78009294810ec | [
"MIT"
] | null | null | null | defmodule GenServers do
use Koans
@intro "GenServers"
defmodule Laptop do
use GenServer
#####
# External API
def start_link(init_password) do
# The __MODULE__ macro returns the current module name as an atom
GenServer.start_link(__MODULE__, init_password, name: __MODULE__)
end
... | 31.666667 | 114 | 0.678543 |
1ade144ea2b03558b94787a0200bec8e3bfafd5e | 2,919 | ex | Elixir | web/controllers/post_controller.ex | Ellocsys/kedo | 81626082952bfc63c382d015cffaa1ebd80e1f67 | [
"MIT"
] | null | null | null | web/controllers/post_controller.ex | Ellocsys/kedo | 81626082952bfc63c382d015cffaa1ebd80e1f67 | [
"MIT"
] | null | null | null | web/controllers/post_controller.ex | Ellocsys/kedo | 81626082952bfc63c382d015cffaa1ebd80e1f67 | [
"MIT"
] | null | null | null | defmodule Pxblog.PostController do
use Pxblog.Web, :controller
plug :assign_user
plug :authorize_user when action in [:new, :create, :update, :edit, :delete]
alias Pxblog.Post
defp assign_user(conn, _opts) do
case conn.params do
%{"user_id" => user_id} ->
case Repo.get(Pxblog.User, user_i... | 28.339806 | 78 | 0.610826 |
1ade80ca874fd4e003c83852384c22bf3dee6504 | 1,534 | ex | Elixir | clients/vm_migration/lib/google_api/vm_migration/v1/model/replication_sync.ex | renovate-bot/elixir-google-api | 1da34cd39b670c99f067011e05ab90af93fef1f6 | [
"Apache-2.0"
] | 1 | 2021-12-20T03:40:53.000Z | 2021-12-20T03:40:53.000Z | clients/vm_migration/lib/google_api/vm_migration/v1/model/replication_sync.ex | swansoffiee/elixir-google-api | 9ea6d39f273fb430634788c258b3189d3613dde0 | [
"Apache-2.0"
] | 1 | 2020-08-18T00:11:23.000Z | 2020-08-18T00:44:16.000Z | clients/vm_migration/lib/google_api/vm_migration/v1/model/replication_sync.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... | 32.638298 | 143 | 0.746415 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.