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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
1d4b5cd4d1f1b05961f143e22d7dff24a6b3479d | 1,879 | exs | Elixir | test/support/http_client.exs | misfo/phoenix | 04464429d9b958e331b2ffe0f0f5926690ab3b56 | [
"MIT"
] | 1 | 2021-03-14T17:50:24.000Z | 2021-03-14T17:50:24.000Z | test/support/http_client.exs | misfo/phoenix | 04464429d9b958e331b2ffe0f0f5926690ab3b56 | [
"MIT"
] | null | null | null | test/support/http_client.exs | misfo/phoenix | 04464429d9b958e331b2ffe0f0f5926690ab3b56 | [
"MIT"
] | 2 | 2020-08-02T04:00:17.000Z | 2020-10-07T16:07:37.000Z | defmodule Phoenix.Integration.HTTPClient do
@doc """
Performs HTTP Request and returns Response
* method - The http method, for example :get, :post, :put, etc
* url - The string url, for example "http://example.com"
* headers - The map of headers
* body - The optional string body. If the body is a ... | 34.163636 | 101 | 0.625865 |
1d4b69cfbc225e8e8435e524c002bf5069eb1730 | 25 | ex | Elixir | testData/org/elixir_lang/parser_definition/matched_pipe_operation_parsing_test_case/MatchedTwoOperation.ex | keyno63/intellij-elixir | 4033e319992c53ddd42a683ee7123a97b5e34f02 | [
"Apache-2.0"
] | 1,668 | 2015-01-03T05:54:27.000Z | 2022-03-25T08:01:20.000Z | testData/org/elixir_lang/parser_definition/matched_pipe_operation_parsing_test_case/MatchedTwoOperation.ex | keyno63/intellij-elixir | 4033e319992c53ddd42a683ee7123a97b5e34f02 | [
"Apache-2.0"
] | 2,018 | 2015-01-01T22:43:39.000Z | 2022-03-31T20:13:08.000Z | testData/org/elixir_lang/parser_definition/matched_pipe_operation_parsing_test_case/MatchedTwoOperation.ex | keyno63/intellij-elixir | 4033e319992c53ddd42a683ee7123a97b5e34f02 | [
"Apache-2.0"
] | 145 | 2015-01-15T11:37:16.000Z | 2021-12-22T05:51:02.000Z | one ++ two | three..four
| 12.5 | 24 | 0.6 |
1d4b7523a3f5a20912f2f83ec7d35affdbe0fffd | 1,565 | ex | Elixir | lib/SQL.ex | luisguilhermemsalmeida/ecto_raw_sql_helpers | 210466634e07fe166cf6b941108c1e8b67939d44 | [
"MIT"
] | 1 | 2021-11-25T21:03:28.000Z | 2021-11-25T21:03:28.000Z | lib/SQL.ex | luisguilhermemsalmeida/ecto_raw_sql_helpers | 210466634e07fe166cf6b941108c1e8b67939d44 | [
"MIT"
] | null | null | null | lib/SQL.ex | luisguilhermemsalmeida/ecto_raw_sql_helpers | 210466634e07fe166cf6b941108c1e8b67939d44 | [
"MIT"
] | null | null | null | defmodule EctoRawSQLHelpers.SQL do
import PipeOperators.SkipOnErrorPipe
alias EctoRawSQLHelpers.DatabaseResponseParser
alias EctoRawSQLHelpers.AdapterSQLExecutor
def query(repo_or_pid, sql, params \\ [], options \\ []) do
AdapterSQLExecutor.adapter_query(repo_or_pid, sql, params, options)
~> DatabaseR... | 37.261905 | 144 | 0.709265 |
1d4b89544fab209c328e232c997681abc27c06c6 | 11,054 | exs | Elixir | test/pay_pal_billing_agreements_test.exs | steady-media/PayPal | 7bbd04950671d5de8926a432538be1377114eb3b | [
"MIT"
] | 33 | 2017-05-09T05:25:06.000Z | 2022-01-13T14:53:07.000Z | test/pay_pal_billing_agreements_test.exs | steady-media/PayPal | 7bbd04950671d5de8926a432538be1377114eb3b | [
"MIT"
] | 7 | 2017-10-13T01:28:10.000Z | 2021-01-25T23:31:14.000Z | test/pay_pal_billing_agreements_test.exs | steady-media/PayPal | 7bbd04950671d5de8926a432538be1377114eb3b | [
"MIT"
] | 24 | 2017-05-09T05:25:08.000Z | 2021-09-04T16:30:21.000Z | defmodule PayPalBillingAgreementsTest do
use ExUnit.Case
use ExVCR.Mock, adapter: ExVCR.Adapter.Hackney
setup_all do
ExVCR.Config.cassette_library_dir("fixture/vcr_cassettes", "fixture/custom_cassettes")
ExVCR.Config.filter_url_params(true)
ExVCR.Config.response_headers_blacklist(["paypal-debug-id", ... | 64.267442 | 2,182 | 0.659852 |
1d4b9160f28b3a057cf1645ffd46771c07b3c9b1 | 1,087 | exs | Elixir | mix.exs | zipme/ueberauth_apple | b9bf009591d2f1df787c99a642d486dc50b01037 | [
"MIT"
] | 1 | 2019-12-15T17:37:48.000Z | 2019-12-15T17:37:48.000Z | mix.exs | zipme/ueberauth_apple | b9bf009591d2f1df787c99a642d486dc50b01037 | [
"MIT"
] | null | null | null | mix.exs | zipme/ueberauth_apple | b9bf009591d2f1df787c99a642d486dc50b01037 | [
"MIT"
] | 2 | 2019-12-15T17:32:38.000Z | 2020-07-24T20:03:30.000Z | defmodule UeberauthApple.Mixfile do
use Mix.Project
@version "0.1.0"
@url "https://github.com/loopsocial/ueberauth_apple"
def project do
[
app: :ueberauth_apple,
version: @version,
name: "Ueberauth Apple Strategy",
package: package(),
elixir: "~> 1.6",
build_embedded: M... | 20.12963 | 57 | 0.557498 |
1d4b9b1de776cc9ac84356b67aca27eca3c08644 | 5,362 | ex | Elixir | deps/db_connection/lib/db_connection/ownership.ex | rpillar/Top5_Elixir | 9c450d2e9b291108ff1465dc066dfe442dbca822 | [
"MIT"
] | null | null | null | deps/db_connection/lib/db_connection/ownership.ex | rpillar/Top5_Elixir | 9c450d2e9b291108ff1465dc066dfe442dbca822 | [
"MIT"
] | null | null | null | deps/db_connection/lib/db_connection/ownership.ex | rpillar/Top5_Elixir | 9c450d2e9b291108ff1465dc066dfe442dbca822 | [
"MIT"
] | null | null | null | defmodule DBConnection.OwnershipError do
defexception [:message]
def exception(message), do: %DBConnection.OwnershipError{message: message}
end
defmodule DBConnection.Ownership do
@moduledoc """
A DBConnection pool that requires explicit checkout and checkin
as a mechanism to coordinate between pro... | 42.896 | 95 | 0.694517 |
1d4ba7cd94e2d5eba9b3079066abf86d7dc6fbeb | 214 | exs | Elixir | test/pdf_calendar/pcal_test.exs | ramortegui/pdf_calendar | 38f367aa505c7f7374cedc34c51e6640f6f983ee | [
"MIT"
] | null | null | null | test/pdf_calendar/pcal_test.exs | ramortegui/pdf_calendar | 38f367aa505c7f7374cedc34c51e6640f6f983ee | [
"MIT"
] | 2 | 2021-03-08T23:54:52.000Z | 2021-05-08T00:14:57.000Z | test/pdf_calendar/pcal_test.exs | ramortegui/pdf_calendar | 38f367aa505c7f7374cedc34c51e6640f6f983ee | [
"MIT"
] | null | null | null | defmodule PdfCalendar.PcalTest do
use ExUnit.Case
test 'with valida data' do
changeset = PdfCalendar.Pcal.changeset(%PdfCalendar.Pcal{}, %{year: "2019", month: "1"})
assert(changeset.valid?)
end
end
| 23.777778 | 92 | 0.705607 |
1d4bd0146dd135bc48042d525338d9445d68fbd5 | 5,402 | ex | Elixir | lib/ecto_sharding/repo.ex | craig-day/ecto_sharding | 9a754bf2c0a6ba1ce480ee93685add5472308c2c | [
"Apache-2.0"
] | 9 | 2017-09-27T02:47:23.000Z | 2021-03-17T00:01:29.000Z | lib/ecto_sharding/repo.ex | craig-day/ecto_sharding | 9a754bf2c0a6ba1ce480ee93685add5472308c2c | [
"Apache-2.0"
] | 3 | 2018-02-24T19:25:41.000Z | 2018-09-17T18:39:20.000Z | lib/ecto_sharding/repo.ex | craig-day/ecto_sharding | 9a754bf2c0a6ba1ce480ee93685add5472308c2c | [
"Apache-2.0"
] | 2 | 2017-09-26T19:24:10.000Z | 2018-03-07T00:50:10.000Z | defmodule EctoSharding.Repo do
@moduledoc """
An `Ecto.Repo` wrapper. This should be used in place of `use Ecto.Repo`.
This implements the same interface as `Ecto.Repo` and should be used in the
same way.
## Example
```
defmodule MyApp.Repo do
use EctoSharding.Repo, otp_app: :my_app
end
defmod... | 31.406977 | 98 | 0.609034 |
1d4bfa2cb158dcd450e888470723cf37ab3fb6fd | 1,328 | ex | Elixir | lib/macchinista_web/resolvers/quest.ex | themaxhero/Machinista | 2e0114dbbc69fc8187b3ed080de694ac4f558ae8 | [
"BSD-2-Clause"
] | 1 | 2019-12-16T10:22:07.000Z | 2019-12-16T10:22:07.000Z | lib/macchinista_web/resolvers/quest.ex | themaxhero/Machinista | 2e0114dbbc69fc8187b3ed080de694ac4f558ae8 | [
"BSD-2-Clause"
] | 2 | 2021-03-10T06:56:47.000Z | 2021-05-11T02:41:32.000Z | lib/macchinista_web/resolvers/quest.ex | themaxhero/Macchinista | 2e0114dbbc69fc8187b3ed080de694ac4f558ae8 | [
"BSD-2-Clause"
] | null | null | null | defmodule MacchinistaWeb.Resolvers.Quest do
alias Macchinista.Accounts
alias Macchinista.Cartello
def quests(_, _, _),
do: {:ok, []}
def quest(_, %{id: id}, _),
do: Cartello.get_quest(id)
def create_quest(_, args, %{context: %{user_id: user_id}}) do
user = Accounts.get_user!(user_id)
Carte... | 26.56 | 83 | 0.661898 |
1d4c298a3a85f8eacd91e76a301cb046031355ba | 4,199 | ex | Elixir | clients/ad_experience_report/lib/google_api/ad_experience_report/v1/api/sites.ex | chingor13/elixir-google-api | 85e13fa25c4c9f4618bb463ab4c79245fc6d2a7b | [
"Apache-2.0"
] | 1 | 2018-12-03T23:43:10.000Z | 2018-12-03T23:43:10.000Z | clients/ad_experience_report/lib/google_api/ad_experience_report/v1/api/sites.ex | chingor13/elixir-google-api | 85e13fa25c4c9f4618bb463ab4c79245fc6d2a7b | [
"Apache-2.0"
] | null | null | null | clients/ad_experience_report/lib/google_api/ad_experience_report/v1/api/sites.ex | chingor13/elixir-google-api | 85e13fa25c4c9f4618bb463ab4c79245fc6d2a7b | [
"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 ... | 46.142857 | 196 | 0.667302 |
1d4c5d27787087450cfc8bb231a9f44c0cfa16a8 | 1,799 | ex | Elixir | lib/ex_png/chunks/palette.ex | mad42/ex_png | bde6fbb237c632342dc009c315125d4c3e2a8b99 | [
"Unlicense"
] | 14 | 2021-01-31T16:06:43.000Z | 2021-11-04T18:10:25.000Z | lib/ex_png/chunks/palette.ex | mad42/ex_png | bde6fbb237c632342dc009c315125d4c3e2a8b99 | [
"Unlicense"
] | 6 | 2021-01-31T14:52:17.000Z | 2022-02-01T08:41:03.000Z | lib/ex_png/chunks/palette.ex | mad42/ex_png | bde6fbb237c632342dc009c315125d4c3e2a8b99 | [
"Unlicense"
] | 2 | 2021-04-26T18:51:35.000Z | 2022-01-17T03:39:25.000Z | defmodule ExPng.Chunks.Palette do
@moduledoc """
Representation of the color palette for a PNG image encoded using the
indexed filter method.
"""
alias ExPng.Color
alias ExPng.Chunks.{Header, Transparency}
import ExPng.Utilities, only: [reduce_to_binary: 1]
@type t :: %__MODULE__{
type: :PL... | 26.455882 | 93 | 0.593663 |
1d4c707bd41d07aaafcdb197714e10193293798c | 9,375 | ex | Elixir | lib/mix/tasks/hex.docs.ex | sudix/hex | f739a57d8829ea0b0f7759c164dc9149c3340e49 | [
"Apache-2.0"
] | null | null | null | lib/mix/tasks/hex.docs.ex | sudix/hex | f739a57d8829ea0b0f7759c164dc9149c3340e49 | [
"Apache-2.0"
] | 1 | 2021-06-25T15:19:59.000Z | 2021-06-25T15:19:59.000Z | lib/mix/tasks/hex.docs.ex | sudix/hex | f739a57d8829ea0b0f7759c164dc9149c3340e49 | [
"Apache-2.0"
] | null | null | null | defmodule Mix.Tasks.Hex.Docs do
use Mix.Task
@shortdoc "Fetches or opens documentation of a package"
@moduledoc """
Fetches or opens documentation of a package.
If no version is specified, defaults to version used in the current mix project.
If called outside of a mix project or the dependency is not use... | 27.412281 | 96 | 0.655893 |
1d4c7d709dbe9eb1bdeb84166bcb348257e5894f | 1,862 | ex | Elixir | lib/watchmen/watcher/pod_watcher.ex | corka149/watchmen | 53b85af504dc137ece9a4529b7f87a2426565dc4 | [
"MIT"
] | null | null | null | lib/watchmen/watcher/pod_watcher.ex | corka149/watchmen | 53b85af504dc137ece9a4529b7f87a2426565dc4 | [
"MIT"
] | null | null | null | lib/watchmen/watcher/pod_watcher.ex | corka149/watchmen | 53b85af504dc137ece9a4529b7f87a2426565dc4 | [
"MIT"
] | null | null | null | defmodule Watchmen.PodWatcher do
use GenServer
require Logger
alias Kazan.Watcher
alias Watchmen.ContainerUtils
alias Watchmen.Client.AlerterClient
# # # # # #
# Client #
# # # # # #
def start_link(init_args) when is_list(init_args) do
GenServer.start(__MODULE__, init_args)
end
... | 28.212121 | 119 | 0.668099 |
1d4cadbf71dfb84a119ec028d8c2e126f02f3681 | 133 | ex | Elixir | lib/hub_web/controllers/page_controller.ex | austenmadden/hub | e9cd481a9d604230197790eb9672aa2b94716bc9 | [
"MIT"
] | null | null | null | lib/hub_web/controllers/page_controller.ex | austenmadden/hub | e9cd481a9d604230197790eb9672aa2b94716bc9 | [
"MIT"
] | null | null | null | lib/hub_web/controllers/page_controller.ex | austenmadden/hub | e9cd481a9d604230197790eb9672aa2b94716bc9 | [
"MIT"
] | null | null | null | defmodule HubWeb.PageController do
use HubWeb, :controller
def index(conn, _params) do
render(conn, "index.html")
end
end
| 16.625 | 34 | 0.721805 |
1d4cc3924197862a6ced2c14035136fc49e09207 | 1,616 | exs | Elixir | mix.exs | E1337Kat/villixir | 43294ad0443f91726024a1f141927ae1cb02f49e | [
"MIT"
] | null | null | null | mix.exs | E1337Kat/villixir | 43294ad0443f91726024a1f141927ae1cb02f49e | [
"MIT"
] | null | null | null | mix.exs | E1337Kat/villixir | 43294ad0443f91726024a1f141927ae1cb02f49e | [
"MIT"
] | null | null | null | defmodule Villixir.Mixfile do
use Mix.Project
def project do
[
app: :villixir,
version: "0.0.1",
elixir: "~> 1.4",
elixirc_paths: elixirc_paths(Mix.env),
compilers: [:phoenix, :gettext] ++ Mix.compilers,
start_permanent: Mix.env == :prod,
aliases: aliases(),
deps... | 26.064516 | 79 | 0.579827 |
1d4ceba23575c0d99905da94021e406493720a2b | 4,598 | exs | Elixir | test/simple_bayes/model/bernoulli_test.exs | fredwu/simple_bayes | 806d7e62ab90bdbd8d905faa9536425466f203e2 | [
"MIT"
] | 412 | 2016-07-14T15:34:26.000Z | 2022-03-26T10:34:39.000Z | test/simple_bayes/model/bernoulli_test.exs | fredwu/simple_bayes | 806d7e62ab90bdbd8d905faa9536425466f203e2 | [
"MIT"
] | 7 | 2016-07-20T08:40:07.000Z | 2018-06-11T12:44:19.000Z | test/simple_bayes/model/bernoulli_test.exs | fredwu/simple_bayes | 806d7e62ab90bdbd8d905faa9536425466f203e2 | [
"MIT"
] | 27 | 2016-07-17T13:05:19.000Z | 2021-04-08T21:46:16.000Z | defmodule SimpleBayes.BernoulliTest do
use ExUnit.Case, async: true
alias SimpleBayes.Test.ModelHelper
describe "Bernoulli" do
# http://nlp.stanford.edu/IR-book/html/htmledition/naive-bayes-text-classification-1.html
test "China yes or no" do
result = SimpleBayes.init(model: :bernoulli)
... | 36.784 | 93 | 0.581122 |
1d4d0ced3ad41bbc9f4fd27e07999bab99094886 | 573 | exs | Elixir | test/seren_web/views/error_view_test.exs | allen-garvey/seren | f61cb7edcd7d3f927d2929db14b2a4a1578a3925 | [
"MIT"
] | 4 | 2019-10-04T16:11:15.000Z | 2021-08-18T21:00:13.000Z | apps/seren/test/seren_web/views/error_view_test.exs | allen-garvey/phoenix-umbrella | 1d444bbd62a5e7b5f51d317ce2be71ee994125d5 | [
"MIT"
] | 5 | 2020-03-16T23:52:25.000Z | 2021-09-03T16:52:17.000Z | test/seren_web/views/error_view_test.exs | allen-garvey/seren | f61cb7edcd7d3f927d2929db14b2a4a1578a3925 | [
"MIT"
] | null | null | null | defmodule SerenWeb.ErrorViewTest do
use SerenWeb.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(SerenWeb.ErrorView, "404.html", []) ==
"Page not found"
end
test "render 500.html" ... | 26.045455 | 66 | 0.678883 |
1d4d0eb561808cb63f4cb9982c8b679f66496ef8 | 6,415 | exs | Elixir | test/context_test.exs | EddyLane/surface | 1f13259cbdf81b5a4740ee13349a48f8b6c54bb5 | [
"MIT"
] | 1 | 2020-12-29T10:43:19.000Z | 2020-12-29T10:43:19.000Z | test/context_test.exs | EddyLane/surface | 1f13259cbdf81b5a4740ee13349a48f8b6c54bb5 | [
"MIT"
] | null | null | null | test/context_test.exs | EddyLane/surface | 1f13259cbdf81b5a4740ee13349a48f8b6c54bb5 | [
"MIT"
] | null | null | null | defmodule ContextTest do
use Surface.ConnCase, async: true
alias Surface.Components.Context
defmodule Outer do
use Surface.Component
slot default
def render(assigns) do
~H"""
<Context put={{ __MODULE__, field: "field from Outer" }}>
<div><slot/></div>
</Context>
"""... | 21.745763 | 84 | 0.509119 |
1d4d15abf95fa0fb869ba7f660d00b3d659aa959 | 1,139 | ex | Elixir | lib/adaptable_costs_evaluator_web/channels/user_socket.ex | patrotom/adaptable-costs-evaluator | c97e65af1e021d7c6acf6564f4671c60321346e3 | [
"MIT"
] | null | null | null | lib/adaptable_costs_evaluator_web/channels/user_socket.ex | patrotom/adaptable-costs-evaluator | c97e65af1e021d7c6acf6564f4671c60321346e3 | [
"MIT"
] | 4 | 2021-12-07T12:26:50.000Z | 2021-12-30T14:17:25.000Z | lib/adaptable_costs_evaluator_web/channels/user_socket.ex | patrotom/adaptable-costs-evaluator | c97e65af1e021d7c6acf6564f4671c60321346e3 | [
"MIT"
] | null | null | null | defmodule AdaptableCostsEvaluatorWeb.UserSocket do
use Phoenix.Socket
## Channels
# channel "room:*", AdaptableCostsEvaluatorWeb.RoomChannel
# Socket params are passed from the client and can
# be used to verify and authenticate a user. After
# verification, you can put default assigns into
# the socket... | 31.638889 | 98 | 0.707638 |
1d4d2565a0879b65f74686ee5a99647b3a1c6d19 | 2,293 | exs | Elixir | installer/templates/phx_single/mix.exs | fertapric/phoenix | cd83fedf3bc842caaf850dedd05b65e4fe71bf0c | [
"MIT"
] | null | null | null | installer/templates/phx_single/mix.exs | fertapric/phoenix | cd83fedf3bc842caaf850dedd05b65e4fe71bf0c | [
"MIT"
] | null | null | null | installer/templates/phx_single/mix.exs | fertapric/phoenix | cd83fedf3bc842caaf850dedd05b65e4fe71bf0c | [
"MIT"
] | null | null | null | defmodule <%= app_module %>.MixProject do
use Mix.Project
def project do
[
app: :<%= app_name %>,
version: "0.1.0",<%= if in_umbrella do %>
build_path: "../../_build",
config_path: "../../config/config.exs",
deps_path: "../../deps",
lockfile: "../../mix.lock",<% end %>
... | 32.295775 | 92 | 0.558221 |
1d4d4a0f1a666c7416012a011123ab00546e7622 | 1,272 | exs | Elixir | config/prod.secret.exs | abmBispo/elixir-films | a8464c0cf180be4e8c5835da2702b73aeb5b0cd2 | [
"MIT"
] | null | null | null | config/prod.secret.exs | abmBispo/elixir-films | a8464c0cf180be4e8c5835da2702b73aeb5b0cd2 | [
"MIT"
] | null | null | null | config/prod.secret.exs | abmBispo/elixir-films | a8464c0cf180be4e8c5835da2702b73aeb5b0cd2 | [
"MIT"
] | null | null | null | # In this file, we load production configuration and secrets
# from environment variables. You can also hardcode secrets,
# although such is generally not recommended and you have to
# remember to add this file to your .gitignore.
use Mix.Config
database_url =
System.get_env("DATABASE_URL") ||
raise """
envi... | 30.285714 | 67 | 0.724843 |
1d4d845e804bea9d0bf0bcd904ecf925aa8183c2 | 1,933 | ex | Elixir | fw/phoenix/todo_api/web/controllers/todo_controller.ex | alexgarzao/learning_elixir | f1b06f26898be35803591245d033d30dd4bd1e1a | [
"MIT"
] | null | null | null | fw/phoenix/todo_api/web/controllers/todo_controller.ex | alexgarzao/learning_elixir | f1b06f26898be35803591245d033d30dd4bd1e1a | [
"MIT"
] | null | null | null | fw/phoenix/todo_api/web/controllers/todo_controller.ex | alexgarzao/learning_elixir | f1b06f26898be35803591245d033d30dd4bd1e1a | [
"MIT"
] | null | null | null | defmodule TodoApi.TodoController do
use TodoApi.Web, :controller
use PhoenixSwagger
alias TodoApi.Todo
def index(conn, _params) do
todos = Repo.all(Todo)
render(conn, "index.json", todos: todos)
end
def create(conn, %{"todo" => todo_params}) do
changeset = Todo.changeset(%Todo{}, todo_params)... | 25.434211 | 81 | 0.601655 |
1d4d9693f4ae1061b3344b7e27dc430d3e2ff624 | 1,044 | exs | Elixir | test/bamboo/eex_test.exs | nsweeting/bamboo_eex | 9f57bf6ad7ba4e3b7fd670ba83ca913f9f3740ac | [
"MIT"
] | 6 | 2017-10-03T22:12:22.000Z | 2019-08-18T21:26:05.000Z | test/bamboo/eex_test.exs | nsweeting/bamboo_eex | 9f57bf6ad7ba4e3b7fd670ba83ca913f9f3740ac | [
"MIT"
] | 3 | 2018-06-29T16:34:59.000Z | 2021-02-26T22:54:06.000Z | test/bamboo/eex_test.exs | nsweeting/bamboo_eex | 9f57bf6ad7ba4e3b7fd670ba83ca913f9f3740ac | [
"MIT"
] | 3 | 2018-06-28T17:45:33.000Z | 2021-08-19T11:56:09.000Z | defmodule Bamboo.EExTest do
use ExUnit.Case, async: true
use Bamboo.EEx, path: "test/support"
describe "assign/2" do
test "merges a map into `:assigns`" do
email =
new_email()
|> assign(:key, "value1")
|> assign(%{ key: "value2" })
assert %{ assigns: %{ key: "value2" } }... | 22.212766 | 62 | 0.561303 |
1d4db2052a27f4a8d32b04b4f2ca22b9d0b11500 | 460 | ex | Elixir | lib/live_qchatex_web/plug/session_setup.ex | fiqus/lqchatex | e5a29cadc2b1eb7fce88be3e612a5ff240a09b59 | [
"MIT"
] | 8 | 2019-06-01T18:45:47.000Z | 2021-11-10T07:56:20.000Z | lib/live_qchatex_web/plug/session_setup.ex | fiqus/lqchatex | e5a29cadc2b1eb7fce88be3e612a5ff240a09b59 | [
"MIT"
] | 3 | 2020-04-19T15:59:27.000Z | 2021-05-09T00:33:11.000Z | lib/live_qchatex_web/plug/session_setup.ex | fiqus/lqchatex | e5a29cadc2b1eb7fce88be3e612a5ff240a09b59 | [
"MIT"
] | 3 | 2019-10-25T16:03:12.000Z | 2021-11-10T07:53:14.000Z | defmodule LiveQchatexWeb.Plug.SessionSetup do
import Plug.Conn
@key :sid
def init(opts), do: opts
def call(conn, _opts) do
conn |> load_sid()
end
defp load_sid(conn), do: conn |> load_sid(get_session(conn, @key))
defp load_sid(conn, nil), do: conn |> set_sid(LiveQchatex.Repo.random_string(256))
... | 25.555556 | 84 | 0.682609 |
1d4e16893acb65018412a5bc32ce9e8646713ab2 | 3,857 | ex | Elixir | clients/service_consumer_management/lib/google_api/service_consumer_management/v1/model/v1_beta1_producer_quota_policy.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2021-12-20T03:40:53.000Z | 2021-12-20T03:40:53.000Z | clients/service_consumer_management/lib/google_api/service_consumer_management/v1/model/v1_beta1_producer_quota_policy.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2020-08-18T00:11:23.000Z | 2020-08-18T00:44:16.000Z | clients/service_consumer_management/lib/google_api/service_consumer_management/v1/model/v1_beta1_producer_quota_policy.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... | 60.265625 | 1,065 | 0.721286 |
1d4e1840d5555bd7071a31996e51bd9b26b23f41 | 2,191 | ex | Elixir | clients/compute/lib/google_api/compute/v1/model/instance_groups_set_named_ports_request.ex | mocknen/elixir-google-api | dac4877b5da2694eca6a0b07b3bd0e179e5f3b70 | [
"Apache-2.0"
] | null | null | null | clients/compute/lib/google_api/compute/v1/model/instance_groups_set_named_ports_request.ex | mocknen/elixir-google-api | dac4877b5da2694eca6a0b07b3bd0e179e5f3b70 | [
"Apache-2.0"
] | null | null | null | clients/compute/lib/google_api/compute/v1/model/instance_groups_set_named_ports_request.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... | 42.960784 | 516 | 0.766773 |
1d4e29c5fc780999f548e2e562627d5a580b4672 | 602 | ex | Elixir | lib/events_tools_web/helpers/redirects.ex | community-tools/community-tools | 40b0e6cc9234b44593d2ab60bb2303d7224deb30 | [
"Apache-2.0"
] | 2 | 2017-10-06T01:14:35.000Z | 2017-11-18T16:44:44.000Z | lib/events_tools_web/helpers/redirects.ex | community-tools/community-tools | 40b0e6cc9234b44593d2ab60bb2303d7224deb30 | [
"Apache-2.0"
] | 6 | 2017-10-06T00:04:59.000Z | 2017-10-06T00:09:27.000Z | lib/events_tools_web/helpers/redirects.ex | apps-team/community-tools | 40b0e6cc9234b44593d2ab60bb2303d7224deb30 | [
"Apache-2.0"
] | 1 | 2017-10-06T01:17:35.000Z | 2017-10-06T01:17:35.000Z | defmodule CommunityToolsWeb.Redirects do
use Plug.Redirect
# Argument #1 is the path to redirect from
# Argument #2 is the path to redirect to
#redirect "/", "/2017"
redirect "/cfp", "/2017/cfp"
redirect "/dashboard", "/2017/dashboard"
redirect "/profile", "/2017/profile"
# An HTTP status code c... | 23.153846 | 62 | 0.694352 |
1d4e3cde2de38ae684a8a8d01b8ac3db3a268121 | 145 | ex | Elixir | lib/mangopay_ex/resources/transfers.ex | StephaneRob/mangopay_ex | d05dab35f431c2f18f6ae95aedf68dede6731402 | [
"MIT"
] | 1 | 2018-02-01T11:10:09.000Z | 2018-02-01T11:10:09.000Z | lib/mangopay_ex/resources/transfers.ex | StephaneRob/mangopay_ex | d05dab35f431c2f18f6ae95aedf68dede6731402 | [
"MIT"
] | null | null | null | lib/mangopay_ex/resources/transfers.ex | StephaneRob/mangopay_ex | d05dab35f431c2f18f6ae95aedf68dede6731402 | [
"MIT"
] | null | null | null | defmodule MangopayEx.Transfers do
@endpoint "transfers"
@resource_name "transfer"
use MangopayEx.Resource, import: [:create, :view]
end
| 16.111111 | 51 | 0.744828 |
1d4e43df1faf4d2cac77f8cba3b140833806eef9 | 12,405 | ex | Elixir | lib/phoenix_live_view/test/dom.ex | feliperenan/phoenix_live_view | af65bb51fe12ea88e7c66808d2b1118e1c491ddd | [
"MIT"
] | 1 | 2020-09-09T09:10:01.000Z | 2020-09-09T09:10:01.000Z | lib/phoenix_live_view/test/dom.ex | feliperenan/phoenix_live_view | af65bb51fe12ea88e7c66808d2b1118e1c491ddd | [
"MIT"
] | null | null | null | lib/phoenix_live_view/test/dom.ex | feliperenan/phoenix_live_view | af65bb51fe12ea88e7c66808d2b1118e1c491ddd | [
"MIT"
] | null | null | null | defmodule Phoenix.LiveViewTest.DOM do
@moduledoc false
@phx_static "data-phx-static"
@phx_component "data-phx-component"
@static :s
@components :c
def ensure_loaded! do
unless Code.ensure_loaded?(Floki) do
raise """
Phoenix LiveView requires Floki as a test dependency.
Please add to ... | 27.203947 | 97 | 0.595083 |
1d4e4b316b368f7832d56fee1c2225862222368f | 2,255 | ex | Elixir | lib/tesla/middleware/consul_watch.ex | nsdavidson/consulex | 6ac7360c4035555da0d0066c1893a7d4d63b1b0b | [
"Apache-2.0"
] | 1 | 2021-06-14T10:59:01.000Z | 2021-06-14T10:59:01.000Z | lib/tesla/middleware/consul_watch.ex | nsdavidson/consulex | 6ac7360c4035555da0d0066c1893a7d4d63b1b0b | [
"Apache-2.0"
] | 1 | 2021-12-15T01:23:36.000Z | 2021-12-15T01:23:36.000Z | lib/tesla/middleware/consul_watch.ex | nsdavidson/consulex | 6ac7360c4035555da0d0066c1893a7d4d63b1b0b | [
"Apache-2.0"
] | 4 | 2020-10-17T13:11:58.000Z | 2021-12-30T17:51:04.000Z | defmodule Tesla.Middleware.ConsulWatch do
@moduledoc """
Fills the request so it results in a Consul blocking query.
## Example usage
```
defmodule Myclient do
use Tesla
plug Tesla.Middleware.ConsulWatch, wait: 60_000
end
```
"""
@behaviour Tesla.Middleware
use GenServer
@default_wait... | 19.273504 | 67 | 0.557428 |
1d4e64df221eb68158e29ab66b8ad1da38264572 | 2,188 | ex | Elixir | clients/compute/lib/google_api/compute/v1/model/machine_type_aggregated_list_warning.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/compute/lib/google_api/compute/v1/model/machine_type_aggregated_list_warning.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/machine_type_aggregated_list_warning.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.518519 | 194 | 0.72989 |
1d4ea5613982b24a318f58b229fef3b302a5625a | 958 | exs | Elixir | test/core/core_test.exs | sylph01/antikythera | 47a93f3d4c70975f7296725c9bde2ea823867436 | [
"Apache-2.0"
] | 144 | 2018-04-27T07:24:49.000Z | 2022-03-15T05:19:37.000Z | test/core/core_test.exs | sylph01/antikythera | 47a93f3d4c70975f7296725c9bde2ea823867436 | [
"Apache-2.0"
] | 123 | 2018-05-01T02:54:43.000Z | 2022-01-28T01:30:52.000Z | test/core/core_test.exs | sylph01/antikythera | 47a93f3d4c70975f7296725c9bde2ea823867436 | [
"Apache-2.0"
] | 14 | 2018-05-01T02:30:47.000Z | 2022-02-21T04:38:56.000Z | # Copyright(c) 2015-2021 ACCESS CO., LTD. All rights reserved.
defmodule AntikytheraCoreTest do
use Croma.TestCase
alias AntikytheraEal.ClusterConfiguration
setup do
:meck.new(ClusterConfiguration, [:passthrough])
on_exit(&:meck.unload/0)
end
defp mock_health_check_grace_period_in_seconds(grace_pe... | 24.564103 | 118 | 0.696242 |
1d4ec1b41a19dc67be4a880b42c6b4a8450e89c8 | 1,745 | ex | Elixir | lib/langue/formatter/gettext/parser.ex | gitter-badger/accent-1 | b2fdf26e598d832550eceaa40cd8055f93bca216 | [
"BSD-3-Clause"
] | null | null | null | lib/langue/formatter/gettext/parser.ex | gitter-badger/accent-1 | b2fdf26e598d832550eceaa40cd8055f93bca216 | [
"BSD-3-Clause"
] | null | null | null | lib/langue/formatter/gettext/parser.ex | gitter-badger/accent-1 | b2fdf26e598d832550eceaa40cd8055f93bca216 | [
"BSD-3-Clause"
] | null | null | null | defmodule Langue.Formatter.Gettext.Parser do
@behaviour Langue.Formatter.Parser
alias Langue.Entry
def parse(%{render: render}) do
{:ok, po} = Gettext.PO.parse_string(render)
entries = parse_translations(po)
top_of_the_file_comment = join_string(po.top_of_the_file_comments)
header = join_string(... | 26.846154 | 74 | 0.654441 |
1d4ec335ce6ef630ab10348bd785fd85d9da5e3a | 1,195 | exs | Elixir | mix.exs | kipcole9/linguist | d67b60fd597bfe894c69773efd05ad690dad8663 | [
"MIT"
] | null | null | null | mix.exs | kipcole9/linguist | d67b60fd597bfe894c69773efd05ad690dad8663 | [
"MIT"
] | null | null | null | mix.exs | kipcole9/linguist | d67b60fd597bfe894c69773efd05ad690dad8663 | [
"MIT"
] | null | null | null | Code.ensure_loaded?(Hex) and Hex.start()
defmodule Linguist.Mixfile do
use Mix.Project
@description """
Elixir Internationalization library, extended to support translation files in the rails-i18n format.
"""
@repo_url "https://github.com/change/linguist"
@version "0.3.1"
def project do
[
a... | 19.916667 | 102 | 0.542259 |
1d4f06dc4c3f14f57cbca0ca48c4c95db71b08ce | 261 | ex | Elixir | apps/bus_detective/lib/bus_detective.ex | bus-detective/bus_detective_ng | ef54684d4f640384bd20a4d5550ff51ab440190b | [
"MIT"
] | 8 | 2018-07-06T14:44:10.000Z | 2021-08-19T17:24:25.000Z | apps/bus_detective/lib/bus_detective.ex | bus-detective/bus_detective_ng | ef54684d4f640384bd20a4d5550ff51ab440190b | [
"MIT"
] | 12 | 2018-07-15T18:43:04.000Z | 2022-02-10T16:07:47.000Z | apps/bus_detective/lib/bus_detective.ex | bus-detective/bus_detective_ng | ef54684d4f640384bd20a4d5550ff51ab440190b | [
"MIT"
] | 1 | 2018-07-13T17:30:20.000Z | 2018-07-13T17:30:20.000Z | defmodule BusDetective do
@moduledoc """
BusDetective 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 |
1d4f2736db7c5b0ea1c2a47d0d325bacfc2cde00 | 630 | exs | Elixir | {{cookiecutter.project_underscored}}/config/test.exs | ijcd/cookiecutter-screaming-phoenix | f34ca6704f8f8b0581e91b4f6e3e75239fb79cb1 | [
"Apache-2.0"
] | null | null | null | {{cookiecutter.project_underscored}}/config/test.exs | ijcd/cookiecutter-screaming-phoenix | f34ca6704f8f8b0581e91b4f6e3e75239fb79cb1 | [
"Apache-2.0"
] | null | null | null | {{cookiecutter.project_underscored}}/config/test.exs | ijcd/cookiecutter-screaming-phoenix | f34ca6704f8f8b0581e91b4f6e3e75239fb79cb1 | [
"Apache-2.0"
] | null | null | null | use Mix.Config
# We don't run a server during test. If one is required,
# you can enable the server option below.
config :{{cookiecutter.project_underscored}}, {{cookiecutter.project_module}}.Web.Endpoint,
http: [port: 4001],
server: false
# Print only warnings and errors during test
config :logger, level: :warn
... | 31.5 | 91 | 0.750794 |
1d4f34e471f9159a0721d01ec9699542f3644075 | 142 | ex | Elixir | lib/conduit/blog/events/author_created.ex | rudyyazdi/conduit | 8defa60962482fb81f5093ea5d58b71a160db3c4 | [
"MIT"
] | null | null | null | lib/conduit/blog/events/author_created.ex | rudyyazdi/conduit | 8defa60962482fb81f5093ea5d58b71a160db3c4 | [
"MIT"
] | 2 | 2022-01-15T02:09:30.000Z | 2022-01-22T10:18:43.000Z | lib/conduit/blog/events/author_created.ex | rudyyazdi/conduit | 8defa60962482fb81f5093ea5d58b71a160db3c4 | [
"MIT"
] | null | null | null | defmodule Conduit.Blog.Events.AuthorCreated do
@derive Jason.Encoder
defstruct [
:author_uuid,
:user_uuid,
:username,
]
end
| 15.777778 | 46 | 0.697183 |
1d4f37ec91076e1ee3fbacfff5e957ec1ededb83 | 2,140 | ex | Elixir | clients/people/lib/google_api/people/v1/model/membership.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/people/lib/google_api/people/v1/model/membership.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/people/lib/google_api/people/v1/model/membership.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | # Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, s... | 39.62963 | 143 | 0.742991 |
1d4f7097b01ab1e44384e1b00301e87aa2ba03cf | 1,572 | exs | Elixir | mix.exs | bwhite-mdsol/white-bread | 4146e1ec4e23af42e93f10e06897a010b593b18f | [
"MIT"
] | null | null | null | mix.exs | bwhite-mdsol/white-bread | 4146e1ec4e23af42e93f10e06897a010b593b18f | [
"MIT"
] | null | null | null | mix.exs | bwhite-mdsol/white-bread | 4146e1ec4e23af42e93f10e06897a010b593b18f | [
"MIT"
] | null | null | null | defmodule WhiteBread.Mixfile do
use Mix.Project
def project do
[app: :white_bread,
name: "WhiteBread",
description: """
Story BDD tool based on cucumber.
Parses Gherkin formatted feature files and executes them as tests.
""",
package: [
maintainers: ["Steve Brazier"],
... | 22.140845 | 77 | 0.563613 |
1d4f72a2767e02e7d2bbcfba5d8fffb103ee3a2c | 1,889 | exs | Elixir | mix.exs | al2o3cr/postgrex | a849473e9bc7f821deb7c787a974735aeef24619 | [
"Apache-2.0"
] | null | null | null | mix.exs | al2o3cr/postgrex | a849473e9bc7f821deb7c787a974735aeef24619 | [
"Apache-2.0"
] | null | null | null | mix.exs | al2o3cr/postgrex | a849473e9bc7f821deb7c787a974735aeef24619 | [
"Apache-2.0"
] | null | null | null | defmodule Postgrex.Mixfile do
use Mix.Project
@source_url "https://github.com/elixir-ecto/postgrex"
@version "0.15.9"
def project do
[
app: :postgrex,
version: @version,
elixir: "~> 1.11",
deps: deps(),
name: "Postgrex",
description: "PostgreSQL driver for Elixir",
... | 22.759036 | 68 | 0.538909 |
1d4f72ac5279bdb20b2f15bc6463f5be7fc72dfe | 318 | exs | Elixir | config/dev.exs | opendoor-labs/paladin_client | 960e7b5ee458c471c140b370ed9a995b7463456c | [
"MIT"
] | 3 | 2016-10-25T16:45:37.000Z | 2021-06-04T06:03:00.000Z | config/dev.exs | opendoor-labs/paladin_client | 960e7b5ee458c471c140b370ed9a995b7463456c | [
"MIT"
] | 1 | 2019-01-15T23:32:07.000Z | 2019-01-15T23:32:07.000Z | config/dev.exs | opendoor-labs/paladin_client | 960e7b5ee458c471c140b370ed9a995b7463456c | [
"MIT"
] | null | null | null | use Mix.Config
config :guardian, Guardian,
serializer: PaladinClient.Test.GuardianSerializer,
issuer: "paladin_client_dev",
secret_key: "dev"
config :paladin_client, PaladinClient,
adapter: PaladinClient.HttpClient,
url: "http://localhost:4000",
apps: [
one: "one-app-id",
two: "two-app-id",
]
| 21.2 | 52 | 0.707547 |
1d4f7adc0f86a52e9450a4e55b92e633882a3a72 | 3,926 | ex | Elixir | clients/slides/lib/google_api/slides/v1/model/response.ex | GoNZooo/elixir-google-api | cf3ad7392921177f68091f3d9001f1b01b92f1cc | [
"Apache-2.0"
] | null | null | null | clients/slides/lib/google_api/slides/v1/model/response.ex | GoNZooo/elixir-google-api | cf3ad7392921177f68091f3d9001f1b01b92f1cc | [
"Apache-2.0"
] | null | null | null | clients/slides/lib/google_api/slides/v1/model/response.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... | 50.333333 | 185 | 0.76108 |
1d4f7ec9a2c00fb6b87f4d63305cf5c8c3bb7c1c | 136 | ex | Elixir | lib/forus_web/controllers/home_controller.ex | finalclass/forus | f745d3ef63684b8fa61a904d4032b5ae26931943 | [
"MIT"
] | null | null | null | lib/forus_web/controllers/home_controller.ex | finalclass/forus | f745d3ef63684b8fa61a904d4032b5ae26931943 | [
"MIT"
] | 1 | 2018-06-19T10:38:48.000Z | 2018-06-19T10:38:48.000Z | lib/forus_web/controllers/home_controller.ex | finalclass/forus | f745d3ef63684b8fa61a904d4032b5ae26931943 | [
"MIT"
] | null | null | null | defmodule ForusWeb.HomeController do
use ForusWeb, :controller
def index(conn, _params) do
render conn, "index.html"
end
end
| 17 | 36 | 0.735294 |
1d4f98bdb37ce88175ad478de754ac71d0995e24 | 1,012 | exs | Elixir | elixir/pig-latin/pig_latin.exs | nayed/exercism | effee8c79b21b9a58049d863646d341c069aa835 | [
"MIT"
] | null | null | null | elixir/pig-latin/pig_latin.exs | nayed/exercism | effee8c79b21b9a58049d863646d341c069aa835 | [
"MIT"
] | null | null | null | elixir/pig-latin/pig_latin.exs | nayed/exercism | effee8c79b21b9a58049d863646d341c069aa835 | [
"MIT"
] | null | null | null | defmodule PigLatin do
@vowels ~w(a e i o u yt xr)
@supplement_consonants ~r(ch|qu|squ|thr|th|sch|[^aeiou])
@doc """
Given a `phrase`, translate it a word at a time to Pig Latin.
Words beginning with consonants should have the consonant moved to the end of
the word, followed by "ay".
Words beginning wit... | 28.914286 | 118 | 0.624506 |
1d4fb7ffdb90ca1560db79d153aa9b250eeb90b5 | 552 | exs | Elixir | config/test.exs | rjdellecese/hon-graffiti-phoenix | a1ee866ef89f9b8ebb45a644db0b19729a37b07d | [
"MIT"
] | null | null | null | config/test.exs | rjdellecese/hon-graffiti-phoenix | a1ee866ef89f9b8ebb45a644db0b19729a37b07d | [
"MIT"
] | null | null | null | config/test.exs | rjdellecese/hon-graffiti-phoenix | a1ee866ef89f9b8ebb45a644db0b19729a37b07d | [
"MIT"
] | null | null | null | use Mix.Config
# We don't run a server during test. If one is required,
# you can enable the server option below.
config :hon_graffiti_phoenix, HonGraffitiPhoenix.Endpoint,
http: [port: 4001],
server: false
# Print only warnings and errors during test
config :logger, level: :warn
# Configure your database
config... | 27.6 | 58 | 0.762681 |
1d4fbdb2d863b3cfe73a818c12aac2728173e784 | 965 | exs | Elixir | config/prod.secret.exs | paulanthonywilson/correct-horse-elixir | 63853f0dff8f3255b7714d12316deccc0879c740 | [
"MIT"
] | 3 | 2020-09-11T09:41:05.000Z | 2021-01-29T00:16:39.000Z | config/prod.secret.exs | paulanthonywilson/correct-horse-elixir | 63853f0dff8f3255b7714d12316deccc0879c740 | [
"MIT"
] | 4 | 2020-07-21T09:31:22.000Z | 2021-06-07T09:27:51.000Z | config/prod.secret.exs | paulanthonywilson/correct-horse-elixir | 63853f0dff8f3255b7714d12316deccc0879c740 | [
"MIT"
] | null | null | null | # In this file, we load production configuration and secrets
# from environment variables. You can also hardcode secrets,
# although such is generally not recommended and you have to
# remember to add this file to your .gitignore.
use Mix.Config
secret_key_base =
System.get_env("SECRET_KEY_BASE") ||
raise """
... | 32.166667 | 70 | 0.737824 |
1d4fe17e36a700ace2abf4e5df85b4f5892fc540 | 2,745 | ex | Elixir | clients/machine_learning/lib/google_api/machine_learning/v1/model/google_cloud_ml_v1__study_config.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/machine_learning/lib/google_api/machine_learning/v1/model/google_cloud_ml_v1__study_config.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/machine_learning/lib/google_api/machine_learning/v1/model/google_cloud_ml_v1__study_config.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | # Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, s... | 39.214286 | 200 | 0.749362 |
1d4fe7b95227051b2b5bc96abb8590b17ac46aad | 1,743 | exs | Elixir | config/config.exs | axelson/hexpm | 3608a9aa16d321f8f7d0890528676c0821d85686 | [
"Apache-2.0"
] | 2 | 2020-03-01T18:23:33.000Z | 2021-01-15T10:15:45.000Z | config/config.exs | axelson/hexpm | 3608a9aa16d321f8f7d0890528676c0821d85686 | [
"Apache-2.0"
] | 3 | 2020-06-30T11:24:41.000Z | 2020-08-05T15:47:34.000Z | config/config.exs | axelson/hexpm | 3608a9aa16d321f8f7d0890528676c0821d85686 | [
"Apache-2.0"
] | null | null | null | import Config
config :hexpm,
user_confirm: true,
user_agent_req: true,
secret: "796f75666f756e64746865686578",
support_email: "support@hex.pm",
repo_bucket: {Hexpm.Store.Local, "repo_bucket"},
logs_bucket: {Hexpm.Store.Local, "logs_bucket"},
cdn_impl: Hexpm.CDN.Local,
billing_impl: Hexpm.Billing.Local,... | 26.815385 | 86 | 0.747562 |
1d5009baadfdf6af41c690ae97a6519e83acccfa | 5,351 | ex | Elixir | lib/virgo_web/controllers/contests/problem_controller.ex | GinShio/AstraeaVirgo | 92804cbae01f67e21b8f421009fa37fddc9054e1 | [
"BSD-2-Clause"
] | null | null | null | lib/virgo_web/controllers/contests/problem_controller.ex | GinShio/AstraeaVirgo | 92804cbae01f67e21b8f421009fa37fddc9054e1 | [
"BSD-2-Clause"
] | null | null | null | lib/virgo_web/controllers/contests/problem_controller.ex | GinShio/AstraeaVirgo | 92804cbae01f67e21b8f421009fa37fddc9054e1 | [
"BSD-2-Clause"
] | null | null | null | defmodule AstraeaVirgoWeb.Contests.ProblemController do
use AstraeaVirgoWeb, :controller
@moduledoc """
Impl Problem API without auth:
- `GET /api/contests/<contest_id>/problems`: get problems info
- `GET /api/contests/<contest_id>/problems/<problem_id>`: get the specified problem info
- `GET /api/co... | 41.804688 | 120 | 0.664922 |
1d500e5b8f91653ca6c4e1ae3cde1003f35560d0 | 300 | ex | Elixir | lib/pubg_api/api_key.ex | norbertnull/pubg_api | 54b20ec91feeefc72d6dc2034cd70da62f06083a | [
"Apache-2.0"
] | null | null | null | lib/pubg_api/api_key.ex | norbertnull/pubg_api | 54b20ec91feeefc72d6dc2034cd70da62f06083a | [
"Apache-2.0"
] | null | null | null | lib/pubg_api/api_key.ex | norbertnull/pubg_api | 54b20ec91feeefc72d6dc2034cd70da62f06083a | [
"Apache-2.0"
] | null | null | null | defmodule PubgApi.ApiKey do
def generate(api_key) when is_bitstring(api_key) do
"Bearer " <> api_key
end
def add_to_headers(header_map, api_key) when is_bitstring(api_key) and is_map(header_map) do
header_map
|> Map.put("Authorization", PubgApi.ApiKey.generate(api_key))
end
end
| 27.272727 | 94 | 0.746667 |
1d501a369ce0b2f1dfb88ba7118be0e3c4e606f2 | 1,215 | ex | Elixir | lib/koans/02_strings.ex | Hana897TRX/quiz1-elixir | 17a6ec743a95b6f038a865c10d7b2d5a07e73a0f | [
"MIT"
] | null | null | null | lib/koans/02_strings.ex | Hana897TRX/quiz1-elixir | 17a6ec743a95b6f038a865c10d7b2d5a07e73a0f | [
"MIT"
] | null | null | null | lib/koans/02_strings.ex | Hana897TRX/quiz1-elixir | 17a6ec743a95b6f038a865c10d7b2d5a07e73a0f | [
"MIT"
] | null | null | null | defmodule Strings do
use Koans
@intro "Strings"
koan "Strings are there to represent text" do
assert "hello" == "hello"
end
koan "Values may be inserted into strings by interpolation" do
assert "1 + 1 = #{1 + 1}" == "1 + 1 = #{1 + 1}"
end
koan "They can be put together" do
assert "hello wo... | 26.413043 | 87 | 0.651029 |
1d5078610a3768aa2f476526a440676973839a2d | 2,477 | ex | Elixir | lib/game/command/map.ex | shanesveller/ex_venture | 68507da11442a9e0423073fcd305e9021f649ca1 | [
"MIT"
] | null | null | null | lib/game/command/map.ex | shanesveller/ex_venture | 68507da11442a9e0423073fcd305e9021f649ca1 | [
"MIT"
] | null | null | null | lib/game/command/map.ex | shanesveller/ex_venture | 68507da11442a9e0423073fcd305e9021f649ca1 | [
"MIT"
] | null | null | null | defmodule Game.Command.Map do
@moduledoc """
The "map" command
"""
use Game.Command
use Game.Zone
alias Game.Environment
alias Game.Session.GMCP
commands(["map"], parse: false)
@impl Game.Command
def help(:topic), do: "Map"
def help(:short), do: "View a map of the zone"
def help(:full) do
... | 24.284314 | 88 | 0.576908 |
1d50799b3161ea0f44534c7efde6ece0bd7a58bf | 111 | exs | Elixir | imaas/config/releases.exs | Elonsoft/imaas | ba5eca1559d042822ba66786e8db53d2f988fb2f | [
"WTFPL"
] | 1 | 2020-07-27T15:50:30.000Z | 2020-07-27T15:50:30.000Z | imaas/config/releases.exs | Elonsoft/imaas | ba5eca1559d042822ba66786e8db53d2f988fb2f | [
"WTFPL"
] | null | null | null | imaas/config/releases.exs | Elonsoft/imaas | ba5eca1559d042822ba66786e8db53d2f988fb2f | [
"WTFPL"
] | null | null | null | import Config
port =
"PORT"
|> System.get_env("4000")
|> String.to_integer()
config :imaas, port: port
| 12.333333 | 27 | 0.648649 |
1d50aef3c70e9277bbf4a86ee5c822f589fba565 | 1,113 | ex | Elixir | lib/ecto/query/builder/where.ex | yrashk/ecto | 1462d5ad4cbb7bf74c292ec405852bc196808daf | [
"Apache-2.0"
] | 1 | 2016-08-15T21:23:28.000Z | 2016-08-15T21:23:28.000Z | lib/ecto/query/builder/where.ex | yrashk/ecto | 1462d5ad4cbb7bf74c292ec405852bc196808daf | [
"Apache-2.0"
] | null | null | null | lib/ecto/query/builder/where.ex | yrashk/ecto | 1462d5ad4cbb7bf74c292ec405852bc196808daf | [
"Apache-2.0"
] | null | null | null | defmodule Ecto.Query.Builder.Where do
@moduledoc false
alias Ecto.Query.Builder
@doc """
Builds a quoted expression.
The quoted expression should evaluate to a query at runtime.
If possible, it does all calculations at compile time to avoid
runtime work.
"""
@spec build(Macro.t, [Macro.t], Macro.t,... | 30.916667 | 66 | 0.620845 |
1d50ecfe222deae629471016e0df20a8c05f8d9f | 2,101 | exs | Elixir | test/lazymaru_validations_test.exs | aforward-oss/lazymaru | e656a342e1dc2989b8e27ab399cb2f4c571aa502 | [
"BSD-3-Clause"
] | null | null | null | test/lazymaru_validations_test.exs | aforward-oss/lazymaru | e656a342e1dc2989b8e27ab399cb2f4c571aa502 | [
"BSD-3-Clause"
] | null | null | null | test/lazymaru_validations_test.exs | aforward-oss/lazymaru | e656a342e1dc2989b8e27ab399cb2f4c571aa502 | [
"BSD-3-Clause"
] | null | null | null | defmodule Lazymaru.ValidationsTest do
use ExUnit.Case , async: true
alias Lazymaru.Validations
test "regexp" do
assert Validations.Regexp.validate_param!(:param, "1", ~r"1")
assert_raise Lazymaru.Exceptions.Validation, fn ->
Validations.Regexp.validate_param!(:param, "1", ~r"2")
end
end
te... | 36.224138 | 70 | 0.676821 |
1d50f10628701e39ab717ac7ea0c2ac4bdc6693b | 1,053 | ex | Elixir | api/lib/api_web/channels/user_socket.ex | andrewvmail/momoirc | 15cd76dc8b5f99f72e4a8e05a35dca9bf293bfca | [
"MIT"
] | 59 | 2021-09-16T19:29:39.000Z | 2022-03-31T20:44:24.000Z | apps/api/lib/api_web/channels/user_socket.ex | svilenkov/plural | ac6c6cc15ac4b66a3b5e32ed4a7bee4d46d1f026 | [
"Apache-2.0"
] | 111 | 2021-08-15T09:56:37.000Z | 2022-03-31T23:59:32.000Z | apps/api/lib/api_web/channels/user_socket.ex | svilenkov/plural | ac6c6cc15ac4b66a3b5e32ed4a7bee4d46d1f026 | [
"Apache-2.0"
] | 4 | 2021-12-13T09:43:01.000Z | 2022-03-29T18:08:44.000Z | defmodule ApiWeb.UserSocket do
use Phoenix.Socket
## Channels
# channel "room:*", ApiWeb.RoomChannel
# Socket params are passed from the client and can
# be used to verify and authenticate a user. After
# verification, you can put default assigns into
# the socket that will be set for all channels, ie
... | 30.970588 | 83 | 0.693257 |
1d510341dce207764703af9755dff39386cda48b | 483 | ex | Elixir | test/support/assert_helper.ex | chownces/cadet | 0d8b264e4fad1c9aaab7ef3f037ac4e07a4c9b22 | [
"Apache-2.0"
] | 27 | 2018-01-20T05:56:24.000Z | 2021-05-24T03:21:55.000Z | test/support/assert_helper.ex | chownces/cadet | 0d8b264e4fad1c9aaab7ef3f037ac4e07a4c9b22 | [
"Apache-2.0"
] | 731 | 2018-04-16T13:25:49.000Z | 2021-06-22T07:16:12.000Z | test/support/assert_helper.ex | chownces/cadet | 0d8b264e4fad1c9aaab7ef3f037ac4e07a4c9b22 | [
"Apache-2.0"
] | 43 | 2018-01-20T06:35:46.000Z | 2021-05-05T03:22:35.000Z | defmodule Cadet.AssertHelper do
@moduledoc """
Contains some general assertion helpers for tests.
"""
import ExUnit.Assertions, only: [assert: 1]
def assert_submaps_eq(expected, actual, fields) do
assert length(expected) == length(actual)
Enum.map(Enum.zip([expected, actual]), fn {e, a} -> assert_s... | 26.833333 | 91 | 0.708075 |
1d5113b205ad67638f91c69579b849da7c180310 | 65 | ex | Elixir | lib/chit_chat_web/views/author_view.ex | areski/ex-chitchat | 0ec14e9af6acba40d6708f924b76fb4fbe592dcf | [
"MIT"
] | 1 | 2021-09-10T16:49:36.000Z | 2021-09-10T16:49:36.000Z | lib/chit_chat_web/views/author_view.ex | areski/ex-chitchat | 0ec14e9af6acba40d6708f924b76fb4fbe592dcf | [
"MIT"
] | 2 | 2020-05-22T18:42:14.000Z | 2021-01-25T16:34:38.000Z | lib/chit_chat_web/views/author_view.ex | areski/ex-chitchat | 0ec14e9af6acba40d6708f924b76fb4fbe592dcf | [
"MIT"
] | null | null | null | defmodule ChitChatWeb.AuthorView do
use ChitChatWeb, :view
end
| 16.25 | 35 | 0.815385 |
1d515a1ba4a4ff5d2b62e76ab891fb767689b5c9 | 42,419 | ex | Elixir | lib/panpipe/ast/nodes.ex | marcelotto/panpipe | 1deba792f8d10ac0474f9c993f0ff326862f2aa1 | [
"MIT"
] | 24 | 2019-08-19T02:53:06.000Z | 2022-03-13T14:41:08.000Z | lib/panpipe/ast/nodes.ex | marcelotto/panpipe | 1deba792f8d10ac0474f9c993f0ff326862f2aa1 | [
"MIT"
] | 4 | 2020-04-02T02:05:52.000Z | 2022-03-18T00:56:23.000Z | lib/panpipe/ast/nodes.ex | marcelotto/panpipe | 1deba792f8d10ac0474f9c993f0ff326862f2aa1 | [
"MIT"
] | 2 | 2019-10-28T15:38:47.000Z | 2021-03-24T17:43:27.000Z | import ProtocolEx
defprotocol_ex Panpipe.Pandoc.AST.Node do
@moduledoc false
def to_panpipe(node)
end
################################################################################
# Helper struct: Attr
defmodule Panpipe.AST.Attr do
defstruct [
identifier: "", # :: String
classes: [], ... | 28.166667 | 203 | 0.602914 |
1d515f4346cee9c508e3f4fff21d6e9f251a00fa | 3,078 | ex | Elixir | lib/k8s/discovery.ex | Overbryd/k8s | 7057601b1f191b47294133045c9e5b74bd9dd525 | [
"MIT"
] | null | null | null | lib/k8s/discovery.ex | Overbryd/k8s | 7057601b1f191b47294133045c9e5b74bd9dd525 | [
"MIT"
] | null | null | null | lib/k8s/discovery.ex | Overbryd/k8s | 7057601b1f191b47294133045c9e5b74bd9dd525 | [
"MIT"
] | null | null | null | defmodule K8s.Discovery do
@moduledoc """
Auto discovery of Kubenetes API Versions and Groups.
"""
@behaviour K8s.Behaviours.DiscoveryProvider
alias K8s.Cluster
alias K8s.Conf.RequestOptions
@doc """
List all resource definitions by group
## Examples
iex> K8s.Discovery.resource_definitions_b... | 36.642857 | 923 | 0.602664 |
1d515fff31a7f644d74282a900069c1aa9766a11 | 1,447 | ex | Elixir | test/support/schema.ex | timbuckley/ecto_paging | 1d0dc9e2b5158e3948d03951f08f62e4a511b6ad | [
"MIT"
] | 13 | 2016-11-25T14:59:28.000Z | 2020-01-16T23:23:25.000Z | test/support/schema.ex | timbuckley/ecto_paging | 1d0dc9e2b5158e3948d03951f08f62e4a511b6ad | [
"MIT"
] | 22 | 2016-11-17T09:51:12.000Z | 2020-03-03T15:32:04.000Z | test/support/schema.ex | timbuckley/ecto_paging | 1d0dc9e2b5158e3948d03951f08f62e4a511b6ad | [
"MIT"
] | 7 | 2016-11-17T14:10:26.000Z | 2020-03-03T15:27:35.000Z | defmodule Ecto.Paging.TestSchema do
@moduledoc false
use Ecto.Schema
schema "apis" do
field :name, :string
embeds_one :request, Request, primary_key: false do
field :scheme, :string
field :host, :string
field :port, :integer
field :path, :string
end
timestamps()
end
en... | 19.554054 | 55 | 0.662751 |
1d5161d7da4338a6c2cfd531ab7c0827698ff240 | 1,153 | ex | Elixir | lib/real_world_web/views/article_view.ex | codefordenver/new-code-for-denver-site | af6cc232c898a197601b4d37e0cd217d0503fd9b | [
"MIT"
] | 1 | 2019-09-28T05:50:46.000Z | 2019-09-28T05:50:46.000Z | lib/real_world_web/views/article_view.ex | codefordenver/new-code-for-denver-site | af6cc232c898a197601b4d37e0cd217d0503fd9b | [
"MIT"
] | null | null | null | lib/real_world_web/views/article_view.ex | codefordenver/new-code-for-denver-site | af6cc232c898a197601b4d37e0cd217d0503fd9b | [
"MIT"
] | null | null | null | defmodule RealWorldWeb.ArticleView do
use RealWorldWeb, :view
alias RealWorldWeb.{ArticleView, FormatHelpers, UserView}
def render("index.json", %{articles: articles}) do
%{articles: render_many(articles, ArticleView, "article.json"),
articlesCount: length(articles)}
end
def render("show.json", %{... | 36.03125 | 134 | 0.701648 |
1d5163939e0daa7e0aa8ca6ab6f67e4d720e784a | 6,695 | ex | Elixir | test/support/hexpm.ex | starbelly/hex | d84d2558812c454fbc9c26eea3b25e7648d345f1 | [
"Apache-2.0"
] | 1 | 2019-04-29T12:35:49.000Z | 2019-04-29T12:35:49.000Z | test/support/hexpm.ex | starbelly/hex | d84d2558812c454fbc9c26eea3b25e7648d345f1 | [
"Apache-2.0"
] | null | null | null | test/support/hexpm.ex | starbelly/hex | d84d2558812c454fbc9c26eea3b25e7648d345f1 | [
"Apache-2.0"
] | null | null | null | defmodule HexTest.Hexpm do
import ExUnit.Assertions
defmodule WrappedCollectable do
defstruct [:collectable, :fun]
defimpl Collectable do
def into(%{collectable: collectable, fun: fun}) do
{term, collectable_fun} = Collectable.into(collectable)
{term, wrap(collectable_fun, fun)}
... | 24.888476 | 97 | 0.572367 |
1d5167f2e2d0c0276909f9517ac4429104641255 | 4,529 | ex | Elixir | clients/dialogflow/lib/google_api/dialogflow/v3/model/google_cloud_dialogflow_cx_v3_fulfillment.ex | yoshi-code-bot/elixir-google-api | cdb6032f01fac5ab704803113c39f2207e9e019d | [
"Apache-2.0"
] | null | null | null | clients/dialogflow/lib/google_api/dialogflow/v3/model/google_cloud_dialogflow_cx_v3_fulfillment.ex | yoshi-code-bot/elixir-google-api | cdb6032f01fac5ab704803113c39f2207e9e019d | [
"Apache-2.0"
] | null | null | null | clients/dialogflow/lib/google_api/dialogflow/v3/model/google_cloud_dialogflow_cx_v3_fulfillment.ex | yoshi-code-bot/elixir-google-api | cdb6032f01fac5ab704803113c39f2207e9e019d | [
"Apache-2.0"
] | null | null | null | # Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, s... | 53.916667 | 535 | 0.741886 |
1d516f4188a065615a5ebc618087f893183627bc | 491 | ex | Elixir | lib/sse_demo_web/views/error_view.ex | vjebelev/sse_demo | 2987ca57bd18fee11a179e9e75d114aa9b28feb9 | [
"MIT"
] | null | null | null | lib/sse_demo_web/views/error_view.ex | vjebelev/sse_demo | 2987ca57bd18fee11a179e9e75d114aa9b28feb9 | [
"MIT"
] | null | null | null | lib/sse_demo_web/views/error_view.ex | vjebelev/sse_demo | 2987ca57bd18fee11a179e9e75d114aa9b28feb9 | [
"MIT"
] | null | null | null | defmodule SseDemoWeb.ErrorView do
use SseDemoWeb, :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.882353 | 61 | 0.735234 |
1d51b23bbdeeca2f3fc23e8a21eea567673c949f | 132 | exs | Elixir | test/lib/opq/worker_supervisor_test.exs | gridgentoo/in-memory-queue | ff1d101b5b1083b6802f7dda909fd06bcf38c0d7 | [
"MIT"
] | 207 | 2017-08-14T12:14:11.000Z | 2022-03-06T23:39:21.000Z | test/lib/opq/worker_supervisor_test.exs | gridgentoo/in-memory-queue | ff1d101b5b1083b6802f7dda909fd06bcf38c0d7 | [
"MIT"
] | 9 | 2017-08-31T02:11:44.000Z | 2021-01-15T06:22:24.000Z | test/lib/opq/worker_supervisor_test.exs | gridgentoo/in-memory-queue | ff1d101b5b1083b6802f7dda909fd06bcf38c0d7 | [
"MIT"
] | 8 | 2017-08-21T04:53:10.000Z | 2022-02-19T13:20:43.000Z | defmodule OPQ.WorkerSupervisorTest do
use OPQ.TestCase, async: true
alias OPQ.WorkerSupervisor
doctest WorkerSupervisor
end
| 16.5 | 37 | 0.810606 |
1d522c94c452576bb9b008d555d57b5f0cd4e235 | 152 | ex | Elixir | apps/core/lib/core/validators/common.ex | ehealth-ua/ehealth.api | 4ffe26a464fe40c95fb841a4aa2e147068f65ca2 | [
"Apache-2.0"
] | 8 | 2019-06-14T11:34:49.000Z | 2021-08-05T19:14:24.000Z | apps/core/lib/core/validators/common.ex | edenlabllc/ehealth.api.public | 4ffe26a464fe40c95fb841a4aa2e147068f65ca2 | [
"Apache-2.0"
] | 1 | 2019-07-08T15:20:22.000Z | 2019-07-08T15:20:22.000Z | apps/core/lib/core/validators/common.ex | ehealth-ua/ehealth.api | 4ffe26a464fe40c95fb841a4aa2e147068f65ca2 | [
"Apache-2.0"
] | 6 | 2018-05-11T13:59:32.000Z | 2022-01-19T20:15:22.000Z | defmodule Core.Validators.Common do
@moduledoc false
def validate_equal(value, value, _), do: :ok
def validate_equal(_, _, error), do: error
end
| 21.714286 | 46 | 0.730263 |
1d5231149b713f79e299eaeb3e70c90a949c138a | 1,456 | exs | Elixir | test/unit/hologram/compiler/call_graph_builder/if_expression_test.exs | gregjohnsonsaltaire/hologram | aa8e9ea0d599def864c263cc37cc8ee31f02ac4a | [
"MIT"
] | 40 | 2022-01-19T20:27:36.000Z | 2022-03-31T18:17:41.000Z | test/unit/hologram/compiler/call_graph_builder/if_expression_test.exs | gregjohnsonsaltaire/hologram | aa8e9ea0d599def864c263cc37cc8ee31f02ac4a | [
"MIT"
] | 42 | 2022-02-03T22:52:43.000Z | 2022-03-26T20:57:32.000Z | test/unit/hologram/compiler/call_graph_builder/if_expression_test.exs | gregjohnsonsaltaire/hologram | aa8e9ea0d599def864c263cc37cc8ee31f02ac4a | [
"MIT"
] | 3 | 2022-02-10T04:00:37.000Z | 2022-03-08T22:07:45.000Z | defmodule Hologram.Compiler.CallGraphBuilder.IfExpressionTest do
use Hologram.Test.UnitCase, async: false
alias Hologram.Compiler.{CallGraph, CallGraphBuilder}
alias Hologram.Compiler.IR.{ModuleType, IfExpression, NilType}
alias Hologram.Test.Fixtures.{PlaceholderModule1, PlaceholderModule2}
@module_defs %{... | 26.472727 | 71 | 0.715659 |
1d523763afcb0605684e9f08648ffa7d48e1bf9d | 8,255 | exs | Elixir | apps/reaper/test/unit/reaper/event/event_handler_test.exs | smartcitiesdata/smartcitiesdata | c926c25003a8ee2d09b933c521c49f674841c0b6 | [
"Apache-2.0"
] | 26 | 2019-09-20T23:54:45.000Z | 2020-08-20T14:23:32.000Z | apps/reaper/test/unit/reaper/event/event_handler_test.exs | smartcitiesdata/smartcitiesdata | c926c25003a8ee2d09b933c521c49f674841c0b6 | [
"Apache-2.0"
] | 757 | 2019-08-15T18:15:07.000Z | 2020-09-18T20:55:31.000Z | apps/reaper/test/unit/reaper/event/event_handler_test.exs | smartcitiesdata/smartcitiesdata | c926c25003a8ee2d09b933c521c49f674841c0b6 | [
"Apache-2.0"
] | 9 | 2019-11-12T16:43:46.000Z | 2020-03-25T16:23:16.000Z | defmodule Reaper.Event.EventHandlerTest do
use ExUnit.Case
use Placebo
use Properties, otp_app: :reaper
require Logger
import SmartCity.Event,
only: [
data_ingest_start: 0,
data_extract_start: 0,
data_extract_end: 0,
ingestion_update: 0,
ingestion_delete: 0,
error_ing... | 40.665025 | 119 | 0.664688 |
1d528198b8416a7f32656169861e9dc654081b68 | 3,225 | ex | Elixir | aoc-2020/day8/lib/day8.ex | danurna/elixir-playground | 6acb40e513d8ab324368b3ec5151b0a4fd88f849 | [
"MIT"
] | null | null | null | aoc-2020/day8/lib/day8.ex | danurna/elixir-playground | 6acb40e513d8ab324368b3ec5151b0a4fd88f849 | [
"MIT"
] | null | null | null | aoc-2020/day8/lib/day8.ex | danurna/elixir-playground | 6acb40e513d8ab324368b3ec5151b0a4fd88f849 | [
"MIT"
] | null | null | null | defmodule Day8 do
def run_part1() do
AOCHelper.read_input()
|> Executor.supervised_execution()
end
def run_part2() do
AOCHelper.read_input()
|> Executor.mutating_execution()
end
def debug_sample() do
[
"nop +0",
"acc +1",
"jmp +4",
"acc +3",
"jmp -3",
... | 26.875 | 107 | 0.590078 |
1d528879dbc3e063cd94650f201088d80c4e83e7 | 1,471 | ex | Elixir | clients/double_click_bid_manager/lib/google_api/double_click_bid_manager/v1/model/report_failure.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/model/report_failure.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/model/report_failure.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... | 31.297872 | 112 | 0.743032 |
1d52a3978306b00cd119cb61ca54f85110a9f438 | 1,678 | ex | Elixir | apps/xee2018_web/lib/xee2018_web/endpoint.ex | RyoheiHayashi/xee2018 | 3b9ff03b13817563a5c7c75db1da360879a8a8d4 | [
"MIT"
] | 1 | 2018-09-05T10:31:50.000Z | 2018-09-05T10:31:50.000Z | apps/xee2018_web/lib/xee2018_web/endpoint.ex | RyoheiHayashi/xee2018 | 3b9ff03b13817563a5c7c75db1da360879a8a8d4 | [
"MIT"
] | null | null | null | apps/xee2018_web/lib/xee2018_web/endpoint.ex | RyoheiHayashi/xee2018 | 3b9ff03b13817563a5c7c75db1da360879a8a8d4 | [
"MIT"
] | null | null | null | defmodule Xee2018Web.Endpoint do
use Phoenix.Endpoint, otp_app: :xee2018_web
socket "/socket", Xee2018Web.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 Plug... | 28.931034 | 95 | 0.709774 |
1d52c2dcb5d8772c1a3846cb7e52080d6ee81334 | 961 | ex | Elixir | lib/livebook/notebook/cell.ex | benjreinhart/livebook | 0500ad5c6237167ce9769d8cc78fca360834f576 | [
"Apache-2.0"
] | null | null | null | lib/livebook/notebook/cell.ex | benjreinhart/livebook | 0500ad5c6237167ce9769d8cc78fca360834f576 | [
"Apache-2.0"
] | null | null | null | lib/livebook/notebook/cell.ex | benjreinhart/livebook | 0500ad5c6237167ce9769d8cc78fca360834f576 | [
"Apache-2.0"
] | null | null | null | defmodule Livebook.Notebook.Cell do
@moduledoc false
# Data structure representing a single cell in a notebook.
#
# A cell is the smallest unit of work in a notebook.
# It may consist of text content, outputs, rendered content
# and other special forms.
alias Livebook.Utils
alias Livebook.Notebook.Cel... | 25.972973 | 93 | 0.677419 |
1d52d002d7066cd2fd90155c0d99a4ded75347b6 | 2,029 | ex | Elixir | clients/sheets/lib/google_api/sheets/v4/model/candlestick_chart_spec.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/sheets/lib/google_api/sheets/v4/model/candlestick_chart_spec.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/sheets/lib/google_api/sheets/v4/model/candlestick_chart_spec.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... | 37.574074 | 166 | 0.737309 |
1d52d476932b3e1d825be8a4e4e1f53d69e3c77a | 2,786 | ex | Elixir | lib/job_queue/worker.ex | jeffutter/job_queue | ad390c5c780fb7a982e64edf9ca7a49c90bb5dd4 | [
"MIT"
] | 6 | 2017-11-21T08:35:10.000Z | 2019-02-07T15:58:31.000Z | lib/job_queue/worker.ex | jeffutter/job_queue | ad390c5c780fb7a982e64edf9ca7a49c90bb5dd4 | [
"MIT"
] | null | null | null | lib/job_queue/worker.ex | jeffutter/job_queue | ad390c5c780fb7a982e64edf9ca7a49c90bb5dd4 | [
"MIT"
] | null | null | null | defmodule JobQueue.Worker do
@moduledoc """
A behaviour and a module to handle some of the ceremony around a ConsumerSupervisor Worker.
## Example
iex> # Setup Worker
...> defmodule JobQueueWorker do
...> use JobQueue.Worker
...>
...> def handle_event(event) do
...> {:... | 27.313725 | 100 | 0.527279 |
1d52db8f12a6f0e9e344f15729940401c6f6ff2a | 243 | ex | Elixir | web/router.ex | philcallister/ticker-phoenix | 052fddec24de3b3e48a9513a0d3782f3c9227c81 | [
"MIT"
] | 15 | 2016-11-02T14:03:00.000Z | 2021-03-23T20:34:14.000Z | web/router.ex | philcallister/ticker-phoenix | 052fddec24de3b3e48a9513a0d3782f3c9227c81 | [
"MIT"
] | null | null | null | web/router.ex | philcallister/ticker-phoenix | 052fddec24de3b3e48a9513a0d3782f3c9227c81 | [
"MIT"
] | 2 | 2019-08-09T18:33:09.000Z | 2020-07-14T16:28:14.000Z | defmodule TickerPhoenix.Router do
use TickerPhoenix.Web, :router
pipeline :api do
plug :accepts, ["json"]
end
scope "/api", TickerPhoenix do
pipe_through :api
get "/quotes/:symbol/show", QuoteController, :show
end
end
| 17.357143 | 54 | 0.691358 |
1d52f81700172687663d2c3423ee10b89b534ba6 | 1,968 | exs | Elixir | test/phoenix/endpoint/adapter_test.exs | knewter/phoenix | 191909d97511ab99f9bbcc776cba9988c8b07596 | [
"MIT"
] | null | null | null | test/phoenix/endpoint/adapter_test.exs | knewter/phoenix | 191909d97511ab99f9bbcc776cba9988c8b07596 | [
"MIT"
] | null | null | null | test/phoenix/endpoint/adapter_test.exs | knewter/phoenix | 191909d97511ab99f9bbcc776cba9988c8b07596 | [
"MIT"
] | null | null | null | defmodule Phoenix.Endpoint.AdapterTest do
use ExUnit.Case, async: true
alias Phoenix.Endpoint.Adapter
setup do
config = [custom: true]
Application.put_env(:phoenix, AdapterApp.Endpoint, config)
:ok
end
test "loads router configuration" do
config = Adapter.config(:phoenix, AdapterApp.Endpoint... | 32.8 | 76 | 0.666667 |
1d52f837a85df32d9371f545fb1d809a046977bc | 1,561 | exs | Elixir | test/mmdb2_encoder/data_test.exs | elixir-geolix/mmdb2_encoder | 965f8e220eb0226310f9a5d84dfa120cfcc56524 | [
"Apache-2.0"
] | null | null | null | test/mmdb2_encoder/data_test.exs | elixir-geolix/mmdb2_encoder | 965f8e220eb0226310f9a5d84dfa120cfcc56524 | [
"Apache-2.0"
] | null | null | null | test/mmdb2_encoder/data_test.exs | elixir-geolix/mmdb2_encoder | 965f8e220eb0226310f9a5d84dfa120cfcc56524 | [
"Apache-2.0"
] | null | null | null | defmodule MMDB2Encoder.DataTest do
use ExUnit.Case, async: true
@autodetectables [
{"binary length 0", :binary, ""},
{"binary length 16", :binary, String.duplicate("x", 16)},
{"binary length 29", :binary, String.duplicate("x", 29)},
{"binary length 285", :binary, String.duplicate("x", 285)},
{"... | 37.166667 | 77 | 0.648943 |
1d5314f92962d62b76a4adcdfa4ebf3f5b21a1c5 | 1,367 | exs | Elixir | test/day_11_hex_ed_test.exs | scmx/advent-of-code-2017-elixir | 7435028bf7cd4d0c880144363aab2e3d80ab7ceb | [
"MIT"
] | 1 | 2018-11-26T11:34:41.000Z | 2018-11-26T11:34:41.000Z | test/day_11_hex_ed_test.exs | scmx/advent-of-code-2017-elixir | 7435028bf7cd4d0c880144363aab2e3d80ab7ceb | [
"MIT"
] | null | null | null | test/day_11_hex_ed_test.exs | scmx/advent-of-code-2017-elixir | 7435028bf7cd4d0c880144363aab2e3d80ab7ceb | [
"MIT"
] | 1 | 2018-01-23T08:12:26.000Z | 2018-01-23T08:12:26.000Z | defmodule Adventofcode.Day11HexEdTest do
use Adventofcode.FancyCase
import Adventofcode.Day11HexEd
describe "steps_away/1" do
test "ne,ne,ne is 3 steps away" do
assert 3 = "ne,ne,ne" |> steps_away()
end
test "ne,ne,sw,sw is 0 steps away (back where you started)" do
assert 0 = "ne,ne,sw,... | 25.314815 | 66 | 0.607169 |
1d534f7556508720eecbc2df5fcac5047673bd14 | 8,995 | exs | Elixir | test/mix/tasks/phx.gen.json_test.exs | sheharyarn/phoenix | 60fce56798cf074a784988ebedb97d17247e5d68 | [
"MIT"
] | 1 | 2019-04-24T09:28:15.000Z | 2019-04-24T09:28:15.000Z | test/mix/tasks/phx.gen.json_test.exs | sheharyarn/phoenix | 60fce56798cf074a784988ebedb97d17247e5d68 | [
"MIT"
] | null | null | null | test/mix/tasks/phx.gen.json_test.exs | sheharyarn/phoenix | 60fce56798cf074a784988ebedb97d17247e5d68 | [
"MIT"
] | null | null | null | Code.require_file "../../../installer/test/mix_helper.exs", __DIR__
defmodule Mix.Tasks.Phx.Gen.JsonTest do
use ExUnit.Case
import MixHelper
alias Mix.Tasks.Phx.Gen
setup do
Mix.Task.clear()
:ok
end
test "invalid mix arguments", config do
in_tmp_project config.test, fn ->
assert_raise M... | 36.714286 | 96 | 0.620678 |
1d536b5d3f171d3a2f2f75ba0dfabb5086b20287 | 1,813 | ex | Elixir | clients/monitoring/lib/google_api/monitoring/v3/model/create_collectd_time_series_response.ex | leandrocp/elixir-google-api | a86e46907f396d40aeff8668c3bd81662f44c71e | [
"Apache-2.0"
] | null | null | null | clients/monitoring/lib/google_api/monitoring/v3/model/create_collectd_time_series_response.ex | leandrocp/elixir-google-api | a86e46907f396d40aeff8668c3bd81662f44c71e | [
"Apache-2.0"
] | null | null | null | clients/monitoring/lib/google_api/monitoring/v3/model/create_collectd_time_series_response.ex | leandrocp/elixir-google-api | a86e46907f396d40aeff8668c3bd81662f44c71e | [
"Apache-2.0"
] | 1 | 2020-11-10T16:58:27.000Z | 2020-11-10T16:58:27.000Z | # Copyright 2017 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in... | 37.770833 | 222 | 0.771649 |
1d53925f11ccba48d3caf47ab8facca7171730f5 | 14,990 | ex | Elixir | lib/elixir/lib/supervisor.ex | sunaku/elixir | 8aa43eaedd76be8ac0d495049eb9ecd56971f4fe | [
"Apache-2.0"
] | null | null | null | lib/elixir/lib/supervisor.ex | sunaku/elixir | 8aa43eaedd76be8ac0d495049eb9ecd56971f4fe | [
"Apache-2.0"
] | null | null | null | lib/elixir/lib/supervisor.ex | sunaku/elixir | 8aa43eaedd76be8ac0d495049eb9ecd56971f4fe | [
"Apache-2.0"
] | 1 | 2020-12-07T08:04:16.000Z | 2020-12-07T08:04:16.000Z | defmodule Supervisor do
@moduledoc """
A behaviour module for implementing supervision functionality.
A supervisor is a process which supervises other processes called
child processes. Supervisors are used to build an hierarchical process
structure called a supervision tree, a nice way to structure fault-tol... | 38.435897 | 92 | 0.711875 |
1d539b4320dbbee4e70435bc3cb584c94fbbdf2a | 237 | ex | Elixir | test/examples/when.ex | narrowtux/loppers | 1dba8cece046e7ac1883bec8c663ce46e68a86d4 | [
"MIT"
] | 4 | 2018-12-07T10:52:37.000Z | 2021-01-22T21:31:10.000Z | test/examples/when.ex | narrowtux/loppers | 1dba8cece046e7ac1883bec8c663ce46e68a86d4 | [
"MIT"
] | 11 | 2017-11-29T12:01:05.000Z | 2020-03-04T09:42:32.000Z | test/examples/when.ex | narrowtux/loppers | 1dba8cece046e7ac1883bec8c663ce46e68a86d4 | [
"MIT"
] | 2 | 2017-11-29T12:00:37.000Z | 2019-04-16T12:43:04.000Z | defmodule When do
def foo(i) when is_integer(i) do
i + 3
end
def foo(i) do
case i do
i when is_binary(i) -> i <> "abc"
_ -> :error
end
bar(i)
end
def bar(i) when is_integer(i) do
:ok
end
end
| 13.166667 | 39 | 0.535865 |
1d53cb1b1461830a1304b0a400adc51a30c0c626 | 156 | ex | Elixir | lib/randomuser_ex/picture.ex | dreamingechoes/randomuser_ex | cfc72e015d2b110d2a4589bf6abb90793905c98c | [
"MIT"
] | 4 | 2017-08-16T18:14:29.000Z | 2020-01-14T03:19:54.000Z | lib/randomuser_ex/picture.ex | dreamingechoes/randomuser_ex | cfc72e015d2b110d2a4589bf6abb90793905c98c | [
"MIT"
] | null | null | null | lib/randomuser_ex/picture.ex | dreamingechoes/randomuser_ex | cfc72e015d2b110d2a4589bf6abb90793905c98c | [
"MIT"
] | null | null | null | defmodule RandomuserEx.Picture do
@moduledoc false
@derive [Poison.Encoder]
@type t :: %__MODULE__{}
defstruct [:large, :medium, :thumbnail]
end
| 15.6 | 41 | 0.705128 |
1d53db6afdf52604f5035f526e75819cab3ed78d | 192 | ex | Elixir | config.json.ex | ibarsi/developer-problems | 56c7e23ba8eb3097b514ac06523f1eadd2ed99a0 | [
"MIT"
] | 1 | 2017-07-04T20:48:22.000Z | 2017-07-04T20:48:22.000Z | config.json.ex | ibarsi/developer-problems | 56c7e23ba8eb3097b514ac06523f1eadd2ed99a0 | [
"MIT"
] | null | null | null | config.json.ex | ibarsi/developer-problems | 56c7e23ba8eb3097b514ac06523f1eadd2ed99a0 | [
"MIT"
] | null | null | null | {
"AUTH": {
"Twitter": {
"consumer_key": "",
"consumer_secret": "",
"access_token": "",
"access_token_secret": ""
}
}
}
| 17.454545 | 37 | 0.359375 |
1d53f29f7626593bb82f27569c34baad8a904918 | 1,264 | ex | Elixir | lib/postoffice/handlers/http.ex | IgorRodriguez/postoffice | 9012193e0780f2403bd3db90b8f6258656780fee | [
"Apache-2.0"
] | null | null | null | lib/postoffice/handlers/http.ex | IgorRodriguez/postoffice | 9012193e0780f2403bd3db90b8f6258656780fee | [
"Apache-2.0"
] | null | null | null | lib/postoffice/handlers/http.ex | IgorRodriguez/postoffice | 9012193e0780f2403bd3db90b8f6258656780fee | [
"Apache-2.0"
] | null | null | null | defmodule Postoffice.Handlers.Http do
use Task
require Logger
alias Postoffice.Messaging
def run(publisher_target, publisher_id, message) do
case impl().publish(publisher_target, message) do
{:ok, %HTTPoison.Response{status_code: status_code, body: _body}}
when status_code in 200..299 ->
... | 26.893617 | 96 | 0.639241 |
1d54071cea292eed09339580f27e37f87fe81d70 | 783 | ex | Elixir | solucoes/desafio_01/felipsimoes.ex | felipsimoes/elixir-study-group | 34af61c29cf3b98df1a3edfa7eab83788eeef8cd | [
"MIT"
] | 32 | 2017-12-13T15:37:12.000Z | 2021-03-08T13:37:40.000Z | solucoes/desafio_01/felipsimoes.ex | felipsimoes/elixir-study-group | 34af61c29cf3b98df1a3edfa7eab83788eeef8cd | [
"MIT"
] | 7 | 2018-03-01T09:37:30.000Z | 2018-08-29T00:16:12.000Z | solucoes/desafio_01/felipsimoes.ex | felipsimoes/elixir-study-group | 34af61c29cf3b98df1a3edfa7eab83788eeef8cd | [
"MIT"
] | 18 | 2017-12-29T23:56:35.000Z | 2019-01-23T17:44:59.000Z | # Construa um jogo de texto, em que o jogador tenha que adivinhar a palavra `elixir`.
# Ao rodar o jogo, o programa deve mostrar algumas dicas como `Poção mágica, liquido encantado em frasco.`
# O jogador só terá 1 tentativa, ou ele ganha o jogo ou perde.
# Se ele ganhar, uma mensagem de vitória deverá ser mostrada com... | 37.285714 | 106 | 0.706258 |
1d5414e8a1ff99478014a6824992545993df95d1 | 1,679 | ex | Elixir | lib/xdr/transactions/transaction_signature_payload_tagged_transaction.ex | einerzg/stellar_base | 2d10c5fc3b8159efc5de10b5c7c665e3b57b3d8f | [
"MIT"
] | 3 | 2021-08-17T20:32:45.000Z | 2022-03-13T20:26:02.000Z | lib/xdr/transactions/transaction_signature_payload_tagged_transaction.ex | einerzg/stellar_base | 2d10c5fc3b8159efc5de10b5c7c665e3b57b3d8f | [
"MIT"
] | 45 | 2021-08-12T20:19:41.000Z | 2022-03-27T21:00:10.000Z | lib/xdr/transactions/transaction_signature_payload_tagged_transaction.ex | einerzg/stellar_base | 2d10c5fc3b8159efc5de10b5c7c665e3b57b3d8f | [
"MIT"
] | 2 | 2021-09-22T23:11:13.000Z | 2022-01-23T03:19:11.000Z | defmodule StellarBase.XDR.TransactionSignaturePayloadTaggedTransaction do
@moduledoc """
Representation of Stellar `TransactionSignaturePayloadTaggedTransaction` type.
"""
alias StellarBase.XDR.{EnvelopeType, Transaction, FeeBumpTransaction}
@behaviour XDR.Declaration
@arms [
ENVELOPE_TYPE_TX: Transac... | 26.650794 | 81 | 0.685527 |
1d54228f51b75d12de16d0a37b8af021af13a8dc | 819 | ex | Elixir | lib/platform/slides/slide_api.ex | lucab85/audioslides.io | cb502ccf6ed0b2db42d9fb20bb4c963bcca3cfa9 | [
"MIT"
] | 17 | 2017-11-14T14:03:18.000Z | 2021-12-10T04:18:48.000Z | lib/platform/slides/slide_api.ex | lucab85/audioslides.io | cb502ccf6ed0b2db42d9fb20bb4c963bcca3cfa9 | [
"MIT"
] | 21 | 2017-11-19T13:38:07.000Z | 2022-02-10T00:11:14.000Z | lib/platform/slides/slide_api.ex | lucab85/audioslides.io | cb502ccf6ed0b2db42d9fb20bb4c963bcca3cfa9 | [
"MIT"
] | 2 | 2019-09-03T03:32:13.000Z | 2021-02-23T21:52:57.000Z | defmodule Platform.SlideAPI do
@moduledoc """
Context for the general converter
"""
@doc """
Get a presentation from the api
"""
@callback get_presentation(String.t()) :: {:ok, String.t()} | {:error, String.t()}
@doc """
Get a slide from the api
"""
@callback get_slide!(String.t(), String.t())... | 19.5 | 84 | 0.59707 |
1d54234e260711d0db9a54294451a06a3638c908 | 97 | ex | Elixir | test_basic/oof_test.ex | maxbeizer/test_oof | 1a8a5986aa399c68f74dc50c0ef1c1a49114fa2c | [
"MIT"
] | null | null | null | test_basic/oof_test.ex | maxbeizer/test_oof | 1a8a5986aa399c68f74dc50c0ef1c1a49114fa2c | [
"MIT"
] | null | null | null | test_basic/oof_test.ex | maxbeizer/test_oof | 1a8a5986aa399c68f74dc50c0ef1c1a49114fa2c | [
"MIT"
] | null | null | null | defmodule OofTestTest do
use ExUnit.Case
test "what is truth?" do
assert true
end
end
| 12.125 | 26 | 0.701031 |
1d5439ea30b22205ce40a7935b3a4302585f3d83 | 1,476 | ex | Elixir | lib/context_web/views/error_helpers.ex | hotpyn/context-demo | 304c767be93f8dec75ef8ec97d13e5e90352a47d | [
"MIT"
] | null | null | null | lib/context_web/views/error_helpers.ex | hotpyn/context-demo | 304c767be93f8dec75ef8ec97d13e5e90352a47d | [
"MIT"
] | null | null | null | lib/context_web/views/error_helpers.ex | hotpyn/context-demo | 304c767be93f8dec75ef8ec97d13e5e90352a47d | [
"MIT"
] | null | null | null | defmodule ContextWeb.ErrorHelpers do
@moduledoc """
Conveniences for translating and building error messages.
"""
use Phoenix.HTML
@doc """
Generates tag for inlined form input errors.
"""
def error_tag(form, field) do
Enum.map(Keyword.get_values(form.errors, field), fn (error) ->
content_ta... | 32.8 | 76 | 0.670732 |
1d543ea2605e757d5854987902a3cc6e3f02d264 | 374 | ex | Elixir | apps/firestorm_data/lib/firestorm_data/application.ex | CircleCI-Public/firestorm | 9ca2c46a2b2377370347ad94d6003eeb77be38d6 | [
"MIT"
] | 10 | 2017-06-28T08:06:52.000Z | 2022-03-19T17:49:21.000Z | apps/firestorm_data/lib/firestorm_data/application.ex | CircleCI-Public/firestorm | 9ca2c46a2b2377370347ad94d6003eeb77be38d6 | [
"MIT"
] | null | null | null | apps/firestorm_data/lib/firestorm_data/application.ex | CircleCI-Public/firestorm | 9ca2c46a2b2377370347ad94d6003eeb77be38d6 | [
"MIT"
] | 2 | 2017-10-21T12:01:02.000Z | 2021-01-29T10:26:22.000Z | defmodule FirestormData.Application do
@moduledoc false
use Application
def start(_type, _args) do
import Supervisor.Spec, warn: false
children = [
supervisor(FirestormData.Repo, []),
worker(FirestormData.Events, []),
]
opts = [strategy: :one_for_one, name: FirestormData.Supervisor... | 20.777778 | 67 | 0.695187 |
1d54681514a4a54e5a582f2e11e2c8e7c976b096 | 990 | ex | Elixir | lib/inmana_web/views/error_view.ex | marciorasf/next-level-week-5-Elixir | 5af63fcf04202111db22209f61928772dbb167ad | [
"MIT"
] | 14 | 2021-04-26T14:19:28.000Z | 2021-09-12T03:29:42.000Z | lib/inmana_web/views/error_view.ex | marciorasf/next-level-week-5-Elixir | 5af63fcf04202111db22209f61928772dbb167ad | [
"MIT"
] | null | null | null | lib/inmana_web/views/error_view.ex | marciorasf/next-level-week-5-Elixir | 5af63fcf04202111db22209f61928772dbb167ad | [
"MIT"
] | 6 | 2021-04-27T12:41:16.000Z | 2021-07-02T04:11:53.000Z | defmodule InmanaWeb.ErrorView do
use InmanaWeb, :view
alias Ecto.Changeset
# If you want to customize a particular status code
# for a certain format, you may uncomment below.
# def render("500.json", _assigns) do
# %{errors: %{detail: "Internal Server Error"}}
# end
# By default, Phoenix returns t... | 28.285714 | 83 | 0.679798 |
1d549cf4f5bfd016be86ba89f1cea174c2ee6351 | 1,214 | exs | Elixir | apps/omg_watcher_rpc/mix.exs | karmonezz/elixir-omg | 3b26fc072fa553992277e1b9c4bad37b3d61ec6a | [
"Apache-2.0"
] | 1 | 2020-05-01T12:30:09.000Z | 2020-05-01T12:30:09.000Z | apps/omg_watcher_rpc/mix.exs | karmonezz/elixir-omg | 3b26fc072fa553992277e1b9c4bad37b3d61ec6a | [
"Apache-2.0"
] | null | null | null | apps/omg_watcher_rpc/mix.exs | karmonezz/elixir-omg | 3b26fc072fa553992277e1b9c4bad37b3d61ec6a | [
"Apache-2.0"
] | null | null | null | defmodule OMG.WatcherRPC.Mixfile do
use Mix.Project
def project do
[
app: :omg_watcher_rpc,
version: "#{String.trim(File.read!("../../VERSION"))}",
build_path: "../../_build",
config_path: "../../config/config.exs",
deps_path: "../../deps",
lockfile: "../../mix.lock",
... | 25.829787 | 63 | 0.558484 |
1d54bcdd57b9aa1f3911e179067cbeb04619417e | 7,624 | exs | Elixir | test/lib/deli/controller/bin_test.exs | rodrigues/deli | a5bdb3df6eb2a943069fa2e4658493f90730bd90 | [
"MIT"
] | 4 | 2019-01-30T11:51:44.000Z | 2019-10-14T02:38:26.000Z | test/lib/deli/controller/bin_test.exs | rodrigues/deli | a5bdb3df6eb2a943069fa2e4658493f90730bd90 | [
"MIT"
] | null | null | null | test/lib/deli/controller/bin_test.exs | rodrigues/deli | a5bdb3df6eb2a943069fa2e4658493f90730bd90 | [
"MIT"
] | null | null | null | defmodule Deli.Controller.BinTest do
use DeliCase, async: true
alias Deli.Controller.Bin
setup do
put_config(:__system_handler__, SystemStub)
end
def nok_signal do
2..500 |> integer() |> except(&(&1 == 127))
end
describe "start_host/2" do
property "starts host" do
check all app_user <... | 24.996721 | 67 | 0.481506 |
1d5513100ca233b767e8d6d5821e7181df13f8a9 | 1,569 | ex | Elixir | lib/twitter.ex | gabrielelana/twitter-kata | eb0406a64b208dd4e078a844e51ab719b0944f42 | [
"MIT"
] | 2 | 2015-07-19T21:33:15.000Z | 2015-07-23T10:26:23.000Z | lib/twitter.ex | gabrielelana/twitter-kata | eb0406a64b208dd4e078a844e51ab719b0944f42 | [
"MIT"
] | null | null | null | lib/twitter.ex | gabrielelana/twitter-kata | eb0406a64b208dd4e078a844e51ab719b0944f42 | [
"MIT"
] | null | null | null | defmodule Twitter do
@moduledoc """
Implements a console-based social networking application similar to Twitter
"""
alias Twitter.User
alias Twitter.Message
alias Twitter.Command
@doc """
Starts the interactive shell
"""
@spec main([String.t]) :: any
def main(_args) do
explain_how_to_leave
... | 21.791667 | 77 | 0.614404 |
1d552ebd1682dbd710fbf61340f73a9b4bc06510 | 17,654 | ex | Elixir | lib/elixir/lib/code.ex | jbcrail/elixir | f30ef15d9d028a6d0f74d10c2bb320d5f8501bdb | [
"Apache-2.0"
] | 1 | 2015-02-23T00:01:48.000Z | 2015-02-23T00:01:48.000Z | lib/elixir/lib/code.ex | jbcrail/elixir | f30ef15d9d028a6d0f74d10c2bb320d5f8501bdb | [
"Apache-2.0"
] | null | null | null | lib/elixir/lib/code.ex | jbcrail/elixir | f30ef15d9d028a6d0f74d10c2bb320d5f8501bdb | [
"Apache-2.0"
] | null | null | null | defmodule Code do
@moduledoc """
Utilities for managing code compilation, code evaluation and code loading.
This module complements [Erlang's code module](http://www.erlang.org/doc/man/code.html)
to add behaviour which is specific to Elixir.
"""
@doc """
List all loaded files.
"""
def loaded_files d... | 31.581395 | 110 | 0.682905 |
1d55f83ed5aebf225716d2c1186301ec426ed428 | 1,108 | ex | Elixir | lib/wabanex_web/schema/types/custom/uuid4.ex | igormotta92/elixir_nlw_wabanex | d63a0d4c664d1909268a6127f108b636a3b46781 | [
"MIT"
] | null | null | null | lib/wabanex_web/schema/types/custom/uuid4.ex | igormotta92/elixir_nlw_wabanex | d63a0d4c664d1909268a6127f108b636a3b46781 | [
"MIT"
] | null | null | null | lib/wabanex_web/schema/types/custom/uuid4.ex | igormotta92/elixir_nlw_wabanex | d63a0d4c664d1909268a6127f108b636a3b46781 | [
"MIT"
] | null | null | null | # Criando tipo customizado de UUID4 no "absinthe-graphql"
# https://github.com/absinthe-graphql/absinthe/wiki/Scalar-Recipes
defmodule WabanexWeb.Schema.Types.Custom.UUID4 do
@moduledoc """
The UUID4 scalar type allows UUID4 compliant strings to be passed in and out.
Requires `{ :ecto, ">= 0.0.0" }` package: htt... | 27.7 | 88 | 0.694946 |
1d5684febc9a0b4655cec7f1f91d1912ade552f8 | 409 | ex | Elixir | lib/list.ex | adept-bits/adept | 214f71e1a5712f015def2068ee529e67cd970dac | [
"Apache-2.0"
] | 1 | 2022-01-06T08:24:23.000Z | 2022-01-06T08:24:23.000Z | lib/list.ex | adept-bits/adept | 214f71e1a5712f015def2068ee529e67cd970dac | [
"Apache-2.0"
] | null | null | null | lib/list.ex | adept-bits/adept | 214f71e1a5712f015def2068ee529e67cd970dac | [
"Apache-2.0"
] | null | null | null | defmodule Adept.List do
# generate a list of arbirary length randomly chosen from source
def random( source, 0 ) when is_list(source), do: []
def random( source, len ) when len > 0 and is_list(source) do
do_random( len, source, [] )
end
defp do_random( 0, _source, out ), do: out
defp do_random( len, so... | 29.214286 | 66 | 0.667482 |
1d56b5099831ce69deb4eb293b61b503d59a5b45 | 6,531 | exs | Elixir | apps/jsonrpc2/test/jsonrpc2/response/block_test.exs | wolflee/mana | db66dac85addfaad98d40da5bd4082b3a0198bb1 | [
"ECL-2.0",
"Apache-2.0",
"MIT-0",
"MIT"
] | 152 | 2018-10-27T04:52:03.000Z | 2022-03-26T10:34:00.000Z | apps/jsonrpc2/test/jsonrpc2/response/block_test.exs | wolflee/mana | db66dac85addfaad98d40da5bd4082b3a0198bb1 | [
"ECL-2.0",
"Apache-2.0",
"MIT-0",
"MIT"
] | 270 | 2018-04-14T07:34:57.000Z | 2018-10-25T18:10:45.000Z | apps/jsonrpc2/test/jsonrpc2/response/block_test.exs | wolflee/mana | db66dac85addfaad98d40da5bd4082b3a0198bb1 | [
"ECL-2.0",
"Apache-2.0",
"MIT-0",
"MIT"
] | 25 | 2018-10-27T12:15:13.000Z | 2022-01-25T20:31:14.000Z | defmodule JSONRPC2.Response.BlockTest do
use ExUnit.Case, async: true
alias JSONRPC2.Response.Block
alias JSONRPC2.TestFactory
describe "new/1" do
test "creates response block from internal block" do
internal_block = TestFactory.build(:block)
response_block = Block.new(internal_block, false)
... | 53.975207 | 1,363 | 0.698362 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.