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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
e8541d0be059291ec2bfeb77903f2ebc10bebbaa | 136 | ex | Elixir | lib/absinthe_websocket/subscriber.ex | karlosmid/absinthe_websocket | b08e0cf07c1dcdbb98e14c3905d8ee7b777aee66 | [
"MIT"
] | 8 | 2018-07-13T20:54:53.000Z | 2020-03-07T08:27:11.000Z | lib/absinthe_websocket/subscriber.ex | karlosmid/absinthe_websocket | b08e0cf07c1dcdbb98e14c3905d8ee7b777aee66 | [
"MIT"
] | 10 | 2018-07-13T15:29:19.000Z | 2019-12-04T18:58:15.000Z | lib/absinthe_websocket/subscriber.ex | karlosmid/absinthe_websocket | b08e0cf07c1dcdbb98e14c3905d8ee7b777aee66 | [
"MIT"
] | 3 | 2018-11-28T19:53:45.000Z | 2021-12-17T15:47:10.000Z | defmodule AbsintheWebSocket.Subscriber do
@callback subscribe() :: no_return()
# @callback receive(atom(), any) :: no_return()
end
| 22.666667 | 49 | 0.720588 |
e85458071c3ae2ab22908a81721c93f6ccb7bbca | 2,664 | ex | Elixir | lib/fusion/udp_tunnel.ex | elpddev/fusion | 7106ba4922786e1d79310074e46e6996d0c2f4aa | [
"MIT"
] | 2 | 2020-02-02T20:22:28.000Z | 2020-12-10T18:25:03.000Z | lib/fusion/udp_tunnel.ex | elpddev/fusion | 7106ba4922786e1d79310074e46e6996d0c2f4aa | [
"MIT"
] | null | null | null | lib/fusion/udp_tunnel.ex | elpddev/fusion | 7106ba4922786e1d79310074e46e6996d0c2f4aa | [
"MIT"
] | null | null | null | defmodule Fusion.UdpTunnel do
@moduledoc """
A GenServer for handling of opening udp tunnel network and observing their state.
"""
alias Fusion.UdpTunnel
alias Fusion.Utilities.Ssh
alias Fusion.Utilities.Exec
alias Fusion.Net.Spot
alias Fusion.Net
alias Fusion.PortRelay
defstruct status: :off,
... | 27.75 | 97 | 0.673423 |
e85461fafc6c347389634d13a33b570d3faf9fa1 | 3,672 | ex | Elixir | implementations/elixir/ockam/ockam/lib/ockam/stream/index/worker.ex | L3pereira/ockam | f53336ec673eb137876551c240e31fae741ef0f9 | [
"Apache-2.0"
] | null | null | null | implementations/elixir/ockam/ockam/lib/ockam/stream/index/worker.ex | L3pereira/ockam | f53336ec673eb137876551c240e31fae741ef0f9 | [
"Apache-2.0"
] | null | null | null | implementations/elixir/ockam/ockam/lib/ockam/stream/index/worker.ex | L3pereira/ockam | f53336ec673eb137876551c240e31fae741ef0f9 | [
"Apache-2.0"
] | null | null | null | defmodule Ockam.Stream.Index.Worker do
@moduledoc false
use Ockam.Protocol.Mapping
use Ockam.Worker
require Logger
@default_mod Ockam.Stream.Index.Storage.Internal
@protocol Ockam.Protocol.Stream.Index
@partitioned_protocol Ockam.Protocol.Stream.Partitioned.Index
@protocol_mapping Ockam.Protocol.Map... | 31.930435 | 93 | 0.670479 |
e854768e971cd8ebef781aff276f0182fbcc8d6a | 2,103 | ex | Elixir | clients/cloud_resource_manager/lib/google_api/cloud_resource_manager/v2/model/folder_operation.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/cloud_resource_manager/lib/google_api/cloud_resource_manager/v2/model/folder_operation.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/cloud_resource_manager/lib/google_api/cloud_resource_manager/v2/model/folder_operation.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... | 36.258621 | 137 | 0.718497 |
e8549723f62b0bd89310274b23f1844d5aaab252 | 138 | exs | Elixir | implementations/elixir/ockam/ockam_transport_udp/test/test_helper.exs | digikata/ockam | 015a834ce0d34921b634439d965f726d877fd076 | [
"Apache-2.0"
] | null | null | null | implementations/elixir/ockam/ockam_transport_udp/test/test_helper.exs | digikata/ockam | 015a834ce0d34921b634439d965f726d877fd076 | [
"Apache-2.0"
] | null | null | null | implementations/elixir/ockam/ockam_transport_udp/test/test_helper.exs | digikata/ockam | 015a834ce0d34921b634439d965f726d877fd076 | [
"Apache-2.0"
] | null | null | null | Application.ensure_all_started(:ockam)
Application.ensure_all_started(:ockam_transport_udp)
ExUnit.start(capture_log: true, trace: true)
| 27.6 | 52 | 0.847826 |
e854af544d6ec1c3b81dc645253f954a5f37bfc4 | 1,267 | exs | Elixir | mix.exs | DataKrewTech/tirexs | 8238da373f4547d27eea57a10826114e947aa66b | [
"Apache-2.0"
] | null | null | null | mix.exs | DataKrewTech/tirexs | 8238da373f4547d27eea57a10826114e947aa66b | [
"Apache-2.0"
] | null | null | null | mix.exs | DataKrewTech/tirexs | 8238da373f4547d27eea57a10826114e947aa66b | [
"Apache-2.0"
] | 1 | 2021-05-11T22:35:50.000Z | 2021-05-11T22:35:50.000Z | defmodule Tirexs.Mixfile do
use Mix.Project
def project do
[
app: :tirexs,
name: "Tirexs",
version: "0.8.16",
source_url: github(),
homepage_url: github(),
elixir: ">= 1.3.0",
description: description(),
package: package(),
deps: deps(),
docs: [extras... | 25.857143 | 134 | 0.597474 |
e854b467b917555770759f81096952b21544db92 | 1,576 | ex | Elixir | lib/realworld_phoenix_web/views/error_helpers.ex | tamanugi/realworld-phoenix | 1c0f90234926550a9124863b3946934b8f2e19a4 | [
"MIT"
] | 9 | 2021-08-23T23:21:31.000Z | 2022-03-27T23:19:55.000Z | lib/realworld_phoenix_web/views/error_helpers.ex | tamanugi/realworld-phoenix | 1c0f90234926550a9124863b3946934b8f2e19a4 | [
"MIT"
] | null | null | null | lib/realworld_phoenix_web/views/error_helpers.ex | tamanugi/realworld-phoenix | 1c0f90234926550a9124863b3946934b8f2e19a4 | [
"MIT"
] | 1 | 2021-09-06T07:26:37.000Z | 2021-09-06T07:26:37.000Z | defmodule RealworldPhoenixWeb.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 ->
con... | 32.833333 | 85 | 0.67132 |
e854bbe43024d6f817335cecb020f759c2527a7b | 358 | exs | Elixir | priv/repo/seeds.exs | jespr/ex_blog_example | 0a014d4b88b224210a7e15d7c60521aff05059c9 | [
"Unlicense"
] | null | null | null | priv/repo/seeds.exs | jespr/ex_blog_example | 0a014d4b88b224210a7e15d7c60521aff05059c9 | [
"Unlicense"
] | null | null | null | priv/repo/seeds.exs | jespr/ex_blog_example | 0a014d4b88b224210a7e15d7c60521aff05059c9 | [
"Unlicense"
] | null | null | null | # Script for populating the database. You can run it as:
#
# mix run priv/repo/seeds.exs
#
# Inside the script, you can read and write to any of your
# repositories directly:
#
# BlogExample.Repo.insert!(%BlogExample.SomeModel{})
#
# We recommend using the bang functions (`insert!`, `update!`
# and so on) as th... | 29.833333 | 61 | 0.712291 |
e854c46c1ea629f7fda5b9191296da3353d70ec0 | 60 | ex | Elixir | apps/voyager/lib/voyager_web/views/faq_view.ex | msk-access/seqosystem | 4d99c50a0b0bc74c7f9f899be4eda8eddf6e5a39 | [
"Apache-2.0"
] | 3 | 2020-11-24T07:45:26.000Z | 2021-07-29T13:37:02.000Z | apps/voyager/lib/voyager_web/views/faq_view.ex | mskcc/seqosystem | 4d99c50a0b0bc74c7f9f899be4eda8eddf6e5a39 | [
"Apache-2.0"
] | 52 | 2020-10-21T19:47:59.000Z | 2021-09-09T18:42:33.000Z | apps/voyager/lib/voyager_web/views/faq_view.ex | msk-access/seqosystem | 4d99c50a0b0bc74c7f9f899be4eda8eddf6e5a39 | [
"Apache-2.0"
] | 1 | 2020-12-15T03:33:31.000Z | 2020-12-15T03:33:31.000Z | defmodule VoyagerWeb.FaqView do
use VoyagerWeb, :view
end
| 15 | 31 | 0.8 |
e854efb7994d7c0f9cb8127e3463e27c82a30a0c | 182 | exs | Elixir | priv/repo/migrations/20190208150347_add_repositories_organization_id_index.exs | Benjamin-Philip/hexpm | 6f38244f81bbabd234c660f46ea973849ba77a7f | [
"Apache-2.0"
] | 691 | 2017-03-08T09:15:45.000Z | 2022-03-23T22:04:47.000Z | priv/repo/migrations/20190208150347_add_repositories_organization_id_index.exs | Benjamin-Philip/hexpm | 6f38244f81bbabd234c660f46ea973849ba77a7f | [
"Apache-2.0"
] | 491 | 2017-03-07T12:58:42.000Z | 2022-03-29T23:32:54.000Z | priv/repo/migrations/20190208150347_add_repositories_organization_id_index.exs | Benjamin-Philip/hexpm | 6f38244f81bbabd234c660f46ea973849ba77a7f | [
"Apache-2.0"
] | 200 | 2017-03-12T23:03:39.000Z | 2022-03-05T17:55:52.000Z | defmodule Hexpm.RepoBase.Migrations.AddRepositoriesOrganizationIdIndex do
use Ecto.Migration
def change do
create(unique_index(:repositories, [:organization_id]))
end
end
| 22.75 | 73 | 0.802198 |
e854f17c51eaba7bb2b05b4cbebbba2b3da8617f | 425 | ex | Elixir | elixir/concurrency-model/state-actor/counter3.ex | lijiansong/lang | e255709da2b12e09dea45f86d54f77a19b96f13b | [
"WTFPL"
] | 1 | 2020-01-09T03:22:09.000Z | 2020-01-09T03:22:09.000Z | elixir/concurrency-model/state-actor/counter3.ex | lijiansong/lang | e255709da2b12e09dea45f86d54f77a19b96f13b | [
"WTFPL"
] | null | null | null | elixir/concurrency-model/state-actor/counter3.ex | lijiansong/lang | e255709da2b12e09dea45f86d54f77a19b96f13b | [
"WTFPL"
] | null | null | null | defmodule Counter do
def loop(count) do
receive do
{:next, sender, ref} ->
send(sender, {:ok, ref, count})
loop(count + 1)
end
end
def start(count) do
pid = spawn(__MODULE__, :loop, [count])
Process.register(pid, :counter)
pid
end
def next do
ref = make_ref()
... | 18.478261 | 43 | 0.56 |
e855196328a9a90b4df893e92e0b1b0dd876072a | 625 | ex | Elixir | lib/exscript/transformers/comprehensions.ex | craigspaeth/exscript | c3a24790dff0eac592060ba3ae349be7c567e0a7 | [
"MIT"
] | 1 | 2017-12-15T23:55:05.000Z | 2017-12-15T23:55:05.000Z | lib/exscript/transformers/comprehensions.ex | craigspaeth/exscript | c3a24790dff0eac592060ba3ae349be7c567e0a7 | [
"MIT"
] | null | null | null | lib/exscript/transformers/comprehensions.ex | craigspaeth/exscript | c3a24790dff0eac592060ba3ae349be7c567e0a7 | [
"MIT"
] | null | null | null | defmodule ExScript.Transformers.Comprehensions do
@moduledoc """
Transforms module (and module-related) Elixir ASTs to ESTree JSON
"""
alias ExScript.Compile, as: Compile
alias ExScript.Common, as: Common
def transform_comprehension({_, _, for_ast}) do
[{_, _, [left, enum]}, [do: block]] = for_ast
... | 24.038462 | 68 | 0.6048 |
e85538bf4dfc372ecbdd10a7533e36513dd33e47 | 586 | exs | Elixir | test/speech_markdown/extended_cases_test.exs | pylon/speechmarkdown-ex | 6305d16f82955e4e74b54bf8c7724bc2e6668659 | [
"Apache-2.0"
] | 4 | 2020-05-21T06:30:47.000Z | 2021-04-19T18:12:25.000Z | test/speech_markdown/extended_cases_test.exs | pylon/speechmarkdown-ex | 6305d16f82955e4e74b54bf8c7724bc2e6668659 | [
"Apache-2.0"
] | 3 | 2020-01-31T21:12:29.000Z | 2020-06-26T08:48:33.000Z | test/speech_markdown/extended_cases_test.exs | pylon/speechmarkdown-ex | 6305d16f82955e4e74b54bf8c7724bc2e6668659 | [
"Apache-2.0"
] | 2 | 2020-02-02T11:11:47.000Z | 2021-09-21T15:21:42.000Z | defmodule SpeechMarkdowntendedCasesTests do
use ExUnit.Case, async: true
import SpeechMarkdown, only: [to_ssml: 2, to_plaintext: 1]
import SpeechMarkdown.TestSupport.FixtureHelper
# out-of-spec SMD cases
@cases [
# SSML mark
{"$[a]", "<speak><mark name=\"a\" /></speak>", ""}
]
for {smd, ssml, ... | 24.416667 | 69 | 0.636519 |
e8553b1f1215254c62655a76cf43e99a08e4d243 | 2,974 | exs | Elixir | test/mix/tasks/phx.gen.channel_test.exs | blunckr/fenix | aeccae9658ed3d85d8af8f28ce2584d407b43d6b | [
"MIT"
] | null | null | null | test/mix/tasks/phx.gen.channel_test.exs | blunckr/fenix | aeccae9658ed3d85d8af8f28ce2584d407b43d6b | [
"MIT"
] | null | null | null | test/mix/tasks/phx.gen.channel_test.exs | blunckr/fenix | aeccae9658ed3d85d8af8f28ce2584d407b43d6b | [
"MIT"
] | null | null | null | Code.require_file "../../../installer/test/mix_helper.exs", __DIR__
defmodule Phoenix.Web.DupChannel do
end
defmodule Mix.Tasks.Phx.Gen.ChannelTest do
use ExUnit.Case
import MixHelper
alias Mix.Tasks.Phx.Gen
setup do
Mix.Task.clear()
:ok
end
test "generates channel" do
in_tmp_project "genera... | 33.41573 | 83 | 0.629455 |
e8555892b6b60ea5b748ff10d18a3e6a1fc69c80 | 445 | ex | Elixir | lib/hl7/2.3/segments/loc.ex | calvinb/elixir-hl7 | 5e953fa11f9184857c0ec4dda8662889f35a6bec | [
"Apache-2.0"
] | null | null | null | lib/hl7/2.3/segments/loc.ex | calvinb/elixir-hl7 | 5e953fa11f9184857c0ec4dda8662889f35a6bec | [
"Apache-2.0"
] | null | null | null | lib/hl7/2.3/segments/loc.ex | calvinb/elixir-hl7 | 5e953fa11f9184857c0ec4dda8662889f35a6bec | [
"Apache-2.0"
] | null | null | null | defmodule HL7.V2_3.Segments.LOC do
@moduledoc false
require Logger
alias HL7.V2_3.{DataTypes}
use HL7.Segment,
fields: [
segment: nil,
primary_key_value: DataTypes.Pl,
location_description: nil,
location_type: nil,
organization_name: DataTypes.Xon,
location_address: Dat... | 22.25 | 39 | 0.685393 |
e85566093dd21171053aca1be01158793d69ac67 | 504 | exs | Elixir | lib/keywords_maps.exs | wasnotrice/elixir_intro | 9f4085478400d43cc5c432f6b0684af6f6f47861 | [
"Apache-2.0"
] | null | null | null | lib/keywords_maps.exs | wasnotrice/elixir_intro | 9f4085478400d43cc5c432f6b0684af6f6f47861 | [
"Apache-2.0"
] | null | null | null | lib/keywords_maps.exs | wasnotrice/elixir_intro | 9f4085478400d43cc5c432f6b0684af6f6f47861 | [
"Apache-2.0"
] | null | null | null | [a: "a", b: "b", c: "c", a: "A"]
[{:a, "a"}, {:b, "b"}, {:c, "c"}, {:a, "A"}]
%{a: "a", b: "b", c: "c", a: "A"}
%{"a" => "a", "b" => "b", "c" => "c", "a" => "A"}
%{1 => "a", [] => "b", :three => "c", "four" => "A"}
# Reading values
map.a
map[:a]
Map.get(map, :a)
Map.fetch(map, :a)
Map.fetch!(map, :a)
# "Modifying" a... | 24 | 54 | 0.444444 |
e855ce7d213ea66f56256598fcff95fdf5bc3d60 | 1,482 | exs | Elixir | test/rendering/tag_test.exs | thepeoplesbourgeois/slime | 55c4d738632ed6540a0a03e0a4022b02e398c2d9 | [
"MIT"
] | 312 | 2015-12-28T05:25:47.000Z | 2022-02-16T05:18:16.000Z | test/rendering/tag_test.exs | thepeoplesbourgeois/slime | 55c4d738632ed6540a0a03e0a4022b02e398c2d9 | [
"MIT"
] | 105 | 2015-12-27T21:20:58.000Z | 2022-02-24T05:23:38.000Z | test/rendering/tag_test.exs | thepeoplesbourgeois/slime | 55c4d738632ed6540a0a03e0a4022b02e398c2d9 | [
"MIT"
] | 45 | 2016-01-12T04:02:01.000Z | 2021-09-14T16:19:18.000Z | defmodule TagTest do
use ExUnit.Case, async: true
import Slime, only: [render: 1, render: 2]
test "dashed-strings can be used as tags" do
assert render(~s(my-component text)) == ~s(<my-component>text</my-component>)
end
test "render nested tags" do
slime = """
#id.class
p Hello World
... | 27.444444 | 100 | 0.616734 |
e855dcbbad49570c1120f31f0caaa85894ea53f1 | 81,604 | ex | Elixir | clients/real_time_bidding/lib/google_api/real_time_bidding/v1/api/bidders.ex | yoshi-code-bot/elixir-google-api | cdb6032f01fac5ab704803113c39f2207e9e019d | [
"Apache-2.0"
] | null | null | null | clients/real_time_bidding/lib/google_api/real_time_bidding/v1/api/bidders.ex | yoshi-code-bot/elixir-google-api | cdb6032f01fac5ab704803113c39f2207e9e019d | [
"Apache-2.0"
] | null | null | null | clients/real_time_bidding/lib/google_api/real_time_bidding/v1/api/bidders.ex | yoshi-code-bot/elixir-google-api | cdb6032f01fac5ab704803113c39f2207e9e019d | [
"Apache-2.0"
] | null | null | null | # Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, s... | 46.498006 | 868 | 0.623254 |
e855ed49a3ff08e88893e8d6e5874ff6fad2c271 | 209 | exs | Elixir | hello-word.exs | MaraniMatias/elixir-hola-mundo | 325a6ba623378521ec6f79bd4627a0eb7c6cd1fa | [
"MIT"
] | 1 | 2016-12-25T09:53:53.000Z | 2016-12-25T09:53:53.000Z | hello-word.exs | MaraniMatias/elixir-hola-mundo | 325a6ba623378521ec6f79bd4627a0eb7c6cd1fa | [
"MIT"
] | null | null | null | hello-word.exs | MaraniMatias/elixir-hola-mundo | 325a6ba623378521ec6f79bd4627a0eb7c6cd1fa | [
"MIT"
] | null | null | null | IO.puts "Hello world from Elixir...\n"
greet = fn s -> IO.puts "Hello, #{s}!" end
if length(System.argv) == 0 do
greet.("Try: \n elixir hello-word.exs Elixir")
else
Enum.each(System.argv, greet)
end
| 20.9 | 50 | 0.641148 |
e8561cd1dcc90165f086bfdba15ba64d85289f1b | 1,282 | ex | Elixir | year_2020/lib/day_12/ship.ex | bschmeck/advent_of_code | cbec98019c6c00444e0f4c7e15e01b1ed9ae6145 | [
"MIT"
] | null | null | null | year_2020/lib/day_12/ship.ex | bschmeck/advent_of_code | cbec98019c6c00444e0f4c7e15e01b1ed9ae6145 | [
"MIT"
] | null | null | null | year_2020/lib/day_12/ship.ex | bschmeck/advent_of_code | cbec98019c6c00444e0f4c7e15e01b1ed9ae6145 | [
"MIT"
] | null | null | null | defmodule Day12.Ship do
defstruct x: 0, y: 0, dir: 90
def follow_instructions(instrs), do: follow_instructions(instrs, %__MODULE__{})
def follow_instructions([], ship), do: ship
def follow_instructions([instr | rest], ship),
do: follow_instructions(rest, follow_instruction(instr, ship))
def follow_inst... | 41.354839 | 86 | 0.655226 |
e85625b7a6a232e43e31b1240edaa01c35271869 | 89 | ex | Elixir | lib/ambrosia_web/views/pow_reset_password/reset_password_view.ex | emeric-martineau/ambrosia | 74c55d35cf66537d7c8a33ef6057e89d44abd347 | [
"MIT"
] | 2 | 2020-05-25T05:28:31.000Z | 2020-05-25T08:10:43.000Z | lib/ambrosia_web/views/pow_reset_password/reset_password_view.ex | emeric-martineau/ambrosia | 74c55d35cf66537d7c8a33ef6057e89d44abd347 | [
"MIT"
] | 9 | 2020-05-25T16:39:15.000Z | 2020-11-11T16:51:37.000Z | lib/ambrosia_web/views/pow_reset_password/reset_password_view.ex | emeric-martineau/ambrosia | 74c55d35cf66537d7c8a33ef6057e89d44abd347 | [
"MIT"
] | null | null | null | defmodule AmbrosiaWeb.PowResetPassword.ResetPasswordView do
use AmbrosiaWeb, :view
end
| 22.25 | 59 | 0.853933 |
e856452bc6ef26f6de7549be31ba0e59f36e3c08 | 425 | exs | Elixir | test_fixtures/proj/good/serum.exs | skunkwerks/serum | 45039417a101bf89f3a86a4aa3d42ce41df2d676 | [
"MIT"
] | 302 | 2016-08-01T05:16:06.000Z | 2022-03-26T07:20:46.000Z | test_fixtures/proj/good/serum.exs | skunkwerks/serum | 45039417a101bf89f3a86a4aa3d42ce41df2d676 | [
"MIT"
] | 206 | 2016-08-04T15:18:35.000Z | 2022-03-01T03:07:57.000Z | test_fixtures/proj/good/serum.exs | skunkwerks/serum | 45039417a101bf89f3a86a4aa3d42ce41df2d676 | [
"MIT"
] | 35 | 2016-10-29T13:59:34.000Z | 2022-03-01T01:50:31.000Z | %{
site_name: "Test Webite",
site_description: "This is the test website.",
server_root: "https://www.example.com",
base_url: "/test-site/",
author: "John Doe",
author_email: "john.doe@example.com",
date_format: "{YYYY}-{0M}-{0D}",
list_title_all: "All Posts",
list_title_tag: "Posts Tagged ~s",
pagi... | 26.5625 | 48 | 0.684706 |
e8564c883199acf81ea47ec9930905ac61f42aec | 2,128 | exs | Elixir | farmbot_core/test/asset_workers/fbos_config_worker_test.exs | elbow-jason/farmbot_os | f5dfc8f58a309285ca3d441b1b7272f15315b2a9 | [
"MIT"
] | 1 | 2019-08-06T11:51:48.000Z | 2019-08-06T11:51:48.000Z | farmbot_core/test/asset_workers/fbos_config_worker_test.exs | SeppPenner/farmbot_os | 39ba5c5880f8aef71792e2c009514bed1177089c | [
"MIT"
] | null | null | null | farmbot_core/test/asset_workers/fbos_config_worker_test.exs | SeppPenner/farmbot_os | 39ba5c5880f8aef71792e2c009514bed1177089c | [
"MIT"
] | null | null | null | defmodule FarmbotCore.FbosConfigWorkerTest do
use ExUnit.Case, async: true
alias FarmbotCore.{Asset.FbosConfig, AssetWorker, BotState}
import Farmbot.TestSupport.AssetFixtures
test "adds configs to bot state and config_storage" do
%FbosConfig{} =
conf =
fbos_config(%{
monitor: true,
... | 32.242424 | 77 | 0.716635 |
e8564e4ab75517101f118cc55a49e5d35029c902 | 642 | ex | Elixir | lib/ex_oauth2_provider/behaviors/skip_authorization.ex | heroinbob/ex_oauth2_provider | 80c21a53bba0955ab3b66f1bd32cc81db0f04f49 | [
"MIT"
] | null | null | null | lib/ex_oauth2_provider/behaviors/skip_authorization.ex | heroinbob/ex_oauth2_provider | 80c21a53bba0955ab3b66f1bd32cc81db0f04f49 | [
"MIT"
] | null | null | null | lib/ex_oauth2_provider/behaviors/skip_authorization.ex | heroinbob/ex_oauth2_provider | 80c21a53bba0955ab3b66f1bd32cc81db0f04f49 | [
"MIT"
] | null | null | null | defmodule ExOauth2Provider.Behaviors.SkipAuthorization do
@moduledoc """
Define the rules used to determine if authorization can be skipped. If your
app has unique criteria then implement it.
For example:
defmodule MyModule do
@behaviour ExOauth2Provider.Behaviors.SkipAuthorization
def skip_authori... | 26.75 | 77 | 0.71028 |
e8565b45116a893e5660fdcb86ffd86ab15e70a9 | 880 | ex | Elixir | clients/storage/lib/google_api/storage/v1/metadata.ex | MasashiYokota/elixir-google-api | 975dccbff395c16afcb62e7a8e411fbb58e9ab01 | [
"Apache-2.0"
] | null | null | null | clients/storage/lib/google_api/storage/v1/metadata.ex | MasashiYokota/elixir-google-api | 975dccbff395c16afcb62e7a8e411fbb58e9ab01 | [
"Apache-2.0"
] | null | null | null | clients/storage/lib/google_api/storage/v1/metadata.ex | MasashiYokota/elixir-google-api | 975dccbff395c16afcb62e7a8e411fbb58e9ab01 | [
"Apache-2.0"
] | 1 | 2020-10-04T10:12:44.000Z | 2020-10-04T10:12:44.000Z | # 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.592593 | 74 | 0.757955 |
e8567af241e30dc74375622e0fbd0b6f0f3589a6 | 1,239 | exs | Elixir | config/prod.secret.exs | enlego/hasher | 43b528059119971ffbca6538ffb6713fb78e077f | [
"MIT"
] | null | null | null | config/prod.secret.exs | enlego/hasher | 43b528059119971ffbca6538ffb6713fb78e077f | [
"MIT"
] | null | null | null | config/prod.secret.exs | enlego/hasher | 43b528059119971ffbca6538ffb6713fb78e077f | [
"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... | 29.5 | 67 | 0.717514 |
e85690b3df8c7cb2101ab5874cf7e51aaada04d5 | 5,694 | ex | Elixir | lib/changelog_web/views/episode_view.ex | wojtekmach/changelog.com | d4a8a7703c5f07a3da63bffd770f4642488cf8fd | [
"MIT"
] | null | null | null | lib/changelog_web/views/episode_view.ex | wojtekmach/changelog.com | d4a8a7703c5f07a3da63bffd770f4642488cf8fd | [
"MIT"
] | null | null | null | lib/changelog_web/views/episode_view.ex | wojtekmach/changelog.com | d4a8a7703c5f07a3da63bffd770f4642488cf8fd | [
"MIT"
] | null | null | null | defmodule ChangelogWeb.EpisodeView do
use ChangelogWeb, :public_view
import ChangelogWeb.Meta.{Title, Description}
alias Changelog.{Episode, Files, Github, ListKit}
alias ChangelogWeb.{Endpoint, LayoutView, NewsItemView, PersonView,
PodcastView, SponsorView, TimeView}
def admin_edit_l... | 28.903553 | 167 | 0.671584 |
e856a6ed009dbeabb448a72db3f24ebd6e80df82 | 895 | ex | Elixir | lib/news/util/temp_file.ex | randomlabs/news | 6aa200858bac69613af1de91420c6425f4517853 | [
"MIT"
] | 3 | 2015-08-12T20:45:57.000Z | 2015-10-26T09:20:10.000Z | lib/news/util/temp_file.ex | randomlabs/news | 6aa200858bac69613af1de91420c6425f4517853 | [
"MIT"
] | 15 | 2015-08-12T16:20:42.000Z | 2015-10-12T16:12:15.000Z | lib/news/util/temp_file.ex | randomlabs/news | 6aa200858bac69613af1de91420c6425f4517853 | [
"MIT"
] | 1 | 2015-08-20T17:43:10.000Z | 2015-08-20T17:43:10.000Z | defmodule News.Util.TempFile do
def write(name, data) do
file = "/tmp/news.temp." <> name
:ok = File.write!(file, data)
parent = self
monitor_file(file)
end
def attach(file) do
monitor_file(file)
end
def release do
pid = Process.get(:temp_file_pid)
if pid do
send(pid, :rel... | 19.042553 | 55 | 0.589944 |
e856c88076905c5f50b90660566f715140c51b68 | 68,087 | ex | Elixir | lib/ecto/query.ex | codinghombre/ecto | 16d2de8e19aa76b91156684d8d0477e5c8df3b87 | [
"Apache-2.0"
] | null | null | null | lib/ecto/query.ex | codinghombre/ecto | 16d2de8e19aa76b91156684d8d0477e5c8df3b87 | [
"Apache-2.0"
] | null | null | null | lib/ecto/query.ex | codinghombre/ecto | 16d2de8e19aa76b91156684d8d0477e5c8df3b87 | [
"Apache-2.0"
] | null | null | null | defmodule Ecto.SubQuery do
@moduledoc """
A struct representing subqueries.
See `Ecto.Query.subquery/2` for more information.
"""
defstruct [:query, :params, :select, :cache]
end
defmodule Ecto.Query do
@moduledoc ~S"""
Provides the Query DSL.
Queries are used to retrieve and manipulate data from a r... | 34.094642 | 139 | 0.675606 |
e856ec376ffbaccdecef025f51e091df320f6546 | 5,761 | ex | Elixir | clients/dfa_reporting/lib/google_api/dfa_reporting/v33/model/report.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/dfa_reporting/lib/google_api/dfa_reporting/v33/model/report.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/dfa_reporting/lib/google_api/dfa_reporting/v33/model/report.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... | 53.342593 | 310 | 0.704218 |
e856f79bffc045fc5a7bfc7bf36208f4b0fa8614 | 280 | ex | Elixir | lib/option_calc/Models/Quote.ex | davidgrupp/Option-Calc | 0b0e4607d827412e207d5fc5102aee001e93a821 | [
"Apache-2.0"
] | null | null | null | lib/option_calc/Models/Quote.ex | davidgrupp/Option-Calc | 0b0e4607d827412e207d5fc5102aee001e93a821 | [
"Apache-2.0"
] | null | null | null | lib/option_calc/Models/Quote.ex | davidgrupp/Option-Calc | 0b0e4607d827412e207d5fc5102aee001e93a821 | [
"Apache-2.0"
] | null | null | null | defmodule OptionCalc.Quote do
defstruct [
:dayslow,
:dayshigh,
:symbol,
:name,
:percentchange,
:change,
:volume,
:shortratio,
:open,
:last,
:ask,
:bid,
]
end | 17.5 | 30 | 0.4 |
e8571075f061d93007f1a7ce070ab3cfb4f95f38 | 1,099 | ex | Elixir | lib/cxs_starter_web/live/page_live.ex | antp/cxs_starter | 349cbd61e561f276b552f95e88e24e01397b8519 | [
"MIT"
] | null | null | null | lib/cxs_starter_web/live/page_live.ex | antp/cxs_starter | 349cbd61e561f276b552f95e88e24e01397b8519 | [
"MIT"
] | null | null | null | lib/cxs_starter_web/live/page_live.ex | antp/cxs_starter | 349cbd61e561f276b552f95e88e24e01397b8519 | [
"MIT"
] | null | null | null | defmodule CxsStarterWeb.PageLive do
use CxsStarterWeb, :live_view
@impl true
def mount(_params, _session, socket) do
{:ok, assign(socket, query: "", results: %{})}
end
@impl true
def handle_event("suggest", %{"q" => query}, socket) do
{:noreply, assign(socket, results: search(query), query: query)... | 27.475 | 84 | 0.605096 |
e8571a9dc18a712f36f935fd8b3e1ce3ee745120 | 954 | exs | Elixir | test/roger/job/worker_timeout_test.exs | jnylen/roger | 074338eceae4783221088e8b235a635452708ef1 | [
"MIT"
] | null | null | null | test/roger/job/worker_timeout_test.exs | jnylen/roger | 074338eceae4783221088e8b235a635452708ef1 | [
"MIT"
] | null | null | null | test/roger/job/worker_timeout_test.exs | jnylen/roger | 074338eceae4783221088e8b235a635452708ef1 | [
"MIT"
] | null | null | null | defmodule Roger.Job.WorkerTimeoutTest do
use ExUnit.Case
use Roger.AppCase
alias Roger.Job
defmodule OnErrorCallback do
use Roger.Partition.Worker.Callback
def on_error(_partition, _job, {error, _reason}, _, _) do
send(Roger.Job.WorkerTimeoutTest, {:job_error, error})
end
end
defmodul... | 21.2 | 61 | 0.680294 |
e8575534610fedd1a2d8fab36baa3704d68f394e | 542 | ex | Elixir | examples/ex2/consumer.ex | Carburetor/esp_ex | 0a0ab02c71945e521b213befc0421a4642c9e07b | [
"MIT"
] | null | null | null | examples/ex2/consumer.ex | Carburetor/esp_ex | 0a0ab02c71945e521b213befc0421a4642c9e07b | [
"MIT"
] | 1 | 2018-05-11T04:27:54.000Z | 2018-05-11T04:27:54.000Z | examples/ex2/consumer.ex | Carburetor/esp_ex | 0a0ab02c71945e521b213befc0421a4642c9e07b | [
"MIT"
] | 1 | 2018-10-30T06:08:02.000Z | 2018-10-30T06:08:02.000Z | defmodule Ex2.Consumer do
use GenServer
def start_link(_) do
EspEx.Consumer.start_link(__MODULE__, identifier: __MODULE__)
EspEx.Consumer.listen(__MODULE__)
end
def handle_cast(:event_received, raw_event) do
event = Ex2.Task.Events.transform(raw_event.type, raw_event)
handle(event)
end
de... | 22.583333 | 65 | 0.714022 |
e85761dc9e8fd11aa3eaf58cd9e514fa32c0addf | 1,906 | exs | Elixir | config/dev.exs | DPechetti/nlw-heat-elixir | c3fe71244a4c1d49bb28668f9334c5b4c803aa54 | [
"MIT"
] | 2 | 2021-10-30T11:53:58.000Z | 2022-02-06T02:17:06.000Z | config/dev.exs | DPechetti/nlw-heat-elixir | c3fe71244a4c1d49bb28668f9334c5b4c803aa54 | [
"MIT"
] | 1 | 2021-10-30T14:24:28.000Z | 2021-10-30T14:24:28.000Z | config/dev.exs | DPechetti/nlw-heat-elixir | c3fe71244a4c1d49bb28668f9334c5b4c803aa54 | [
"MIT"
] | null | null | null | import Config
# Configure your database
config :heat_tags, HeatTags.Repo,
username: "postgres",
password: "postgres",
database: "heat_tags_dev",
hostname: "localhost",
show_sensitive_data_on_connection_error: true,
pool_size: 10
# For development, we disable any cache and enable
# debugging and code reloa... | 31.245902 | 86 | 0.730325 |
e8579601c274c4e44df47031aa61693f2b92e4ad | 1,007 | ex | Elixir | test/support/data_case.ex | andsleonardo/magnemite | 2a06c1520defeb193d718313ad3fc6a50349bc8d | [
"MIT"
] | null | null | null | test/support/data_case.ex | andsleonardo/magnemite | 2a06c1520defeb193d718313ad3fc6a50349bc8d | [
"MIT"
] | null | null | null | test/support/data_case.ex | andsleonardo/magnemite | 2a06c1520defeb193d718313ad3fc6a50349bc8d | [
"MIT"
] | null | null | null | defmodule Magnemite.DataCase do
@moduledoc """
This module defines the setup for tests requiring
access to the application's data layer.
You may define functions here to be used as helpers in
your tests.
Finally, if the test case interacts with the database,
we enable the SQL sandbox, so changes done to... | 23.97619 | 71 | 0.713009 |
e857f1351dfcddfd02cb5abab6510eca4140e09c | 1,474 | ex | Elixir | lib/namedb_web/views/error_helpers.ex | empex2019liveview/namedb | fd01151dd293f9740204435fed524bc364f81069 | [
"MIT"
] | null | null | null | lib/namedb_web/views/error_helpers.ex | empex2019liveview/namedb | fd01151dd293f9740204435fed524bc364f81069 | [
"MIT"
] | null | null | null | lib/namedb_web/views/error_helpers.ex | empex2019liveview/namedb | fd01151dd293f9740204435fed524bc364f81069 | [
"MIT"
] | null | null | null | defmodule NamedbWeb.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_tag(:... | 32.755556 | 75 | 0.669607 |
e857ff852d4a89784ff151f93ed495ef49ccd754 | 2,342 | exs | Elixir | test/controllers/tag_controller_test.exs | cdegroot/clueless | c7f575159a42f55eb843df0e37802e778826c845 | [
"MIT"
] | null | null | null | test/controllers/tag_controller_test.exs | cdegroot/clueless | c7f575159a42f55eb843df0e37802e778826c845 | [
"MIT"
] | 4 | 2015-12-18T20:35:49.000Z | 2015-12-18T20:36:43.000Z | test/controllers/tag_controller_test.exs | cdegroot/clueless | c7f575159a42f55eb843df0e37802e778826c845 | [
"MIT"
] | null | null | null | defmodule Clueless.TagControllerTest do
use Clueless.ConnCase
alias Clueless.Tag
@valid_attrs %{name: "some content"}
@invalid_attrs %{}
setup do
conn = authenticated_conn()
{:ok, conn: conn}
end
test "lists all entries on index", %{conn: conn} do
conn = get conn, tag_path(conn, :index)
... | 32.527778 | 98 | 0.668232 |
e8582abc289aebf396d28fec7f294d96ad6a330e | 3,181 | ex | Elixir | clients/firestore/lib/google_api/firestore/v1beta1/model/google_firestore_admin_v1beta1_import_documents_metadata.ex | MasashiYokota/elixir-google-api | 975dccbff395c16afcb62e7a8e411fbb58e9ab01 | [
"Apache-2.0"
] | null | null | null | clients/firestore/lib/google_api/firestore/v1beta1/model/google_firestore_admin_v1beta1_import_documents_metadata.ex | MasashiYokota/elixir-google-api | 975dccbff395c16afcb62e7a8e411fbb58e9ab01 | [
"Apache-2.0"
] | 1 | 2020-12-18T09:25:12.000Z | 2020-12-18T09:25:12.000Z | clients/firestore/lib/google_api/firestore/v1beta1/model/google_firestore_admin_v1beta1_import_documents_metadata.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... | 41.855263 | 179 | 0.728387 |
e8582b02b4020d5e1f9bdb1128b625d4389bc16b | 280 | exs | Elixir | chapter-11/strings-and-binaries-2.exs | andreyuhai/elixir-exercises | 23f90ba8e76597cf8feb45a11718dcb0c42b649d | [
"MIT"
] | null | null | null | chapter-11/strings-and-binaries-2.exs | andreyuhai/elixir-exercises | 23f90ba8e76597cf8feb45a11718dcb0c42b649d | [
"MIT"
] | null | null | null | chapter-11/strings-and-binaries-2.exs | andreyuhai/elixir-exercises | 23f90ba8e76597cf8feb45a11718dcb0c42b649d | [
"MIT"
] | null | null | null | defmodule StringsAndBinaries do
# Exercise:StringsAndBinaries-2
# Write an anagram?(word1, word2) that returns true if
# its parameters are anagrams
def anagram?(word1, word2), do: word1 -- word2 == []
end
IO.puts StringsAndBinaries.anagram?('alert', 'alter')
# => true
| 25.454545 | 56 | 0.717857 |
e85858b3ff8daae5cb2fbb925f67394a1b2032ee | 1,225 | ex | Elixir | clients/analytics_reporting/lib/google_api/analytics_reporting/v4/connection.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/analytics_reporting/lib/google_api/analytics_reporting/v4/connection.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | 1 | 2020-12-18T09:25:12.000Z | 2020-12-18T09:25:12.000Z | clients/analytics_reporting/lib/google_api/analytics_reporting/v4/connection.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... | 34.027778 | 74 | 0.740408 |
e85893d3a67eab33a0a6746b4f920ce39d121c1c | 277 | exs | Elixir | test/lib/Utilities/oauth_test.exs | davidgrupp/Option-Calc | 0b0e4607d827412e207d5fc5102aee001e93a821 | [
"Apache-2.0"
] | null | null | null | test/lib/Utilities/oauth_test.exs | davidgrupp/Option-Calc | 0b0e4607d827412e207d5fc5102aee001e93a821 | [
"Apache-2.0"
] | null | null | null | test/lib/Utilities/oauth_test.exs | davidgrupp/Option-Calc | 0b0e4607d827412e207d5fc5102aee001e93a821 | [
"Apache-2.0"
] | null | null | null | defmodule OAuthTests do
use ExUnit.Case
#doctest OptionCalc.OAuth
test "OAuth sign" do
#assert on patern match
assert [{"Authorization", "OAuth oauth_signature=" <> _}] = OptionCalc.OAuth.sign(:get, "https://example.com", :tk_oauth)
#assert 1==1
end
end
| 23.083333 | 125 | 0.68231 |
e858984bc30e46d9bc4b6c45f2926df9ce5f8487 | 845 | exs | Elixir | apps/state_mediator/test/state_mediator/mediator_log_test.exs | mbta/automatic-fiesta | de9eb43e4fc7c47aa069f5ded8497ddd39ff74c5 | [
"MIT"
] | null | null | null | apps/state_mediator/test/state_mediator/mediator_log_test.exs | mbta/automatic-fiesta | de9eb43e4fc7c47aa069f5ded8497ddd39ff74c5 | [
"MIT"
] | null | null | null | apps/state_mediator/test/state_mediator/mediator_log_test.exs | mbta/automatic-fiesta | de9eb43e4fc7c47aa069f5ded8497ddd39ff74c5 | [
"MIT"
] | null | null | null | defmodule StateMediator.MediatorLogTest do
use ExUnit.Case
import ExUnit.CaptureLog, only: [capture_log: 1]
alias StateMediator.Mediator
test "logs a fetch timeout as a warning" do
assert capture_log(fn ->
Mediator.handle_response(
{:error,
%HTTPoison.Error{
... | 26.40625 | 50 | 0.486391 |
e858df72f6494dbb06ad6ec5015935c0319280cb | 213 | ex | Elixir | apps/wechat_mp/lib/wechat_mp/api/model/access_token.ex | secretworry/exwechat | 2d3a8bf03135eebd58452122c2f7b3718b5f5b3d | [
"Apache-2.0"
] | null | null | null | apps/wechat_mp/lib/wechat_mp/api/model/access_token.ex | secretworry/exwechat | 2d3a8bf03135eebd58452122c2f7b3718b5f5b3d | [
"Apache-2.0"
] | null | null | null | apps/wechat_mp/lib/wechat_mp/api/model/access_token.ex | secretworry/exwechat | 2d3a8bf03135eebd58452122c2f7b3718b5f5b3d | [
"Apache-2.0"
] | null | null | null | defmodule WechatMP.Api.Model.AccessToken do
use WechatBase.Api.Model.JsonResponse
model do
field :access_token
field :expires_in
field :refresh_token
field :openid
field :scope
end
end
| 16.384615 | 43 | 0.7277 |
e858e22f8b3de2964e597531be0e2e90dc58bebd | 2,011 | ex | Elixir | lib/mix/lib/mix/tasks/compile.protocols.ex | patrickgombert/elixir | dc4b7c89ea30a9734d9f1cbf3bb1612fada498d4 | [
"Apache-2.0"
] | null | null | null | lib/mix/lib/mix/tasks/compile.protocols.ex | patrickgombert/elixir | dc4b7c89ea30a9734d9f1cbf3bb1612fada498d4 | [
"Apache-2.0"
] | null | null | null | lib/mix/lib/mix/tasks/compile.protocols.ex | patrickgombert/elixir | dc4b7c89ea30a9734d9f1cbf3bb1612fada498d4 | [
"Apache-2.0"
] | 1 | 2020-12-07T08:04:16.000Z | 2020-12-07T08:04:16.000Z | defmodule Mix.Tasks.Compile.Protocols do
use Mix.Task
@recursive true
@shortdoc "Consolidates all protocols in all paths"
@moduledoc ~S"""
Consolidates all protocols in all paths.
This module consolidates all protocols in the code path
and output the new binary files to the given directory
(defaults... | 27.175676 | 95 | 0.679761 |
e858eba0d3d6ceef40c16efbc2cd4918b5a53f5c | 2,026 | exs | Elixir | test/swoosh/attachment_test.exs | henb/swoosh | 54534c411d1b9be46d94c2f75e102098a3ad28ea | [
"MIT"
] | null | null | null | test/swoosh/attachment_test.exs | henb/swoosh | 54534c411d1b9be46d94c2f75e102098a3ad28ea | [
"MIT"
] | null | null | null | test/swoosh/attachment_test.exs | henb/swoosh | 54534c411d1b9be46d94c2f75e102098a3ad28ea | [
"MIT"
] | null | null | null | defmodule Swoosh.AttachmentTest do
use ExUnit.Case
alias Swoosh.Attachment
test "create an attachment" do
attachment = Attachment.new("/data/file")
assert attachment.content_type == "application/octet-stream"
assert attachment.filename == "file"
assert attachment.path == "/data/file"
end
te... | 36.836364 | 96 | 0.684107 |
e8590b95f16e5b8efa1ecaf672ba415efe8bf0b6 | 114 | ex | Elixir | lib/suomidev_web/views/auth_view.ex | yliaho/suomi.dev | 4e1946adbeb67cebdc1b7e2009ddecf66497a9c7 | [
"MIT"
] | 19 | 2020-08-24T02:50:26.000Z | 2021-05-31T20:54:30.000Z | lib/suomidev_web/views/auth_view.ex | yliaho/suomi.dev | 4e1946adbeb67cebdc1b7e2009ddecf66497a9c7 | [
"MIT"
] | 2 | 2020-08-24T06:59:46.000Z | 2020-08-26T09:51:40.000Z | lib/suomidev_web/views/auth_view.ex | yliaho/suomi.dev | 4e1946adbeb67cebdc1b7e2009ddecf66497a9c7 | [
"MIT"
] | 6 | 2020-08-26T02:52:48.000Z | 2022-03-08T12:55:51.000Z | defmodule SuomidevWeb.AuthView do
use SuomidevWeb, :view
def title(_template, _assigns) do
nil
end
end
| 14.25 | 35 | 0.736842 |
e85910f4ce1264eb4bef0891632650934d7a7b8d | 675 | exs | Elixir | dei_app/config/test.exs | mbta/DEI-dashboard | 7446c1d5497b388f337df554ef1109b8b9b0f606 | [
"MIT"
] | 1 | 2020-09-18T19:41:07.000Z | 2020-09-18T19:41:07.000Z | dei_app/config/test.exs | mbta/DEI-dashboard | 7446c1d5497b388f337df554ef1109b8b9b0f606 | [
"MIT"
] | 4 | 2020-07-23T02:35:33.000Z | 2020-09-21T14:55:32.000Z | dei_app/config/test.exs | mbta/DEI-dashboard | 7446c1d5497b388f337df554ef1109b8b9b0f606 | [
"MIT"
] | null | null | null | use Mix.Config
# Configure your database
#
# The MIX_TEST_PARTITION environment variable can be used
# to provide built-in test partitioning in CI environment.
# Run `mix help test` for more information.
config :dei_app, DeiApp.Repo,
username: "dei_user",
password: "password",
database: "dei_dashboard_test",
h... | 28.125 | 58 | 0.752593 |
e8592b6e04d5dba01cafdcaa65d0ac58a1a46d7b | 3,127 | exs | Elixir | host_core/test/host_core/wasmcloud/native_test.exs | sleipnir/wasmcloud-otp | aef10f2f07257e65c527be6030006aaed2b85ff9 | [
"Apache-2.0"
] | null | null | null | host_core/test/host_core/wasmcloud/native_test.exs | sleipnir/wasmcloud-otp | aef10f2f07257e65c527be6030006aaed2b85ff9 | [
"Apache-2.0"
] | null | null | null | host_core/test/host_core/wasmcloud/native_test.exs | sleipnir/wasmcloud-otp | aef10f2f07257e65c527be6030006aaed2b85ff9 | [
"Apache-2.0"
] | null | null | null | defmodule HostCore.WasmCloud.NativeTest do
@httpserver_key "VAG3QITQQ2ODAOWB5TTQSDJ53XK3SHBEIFNK4AYJ5RKAX2UNSCAPHA5M"
@httpserver_link "default"
@httpserver_contract "wasmcloud:httpserver"
@httpserver_oci "wasmcloud.azurecr.io/httpserver:0.13.1"
@official_issuer "ACOJJN6WUP4ODD75XEBKKTCCUJJCY5ZKQ56XVKYK4BEJWG... | 26.956897 | 123 | 0.631916 |
e8592c95ca6c32fa939b1741dc5fafe3b4abdb08 | 3,903 | ex | Elixir | clients/monitoring/lib/google_api/monitoring/v3/model/http_check.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/monitoring/lib/google_api/monitoring/v3/model/http_check.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/monitoring/lib/google_api/monitoring/v3/model/http_check.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... | 60.046154 | 527 | 0.726621 |
e859388566d9e9c70fda595cc3573de4f23f8066 | 21,720 | exs | Elixir | test/finch_test.exs | c4710n/finch | f07ef3063b2778776ea847bab45fc7b566d02668 | [
"MIT"
] | 71 | 2021-10-16T09:55:02.000Z | 2022-03-26T08:42:59.000Z | test/finch_test.exs | c4710n/finch | f07ef3063b2778776ea847bab45fc7b566d02668 | [
"MIT"
] | 21 | 2021-10-16T07:58:51.000Z | 2022-03-28T12:27:40.000Z | test/finch_test.exs | c4710n/finch | f07ef3063b2778776ea847bab45fc7b566d02668 | [
"MIT"
] | 20 | 2021-10-16T09:55:06.000Z | 2022-03-27T13:21:27.000Z | defmodule FinchTest do
use FinchCase, async: true
doctest Finch
import ExUnit.CaptureIO
alias Finch.Response
alias Finch.MockSocketServer
describe "start_link/1" do
test "raises if :name is not provided" do
assert_raise(ArgumentError, ~r/must supply a name/, fn -> Finch.start_link([]) end)
... | 31.894273 | 110 | 0.564227 |
e8593caec562e4a56ced9cb2ea854ec46e59320b | 161 | exs | Elixir | lib/modules_and_functions_1/triple.exs | mikan/elixir-practice | 624525605eb2324e0c55a4ddcb68388c0d2ecefc | [
"Apache-2.0"
] | null | null | null | lib/modules_and_functions_1/triple.exs | mikan/elixir-practice | 624525605eb2324e0c55a4ddcb68388c0d2ecefc | [
"Apache-2.0"
] | 1 | 2020-01-28T00:19:53.000Z | 2020-01-28T00:19:53.000Z | lib/modules_and_functions_1/triple.exs | mikan/elixir-practice | 624525605eb2324e0c55a4ddcb68388c0d2ecefc | [
"Apache-2.0"
] | null | null | null | defmodule Times do
def double(n), do: n * 2
def triple(n), do: n * 3
end
IO.puts Times.triple(0) # 0
IO.puts Times.triple(1) # 3
IO.puts Times.triple(2) # 6
| 20.125 | 27 | 0.645963 |
e859468a48a9c7c6fbe74ef0bc078ed9a1b6faba | 320 | ex | Elixir | examples/simple_app/lib/simple_app/struct_example.ex | Fl4m3Ph03n1x/gradient | 60d7d3fe2ebdf68747325c1e852959f8b92fdcee | [
"Apache-2.0"
] | 75 | 2021-11-17T11:55:13.000Z | 2022-03-28T04:35:04.000Z | examples/simple_app/lib/simple_app/struct_example.ex | Fl4m3Ph03n1x/gradient | 60d7d3fe2ebdf68747325c1e852959f8b92fdcee | [
"Apache-2.0"
] | 48 | 2021-11-15T13:56:14.000Z | 2022-03-31T15:55:47.000Z | examples/simple_app/lib/simple_app/struct_example.ex | Fl4m3Ph03n1x/gradient | 60d7d3fe2ebdf68747325c1e852959f8b92fdcee | [
"Apache-2.0"
] | 6 | 2021-12-22T20:41:27.000Z | 2022-03-09T09:07:38.000Z | defmodule SimpleApp.StructExample do
defmodule SomeStruct do
defstruct [name: "John Smith", age: 25]
end
@type t :: %SomeStruct{}
@spec age(t) :: non_neg_integer
def age(%SomeStruct{age: age}), do: age
@spec mistake :: :ok
def mistake do
age(%{first: "John", last: "Smith", age: 32})
end
end
| 18.823529 | 49 | 0.64375 |
e859510237c9a57862ca47375b08bc7253e919cd | 1,021 | ex | Elixir | test/support/conn_case.ex | JosKar/iris_server | 8faa370f506a003ae3c06b23d6c827bd746368f3 | [
"MIT"
] | 17 | 2017-07-10T09:01:40.000Z | 2022-03-08T23:47:27.000Z | test/support/conn_case.ex | 7-iris/iris_server | 8faa370f506a003ae3c06b23d6c827bd746368f3 | [
"MIT"
] | 7 | 2017-07-09T16:22:13.000Z | 2018-06-09T21:34:03.000Z | test/support/conn_case.ex | JosKar/iris_server | 8faa370f506a003ae3c06b23d6c827bd746368f3 | [
"MIT"
] | null | null | null | defmodule IrisWeb.ConnCase do
@moduledoc """
This module defines the test case to be used by
tests that require setting up a connection.
Such tests rely on `Phoenix.ConnTest` and also
import other functionality to make it easier
to build common datastructures and query the data layer.
Finally, if the te... | 27.594595 | 66 | 0.716944 |
e85957818606c24d0311828d07f8afb670d64a7e | 6,413 | ex | Elixir | lib/elixir/lib/macro/env.ex | RyanBard/elixir | 3e0f3b47cf26aa121470141b9a1aa55a366c066e | [
"Apache-2.0"
] | 2 | 2018-11-15T06:38:14.000Z | 2018-11-17T18:03:14.000Z | lib/elixir/lib/macro/env.ex | RyanBard/elixir | 3e0f3b47cf26aa121470141b9a1aa55a366c066e | [
"Apache-2.0"
] | null | null | null | lib/elixir/lib/macro/env.ex | RyanBard/elixir | 3e0f3b47cf26aa121470141b9a1aa55a366c066e | [
"Apache-2.0"
] | null | null | null | defmodule Macro.Env do
@moduledoc """
A struct that holds compile time environment information.
The current environment can be accessed at any time as
`__ENV__/0`. Inside macros, the caller environment can be
accessed as `__CALLER__/0`.
An instance of `Macro.Env` must not be modified by hand. If you need ... | 29.96729 | 82 | 0.645252 |
e85971c4b582c1db3c1ab00a14d9050cac53bd77 | 378 | exs | Elixir | priv/repo/migrations/20200707155254_fill_document_tokens_posts_column.exs | santiment/sanbase2 | 9ef6e2dd1e377744a6d2bba570ea6bd477a1db31 | [
"MIT"
] | 81 | 2017-11-20T01:20:22.000Z | 2022-03-05T12:04:25.000Z | priv/repo/migrations/20200707155254_fill_document_tokens_posts_column.exs | rmoorman/sanbase2 | 226784ab43a24219e7332c49156b198d09a6dd85 | [
"MIT"
] | 359 | 2017-10-15T14:40:53.000Z | 2022-01-25T13:34:20.000Z | priv/repo/migrations/20200707155254_fill_document_tokens_posts_column.exs | rmoorman/sanbase2 | 226784ab43a24219e7332c49156b198d09a6dd85 | [
"MIT"
] | 16 | 2017-11-19T13:57:40.000Z | 2022-02-07T08:13:02.000Z | defmodule Sanbase.Repo.Migrations.FillDocumentTokensPostsColumn do
use Ecto.Migration
def up do
setup()
Sanbase.Insight.Search.update_all_document_tokens()
end
def down do
:ok
end
defp setup() do
Application.ensure_all_started(:tzdata)
Application.ensure_all_started(:prometheus_ecto)
... | 19.894737 | 66 | 0.756614 |
e85971ede6d4634a8cd54d436f91dd1d581a1782 | 562 | ex | Elixir | lib/mail_slurp_api/model/sort.ex | sumup-bank/mailslurp-client-elixir | 87ccdedf2f0f4cd3e50f5781ffb088142e3cf4e8 | [
"MIT"
] | 1 | 2021-06-17T18:07:49.000Z | 2021-06-17T18:07:49.000Z | lib/mail_slurp_api/model/sort.ex | sumup-bank/mailslurp-client-elixir | 87ccdedf2f0f4cd3e50f5781ffb088142e3cf4e8 | [
"MIT"
] | null | null | null | lib/mail_slurp_api/model/sort.ex | sumup-bank/mailslurp-client-elixir | 87ccdedf2f0f4cd3e50f5781ffb088142e3cf4e8 | [
"MIT"
] | 1 | 2021-03-16T18:55:56.000Z | 2021-03-16T18:55:56.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 MailSlurpAPI.Model.Sort do
@moduledoc """
"""
@derive [Poison.Encoder]
defstruct [
:"empty",
:"sorted",
:"unsorted"
]
@ty... | 18.733333 | 91 | 0.635231 |
e85974b5e7fe895a67232d9b8b5a6643950fc7f8 | 2,300 | ex | Elixir | clients/app_engine/lib/google_api/app_engine/v1/model/identity_aware_proxy.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/app_engine/lib/google_api/app_engine/v1/model/identity_aware_proxy.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | 1 | 2020-12-18T09:25:12.000Z | 2020-12-18T09:25:12.000Z | clients/app_engine/lib/google_api/app_engine/v1/model/identity_aware_proxy.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... | 41.071429 | 292 | 0.735217 |
e85979a2aed27d12f6445f8bf029927f7e6a7968 | 1,081 | exs | Elixir | config/config.exs | adanselm/exrecaptcha | 5e4ab06f791c4e54ccb510631abb4779ed34723f | [
"WTFPL"
] | 10 | 2015-10-02T12:04:05.000Z | 2020-01-09T02:50:22.000Z | config/config.exs | adanselm/exrecaptcha | 5e4ab06f791c4e54ccb510631abb4779ed34723f | [
"WTFPL"
] | 2 | 2015-08-24T09:06:29.000Z | 2018-04-06T08:35:51.000Z | config/config.exs | adanselm/exrecaptcha | 5e4ab06f791c4e54ccb510631abb4779ed34723f | [
"WTFPL"
] | 1 | 2015-08-21T10:51:55.000Z | 2015-08-21T10:51:55.000Z | # This file is responsible for configuring your application
# and its dependencies with the aid of the Mix.Config module.
use Mix.Config
# This configuration is loaded before any dependency and is restricted
# to this project. If another project depends on this project, this
# file won't be loaded nor affect the paren... | 43.24 | 74 | 0.749306 |
e8597feb72590b5107dbcc92c26a484a8b181f1f | 1,107 | exs | Elixir | config/config.exs | staspoons/secretplace | 1270d2d40606cdde9f1196c8f4a87acb8e94efe8 | [
"MIT"
] | 1 | 2019-04-12T08:50:05.000Z | 2019-04-12T08:50:05.000Z | config/config.exs | staspoons/secretplace | 1270d2d40606cdde9f1196c8f4a87acb8e94efe8 | [
"MIT"
] | null | null | null | config/config.exs | staspoons/secretplace | 1270d2d40606cdde9f1196c8f4a87acb8e94efe8 | [
"MIT"
] | null | null | null | # This file is responsible for configuring your application
# and its dependencies with the aid of the Mix.Config module.
use Mix.Config
# This configuration is loaded before any dependency and is restricted
# to this project. If another project depends on this project, this
# file won't be loaded nor affect the paren... | 35.709677 | 73 | 0.748871 |
e85985941107e1a57b8ab38f5048059bf0059a95 | 4,055 | exs | Elixir | test/sitemapper_test.exs | kotsius/sitemapper | 67807a9c4d609a86feb7fd890f5ff48c7bb08223 | [
"MIT"
] | null | null | null | test/sitemapper_test.exs | kotsius/sitemapper | 67807a9c4d609a86feb7fd890f5ff48c7bb08223 | [
"MIT"
] | null | null | null | test/sitemapper_test.exs | kotsius/sitemapper | 67807a9c4d609a86feb7fd890f5ff48c7bb08223 | [
"MIT"
] | null | null | null | defmodule SitemapperTest do
use ExUnit.Case
doctest Sitemapper
alias Sitemapper.URL
test "generate with 0 URLs" do
opts = [
sitemap_url: "http://example.org/foo"
]
elements =
Stream.concat([])
|> Sitemapper.generate(opts)
assert Enum.count(elements) == 0
end
test "gene... | 27.773973 | 105 | 0.587423 |
e8598c950e86596b8c8230cfcc67d378e49f9ca4 | 804 | ex | Elixir | guardian_authentication/test/support/channel_case.ex | hbobenicio/phoenix-examples | dd2adc8887a341b50d192bc31c61ee528e896672 | [
"MIT"
] | null | null | null | guardian_authentication/test/support/channel_case.ex | hbobenicio/phoenix-examples | dd2adc8887a341b50d192bc31c61ee528e896672 | [
"MIT"
] | null | null | null | guardian_authentication/test/support/channel_case.ex | hbobenicio/phoenix-examples | dd2adc8887a341b50d192bc31c61ee528e896672 | [
"MIT"
] | null | null | null | defmodule GuardianAuthenticationWeb.ChannelCase do
@moduledoc """
This module defines the test case to be used by
channel tests.
Such tests rely on `Phoenix.ChannelTest` and also
import other functionality to make it easier
to build common datastructures and query the data layer.
Finally, if the test ca... | 23.647059 | 58 | 0.736318 |
e8599cbf0e5e1051d91a3c0914c55b1b0518cb2a | 3,516 | ex | Elixir | lib/helios_aggregate/pipeline.ex | exponentially/helios_aggregate | d667fe913cd5ed380f874e2f207fdbc98f4c9b71 | [
"Apache-2.0"
] | 2 | 2018-09-03T11:02:12.000Z | 2019-12-12T13:08:51.000Z | lib/helios_aggregate/pipeline.ex | exponentially/helios_aggregate | d667fe913cd5ed380f874e2f207fdbc98f4c9b71 | [
"Apache-2.0"
] | 1 | 2018-09-04T05:14:55.000Z | 2018-09-05T06:37:07.000Z | lib/helios_aggregate/pipeline.ex | exponentially/helios_aggregate | d667fe913cd5ed380f874e2f207fdbc98f4c9b71 | [
"Apache-2.0"
] | null | null | null | defmodule Helios.Aggregate.Pipeline do
@moduledoc false
alias Helios.Aggregate.Pipeline.Context
@doc false
defmacro __using__(opts) do
quote bind_quoted: [opts: opts] do
@behaviour Helios.Aggregate.Pipeline.Plug
import Helios.Aggregate.Pipeline
alias Helios.Aggregate.Pipeline.Context
... | 26.839695 | 96 | 0.613481 |
e859bd012d6d9d3e025aa6f4bc7ff213690adf25 | 1,811 | ex | Elixir | lib/assent/strategies/google.ex | lmeier/assent | 3f5a5d340eb1833cd9d6ada9d7e3056b7e3d4f41 | [
"MIT"
] | 160 | 2019-09-25T01:07:16.000Z | 2022-03-08T00:45:16.000Z | lib/assent/strategies/google.ex | lmeier/assent | 3f5a5d340eb1833cd9d6ada9d7e3056b7e3d4f41 | [
"MIT"
] | 47 | 2019-09-25T00:38:44.000Z | 2022-03-21T17:35:43.000Z | lib/assent/strategies/google.ex | lmeier/assent | 3f5a5d340eb1833cd9d6ada9d7e3056b7e3d4f41 | [
"MIT"
] | 30 | 2019-10-04T15:58:06.000Z | 2021-12-10T16:43:52.000Z | defmodule Assent.Strategy.Google do
@moduledoc """
Google OAuth 2.0 strategy.
In the normalized user response a `google_hd` ("Hosted Domain") field is
included in user parameters and can be used to limit access to users
belonging to a particular hosted domain.
## Usage
config = [
client_id:... | 29.688525 | 135 | 0.617891 |
e859bebbfa25adbdf7020b1617e2ebdd35ca4fe6 | 1,919 | ex | Elixir | clients/document_ai/lib/google_api/document_ai/v1/model/google_cloud_documentai_v1_set_default_processor_version_metadata.ex | renovate-bot/elixir-google-api | 1da34cd39b670c99f067011e05ab90af93fef1f6 | [
"Apache-2.0"
] | 1 | 2021-12-20T03:40:53.000Z | 2021-12-20T03:40:53.000Z | clients/document_ai/lib/google_api/document_ai/v1/model/google_cloud_documentai_v1_set_default_processor_version_metadata.ex | swansoffiee/elixir-google-api | 9ea6d39f273fb430634788c258b3189d3613dde0 | [
"Apache-2.0"
] | 1 | 2020-08-18T00:11:23.000Z | 2020-08-18T00:44:16.000Z | clients/document_ai/lib/google_api/document_ai/v1/model/google_cloud_documentai_v1_set_default_processor_version_metadata.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... | 34.890909 | 183 | 0.771756 |
e859d310907e531d8ef00994a89ddbcb7a86e784 | 2,021 | exs | Elixir | programming_elixir/chapter11/exercises.exs | hectoregm/elixir | c4dc9cd327c6d935de93337e5c52d58b82c4d339 | [
"MIT"
] | null | null | null | programming_elixir/chapter11/exercises.exs | hectoregm/elixir | c4dc9cd327c6d935de93337e5c52d58b82c4d339 | [
"MIT"
] | null | null | null | programming_elixir/chapter11/exercises.exs | hectoregm/elixir | c4dc9cd327c6d935de93337e5c52d58b82c4d339 | [
"MIT"
] | null | null | null | defmodule Exercise do
def printable?(chars), do: Enum.all?(chars, fn ch -> ch in ?\s..?~ end)
def anagram?(word1, word2), do: Enum.sort(word1) == Enum.sort(word2)
def calculate(str) do
{num_a, [op | num_b]} = Enum.split_while(str, fn ch -> ch in '0123456789 ' end)
number_a = parse_number(num_a)
numbe... | 29.720588 | 95 | 0.629886 |
e859e77fc7d3b7a40d72be934d419f399af16d53 | 1,171 | ex | Elixir | apps/wuw_web/lib/wuw_web/web/channels/user_socket.ex | aforward/wuw | 8f41157aeb9fce738a402e757bf78a322a890b7a | [
"MIT"
] | null | null | null | apps/wuw_web/lib/wuw_web/web/channels/user_socket.ex | aforward/wuw | 8f41157aeb9fce738a402e757bf78a322a890b7a | [
"MIT"
] | null | null | null | apps/wuw_web/lib/wuw_web/web/channels/user_socket.ex | aforward/wuw | 8f41157aeb9fce738a402e757bf78a322a890b7a | [
"MIT"
] | null | null | null | defmodule WuwWeb.Web.UserSocket do
use Phoenix.Socket
## Channels
# channel "room:*", WuwWeb.RoomChannel
## Transports
transport :websocket, Phoenix.Transports.WebSocket
# transport :longpoll, Phoenix.Transports.LongPoll
# Socket params are passed from the client and can
# be used to verify and authe... | 30.815789 | 83 | 0.70111 |
e859fd4c814e3288f16f0f441d3abba18e70e8e8 | 413 | exs | Elixir | nomads/src/test/nomads_web/views/error_view_test.exs | HarpBytes/nomads | 10c79953e19262d9d095a190eecb09a5e57e6bf2 | [
"MIT"
] | null | null | null | nomads/src/test/nomads_web/views/error_view_test.exs | HarpBytes/nomads | 10c79953e19262d9d095a190eecb09a5e57e6bf2 | [
"MIT"
] | null | null | null | nomads/src/test/nomads_web/views/error_view_test.exs | HarpBytes/nomads | 10c79953e19262d9d095a190eecb09a5e57e6bf2 | [
"MIT"
] | null | null | null | defmodule NomadsWeb.ErrorViewTest do
use NomadsWeb.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(NomadsWeb.ErrorView, "404.html", []) == "Not Found"
end
test "renders 500.html" do
asser... | 27.533333 | 91 | 0.731235 |
e85a0dc13db46af8d188104e1cd127f10fc77337 | 693 | ex | Elixir | apps/artemis/lib/artemis/contexts/tag/create_tag.ex | artemis-platform/artemis_dashboard | 5ab3f5ac4c5255478bbebf76f0e43b44992e3cab | [
"MIT"
] | 9 | 2019-08-19T19:56:34.000Z | 2022-03-22T17:56:38.000Z | apps/artemis/lib/artemis/contexts/tag/create_tag.ex | chrislaskey/artemis_teams | 9930c3d9528e37b76f0525390e32b66eed7eadde | [
"MIT"
] | 7 | 2019-07-12T21:41:01.000Z | 2020-08-17T21:29:22.000Z | apps/artemis/lib/artemis/contexts/tag/create_tag.ex | chrislaskey/artemis_teams | 9930c3d9528e37b76f0525390e32b66eed7eadde | [
"MIT"
] | 2 | 2019-07-05T22:51:47.000Z | 2019-08-19T19:56:37.000Z | defmodule Artemis.CreateTag do
use Artemis.Context
use Assoc.Updater, repo: Artemis.Repo
alias Artemis.GenerateTagParams
alias Artemis.Repo
alias Artemis.Tag
def call!(params, user) do
case call(params, user) do
{:error, _} -> raise(Artemis.Context.Error, "Error creating tag")
{:ok, result... | 21 | 71 | 0.656566 |
e85a326e28ea0338041be50c677a0582176a6a98 | 4,380 | exs | Elixir | test/ex_doc/formatter/epub/templates_test.exs | zoldar/ex_doc | f2ca5d1f4f85650b55460bc08e4d17a00f9f0d75 | [
"Apache-2.0",
"CC-BY-4.0"
] | null | null | null | test/ex_doc/formatter/epub/templates_test.exs | zoldar/ex_doc | f2ca5d1f4f85650b55460bc08e4d17a00f9f0d75 | [
"Apache-2.0",
"CC-BY-4.0"
] | 2 | 2020-12-04T22:03:31.000Z | 2022-03-02T10:00:23.000Z | test/ex_doc/formatter/epub/templates_test.exs | bonomali/ex_doc | d22cdad512fbfd8bfc44b417c680b1105c8aa19a | [
"Apache-2.0",
"CC-BY-4.0"
] | null | null | null | defmodule ExDoc.Formatter.EPUB.TemplatesTest do
use ExUnit.Case, async: true
alias ExDoc.Formatter.HTML
alias ExDoc.Formatter.EPUB.Templates
defp source_url do
"https://github.com/elixir-lang/elixir"
end
defp homepage_url do
"http://elixir-lang.org"
end
defp doc_config(config \\ []) do
d... | 32.205882 | 138 | 0.63653 |
e85a66334e9a8e19759df0badaf387c5a8bdc10d | 1,585 | ex | Elixir | web/web.ex | Croissong/nussnougat | dd669d8614029400a25cef67971ef8720f5580dd | [
"MIT"
] | null | null | null | web/web.ex | Croissong/nussnougat | dd669d8614029400a25cef67971ef8720f5580dd | [
"MIT"
] | null | null | null | web/web.ex | Croissong/nussnougat | dd669d8614029400a25cef67971ef8720f5580dd | [
"MIT"
] | null | null | null | defmodule Nussnougat.Web do
@moduledoc """
A module that keeps using definitions for controllers,
views and so on.
This can be used in your application as:
use Nussnougat.Web, :controller
use Nussnougat.Web, :view
The definitions below will be executed for every view,
controller, etc, so keep... | 20.584416 | 88 | 0.663722 |
e85a68fb2527b443f1dd9deeaadfca21e2fd4a9f | 362 | ex | Elixir | lib/parser/inform_response.ex | smiyabe/cwmp_ex | 9db322497aa3208b5985ccf496ada5286cde3925 | [
"Artistic-2.0"
] | 3 | 2017-11-29T05:07:35.000Z | 2019-12-18T17:16:41.000Z | lib/parser/inform_response.ex | smiyabe/cwmp_ex | 9db322497aa3208b5985ccf496ada5286cde3925 | [
"Artistic-2.0"
] | 1 | 2021-12-02T19:35:28.000Z | 2022-03-29T09:40:52.000Z | lib/parser/inform_response.ex | smiyabe/cwmp_ex | 9db322497aa3208b5985ccf496ada5286cde3925 | [
"Artistic-2.0"
] | 2 | 2017-11-29T05:07:30.000Z | 2020-11-10T07:10:42.000Z | defmodule CWMP.Protocol.Parser.Messages.InformResponse do
use CWMP.Protocol.ParserHelpers
alias CWMP.Protocol.Messages.InformResponse
def initial_acc do
%InformResponse{}
end
def end_element(state, ['MaxEnvelopes']) do
me=integerValue(state.last_text)
update_acc(state, fn acc -> %InformResponse{... | 22.625 | 77 | 0.754144 |
e85a8c749b6e73c48a18a219aafe108679c5d005 | 494 | exs | Elixir | config/test.exs | retgoat/band-indigo.com | b8a1cf58ec766858cc2319441fa8628ad763529a | [
"MIT"
] | null | null | null | config/test.exs | retgoat/band-indigo.com | b8a1cf58ec766858cc2319441fa8628ad763529a | [
"MIT"
] | null | null | null | config/test.exs | retgoat/band-indigo.com | b8a1cf58ec766858cc2319441fa8628ad763529a | [
"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 :band_indigo, BandIndigo.Endpoint,
http: [port: 4001],
server: false
# Print only warnings and errors during test
config :logger, level: :warn
# Configure your database
config :band_indigo, Ba... | 24.7 | 56 | 0.734818 |
e85acdc55f3c3279fc7f99cb07256ae26e435d3b | 3,246 | exs | Elixir | mix.exs | mitjok/phoenix_live_view | b396bb83d9e02c18c58039bd86fdc4835bd8e0e9 | [
"MIT"
] | null | null | null | mix.exs | mitjok/phoenix_live_view | b396bb83d9e02c18c58039bd86fdc4835bd8e0e9 | [
"MIT"
] | null | null | null | mix.exs | mitjok/phoenix_live_view | b396bb83d9e02c18c58039bd86fdc4835bd8e0e9 | [
"MIT"
] | null | null | null | defmodule Phoenix.LiveView.MixProject do
use Mix.Project
@version "0.15.3"
def project do
[
app: :phoenix_live_view,
version: @version,
elixir: "~> 1.7",
start_permanent: Mix.env() == :prod,
elixirc_paths: elixirc_paths(Mix.env()),
compilers: compilers(Mix.env()),
p... | 26.826446 | 99 | 0.597967 |
e85acf44201a79a46921f91ed54f94b507f9c8b2 | 924 | ex | Elixir | test/fixtures/my_handler.ex | NFIBrokerage/beeline_honeycomb | f64b8715289021ae0d5709a2b05a8d2d136c6481 | [
"Apache-2.0"
] | null | null | null | test/fixtures/my_handler.ex | NFIBrokerage/beeline_honeycomb | f64b8715289021ae0d5709a2b05a8d2d136c6481 | [
"Apache-2.0"
] | null | null | null | test/fixtures/my_handler.ex | NFIBrokerage/beeline_honeycomb | f64b8715289021ae0d5709a2b05a8d2d136c6481 | [
"Apache-2.0"
] | null | null | null | defmodule BeelineHoneycomb.MyHandler do
@moduledoc """
An example beeline fixture for the sake of testing which relies on the dummy
producer
"""
use Beeline
def start_link(opts) do
Beeline.start_link(__MODULE__,
name: __MODULE__,
producers: [
default: [
adapter: :dummy,
... | 24.315789 | 78 | 0.649351 |
e85adfb9142bead4d1413c138e2868fa45c479c7 | 3,640 | ex | Elixir | clients/vm_migration/lib/google_api/vm_migration/v1/model/vmware_vm_details.ex | MMore/elixir-google-api | 0574ec1439d9bbfe22d63965be1681b0f45a94c9 | [
"Apache-2.0"
] | null | null | null | clients/vm_migration/lib/google_api/vm_migration/v1/model/vmware_vm_details.ex | MMore/elixir-google-api | 0574ec1439d9bbfe22d63965be1681b0f45a94c9 | [
"Apache-2.0"
] | null | null | null | clients/vm_migration/lib/google_api/vm_migration/v1/model/vmware_vm_details.ex | MMore/elixir-google-api | 0574ec1439d9bbfe22d63965be1681b0f45a94c9 | [
"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... | 45.5 | 313 | 0.673626 |
e85b385b74bb9f9a4ac5a74446c1ce255e8eea93 | 2,393 | ex | Elixir | clients/cloud_private_catalog_producer/lib/google_api/cloud_private_catalog_producer/v1beta1/model/google_cloud_privatecatalogproducer_v1beta1_list_associations_response.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | 1 | 2021-12-20T03:40:53.000Z | 2021-12-20T03:40:53.000Z | clients/cloud_private_catalog_producer/lib/google_api/cloud_private_catalog_producer/v1beta1/model/google_cloud_privatecatalogproducer_v1beta1_list_associations_response.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | 1 | 2020-08-18T00:11:23.000Z | 2020-08-18T00:44:16.000Z | clients/cloud_private_catalog_producer/lib/google_api/cloud_private_catalog_producer/v1beta1/model/google_cloud_privatecatalogproducer_v1beta1_list_associations_response.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | 1 | 2020-10-04T10:12:44.000Z | 2020-10-04T10:12:44.000Z | # Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, s... | 35.716418 | 221 | 0.760552 |
e85b9cecec6cbe28ae1d1c9419cf3f940e621b30 | 280 | ex | Elixir | lib/oli/repo/sorting.ex | malav2110/oli-torus | 8af64e762a7c8a2058bd27a7ab8e96539ffc055f | [
"MIT"
] | 45 | 2020-04-17T15:40:27.000Z | 2022-03-25T00:13:30.000Z | lib/oli/repo/sorting.ex | malav2110/oli-torus | 8af64e762a7c8a2058bd27a7ab8e96539ffc055f | [
"MIT"
] | 944 | 2020-02-13T02:37:01.000Z | 2022-03-31T17:50:07.000Z | lib/oli/repo/sorting.ex | malav2110/oli-torus | 8af64e762a7c8a2058bd27a7ab8e96539ffc055f | [
"MIT"
] | 23 | 2020-07-28T03:36:13.000Z | 2022-03-17T14:29:02.000Z | defmodule Oli.Repo.Sorting do
@moduledoc """
Params for sorting queries.
"""
@enforce_keys [
:field,
:direction
]
defstruct [
:field,
:direction
]
@type t() :: %__MODULE__{
field: any(),
direction: :asc | :desc
}
end
| 13.333333 | 33 | 0.528571 |
e85bc7d5e3cd23446341615775b5f4816d46b18f | 7,978 | ex | Elixir | lib/cobol_to_elixir/elixirizer.ex | TheFirstAvenger/cobol_to_elixir | 549528aed3dd1de8a14bb3a763539b5cbf714811 | [
"MIT"
] | 65 | 2021-08-10T19:16:25.000Z | 2022-02-23T01:38:13.000Z | lib/cobol_to_elixir/elixirizer.ex | TheFirstAvenger/cobol_to_elixir | 549528aed3dd1de8a14bb3a763539b5cbf714811 | [
"MIT"
] | 1 | 2021-08-15T21:59:54.000Z | 2021-08-20T20:30:06.000Z | lib/cobol_to_elixir/elixirizer.ex | TheFirstAvenger/cobol_to_elixir | 549528aed3dd1de8a14bb3a763539b5cbf714811 | [
"MIT"
] | 1 | 2021-08-21T19:53:13.000Z | 2021-08-21T19:53:13.000Z | defmodule CobolToElixir.Elixirizer do
alias CobolToElixir.Parsed
alias CobolToElixir.Parsed.Variable
require Logger
def elixirize(%Parsed{program_id: program_id} = parsed, opts \\ []) do
namespace = Keyword.get(opts, :namespace, "ElixirFromCobol")
io_dir = Keyword.get(opts, :io_dir, "")
accept_via... | 31.533597 | 151 | 0.573076 |
e85bcc3512d97c8660e68de24b3d7ce24672b8c9 | 770 | ex | Elixir | lib/stylexer/tokenizer.ex | alganet/stylistex | b1ceb3b6456f841a03153d58153fc6ed1427a923 | [
"MIT"
] | null | null | null | lib/stylexer/tokenizer.ex | alganet/stylistex | b1ceb3b6456f841a03153d58153fc6ed1427a923 | [
"MIT"
] | null | null | null | lib/stylexer/tokenizer.ex | alganet/stylistex | b1ceb3b6456f841a03153d58153fc6ed1427a923 | [
"MIT"
] | null | null | null | defmodule Stylexer.Tokenizer do
@moduledoc """
Tokenize the CSS definition
"""
@typedoc """
Token definition when consuming CSS with Lexer
"""
@type token :: list({atom(), pos_integer(), char()})
@doc """
Consume the stream with UTF-8 encoding
"""
@spec consume(expression :: binary() | charlist(... | 22.647059 | 89 | 0.620779 |
e85bcef87825bbd5e10ccbac09eeab991c667f2f | 19,373 | ex | Elixir | lib/elixir/lib/module/types/pattern.ex | hassan/elixir | d002f2fd1093f37b422e424014f1cb0a7e675e79 | [
"Apache-2.0"
] | null | null | null | lib/elixir/lib/module/types/pattern.ex | hassan/elixir | d002f2fd1093f37b422e424014f1cb0a7e675e79 | [
"Apache-2.0"
] | null | null | null | lib/elixir/lib/module/types/pattern.ex | hassan/elixir | d002f2fd1093f37b422e424014f1cb0a7e675e79 | [
"Apache-2.0"
] | null | null | null | defmodule Module.Types.Pattern do
@moduledoc false
import Module.Types.{Helpers, Infer}
@doc """
Return the type and typing context of a pattern expression or an error
in case of a typing conflict.
"""
# :atom
def of_pattern(atom, _stack, context) when is_atom(atom) do
{:ok, {:atom, atom}, context... | 33.059727 | 91 | 0.579879 |
e85be060ce7a78dd95833ce1c29b51b29330bd38 | 2,197 | ex | Elixir | implementations/elixir/ockam/ockam_services/lib/services/tracing.ex | 0x00A5/ockam | 9710804e20606e70057d65c70d1af7236194aeeb | [
"Apache-2.0"
] | null | null | null | implementations/elixir/ockam/ockam_services/lib/services/tracing.ex | 0x00A5/ockam | 9710804e20606e70057d65c70d1af7236194aeeb | [
"Apache-2.0"
] | null | null | null | implementations/elixir/ockam/ockam_services/lib/services/tracing.ex | 0x00A5/ockam | 9710804e20606e70057d65c70d1af7236194aeeb | [
"Apache-2.0"
] | null | null | null | defmodule Ockam.Services.Tracing do
@moduledoc """
Tracing service.
Create watchers - workers to intercept traffic
Watchers will forward all traffic without changes
but send a copy of the payload to the tracing route.
"""
use Ockam.Worker
alias Ockam.Message
alias Ockam.Router
require Logger
... | 23.126316 | 83 | 0.694128 |
e85c08a2052105dae28a0946b9416af3a57b96e5 | 969 | ex | Elixir | lib/game/character/via.ex | shanesveller/ex_venture | 68507da11442a9e0423073fcd305e9021f649ca1 | [
"MIT"
] | null | null | null | lib/game/character/via.ex | shanesveller/ex_venture | 68507da11442a9e0423073fcd305e9021f649ca1 | [
"MIT"
] | null | null | null | lib/game/character/via.ex | shanesveller/ex_venture | 68507da11442a9e0423073fcd305e9021f649ca1 | [
"MIT"
] | null | null | null | defmodule Game.Character.Via do
@moduledoc """
Send to either a player (session) or an NPC
"""
alias Game.Session
@doc """
Find the player or NPC pid
Callback for :via GenServer lookup
"""
@spec whereis_name(any) :: pid
def whereis_name(who)
def whereis_name({:npc, id}) do
:global.whereis_... | 18.634615 | 45 | 0.587203 |
e85c39b74c813fe9d63b139c4317da353ecfde7d | 2,582 | exs | Elixir | test/test_helper.exs | ikeyasu/antikythera | 544fdd22e46b1f34177053d87d9e2a9708c74113 | [
"Apache-2.0"
] | null | null | null | test/test_helper.exs | ikeyasu/antikythera | 544fdd22e46b1f34177053d87d9e2a9708c74113 | [
"Apache-2.0"
] | null | null | null | test/test_helper.exs | ikeyasu/antikythera | 544fdd22e46b1f34177053d87d9e2a9708c74113 | [
"Apache-2.0"
] | null | null | null | # Copyright(c) 2015-2018 ACCESS CO., LTD. All rights reserved.
ExUnit.start()
defmodule ExecutorPoolHelper do
import ExUnit.Assertions
alias Antikythera.Test.{ProcessHelper, GenServerHelper}
alias AntikytheraCore.ExecutorPool
alias AntikytheraCore.ExecutorPool.RegisteredName, as: RegName
def assert_current... | 37.970588 | 135 | 0.732378 |
e85c4c7c3c6b32129311ac27e722dfb6438b8ca6 | 3,710 | ex | Elixir | clients/ad_experience_report/lib/google_api/ad_experience_report/v1/api/violating_sites.ex | kolorahl/elixir-google-api | 46bec1e092eb84c6a79d06c72016cb1a13777fa6 | [
"Apache-2.0"
] | null | null | null | clients/ad_experience_report/lib/google_api/ad_experience_report/v1/api/violating_sites.ex | kolorahl/elixir-google-api | 46bec1e092eb84c6a79d06c72016cb1a13777fa6 | [
"Apache-2.0"
] | null | null | null | clients/ad_experience_report/lib/google_api/ad_experience_report/v1/api/violating_sites.ex | kolorahl/elixir-google-api | 46bec1e092eb84c6a79d06c72016cb1a13777fa6 | [
"Apache-2.0"
] | null | null | null | # Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, s... | 42.643678 | 196 | 0.662264 |
e85c5dcab0438d6116c255a13bb68f753ac6c4a0 | 1,605 | ex | Elixir | lib/radiator/directory/audio.ex | bhtabor/radiator | 39c137a18d36d6f418f9d1ffb7aa2c99011d66cf | [
"MIT"
] | 92 | 2019-01-03T11:46:23.000Z | 2022-02-19T21:28:44.000Z | lib/radiator/directory/audio.ex | bhtabor/radiator | 39c137a18d36d6f418f9d1ffb7aa2c99011d66cf | [
"MIT"
] | 350 | 2019-04-11T07:55:51.000Z | 2021-08-03T11:19:05.000Z | lib/radiator/directory/audio.ex | bhtabor/radiator | 39c137a18d36d6f418f9d1ffb7aa2c99011d66cf | [
"MIT"
] | 10 | 2019-04-18T12:47:27.000Z | 2022-01-25T20:49:15.000Z | defmodule Radiator.Directory.Audio do
@moduledoc """
Audio Meta Object.
An Audio contains all data required to generate a web player: file references
and audio metadata.
An Audio belongs to one or many episodes, or stand on its own in a network via AudioPublication.
"""
use Ecto.Schema
import Ecto.Ch... | 23.26087 | 98 | 0.676636 |
e85c8bce6b098d3242d080154118fd58ac198e3e | 11,047 | ex | Elixir | apps/core/lib/core/services/recipes.ex | michaeljguarino/forge | 50ee583ecb4aad5dee4ef08fce29a8eaed1a0824 | [
"Apache-2.0"
] | 59 | 2021-09-16T19:29:39.000Z | 2022-03-31T20:44:24.000Z | apps/core/lib/core/services/recipes.ex | michaeljguarino/forge | 50ee583ecb4aad5dee4ef08fce29a8eaed1a0824 | [
"Apache-2.0"
] | 111 | 2021-08-15T09:56:37.000Z | 2022-03-31T23:59:32.000Z | apps/core/lib/core/services/recipes.ex | michaeljguarino/chartmart | a34c949cc29d6a1ab91c04c5e4f797e6f0daabfc | [
"Apache-2.0"
] | 4 | 2021-12-13T09:43:01.000Z | 2022-03-29T18:08:44.000Z | defmodule Core.Services.Recipes do
use Core.Services.Base
import Core.Policies.Recipe
alias Core.Schema.{Recipe, RecipeSection, RecipeItem, Installation, Terraform, Chart, User}
alias Core.Services.{Repositories, Charts, Versions}
alias Core.Services.Terraform, as: TfSvc
@spec get!(binary) :: Recipe.t
de... | 36.219672 | 124 | 0.634561 |
e85cb3fce99f35a672e4c85c4f624282144f237b | 708 | exs | Elixir | test/features/category_change_via_drag_and_drop_test.exs | codyduval/remote_retro_crd | b3a4adda7503b4e1ca5ec135cd34e1e71ec8d247 | [
"MIT"
] | null | null | null | test/features/category_change_via_drag_and_drop_test.exs | codyduval/remote_retro_crd | b3a4adda7503b4e1ca5ec135cd34e1e71ec8d247 | [
"MIT"
] | null | null | null | test/features/category_change_via_drag_and_drop_test.exs | codyduval/remote_retro_crd | b3a4adda7503b4e1ca5ec135cd34e1e71ec8d247 | [
"MIT"
] | null | null | null | defmodule CategoryChangeViaDragAndDrop do
use RemoteRetro.IntegrationCase, async: false
alias RemoteRetro.Idea
import ShorterMaps
describe "when an idea already exists in a retro" do
setup [:persist_idea_for_retro]
@tag [
idea: %Idea{category: "sad", body: "no linter"},
]
test "users ca... | 28.32 | 84 | 0.670904 |
e85cb5cdd0af73522409255bd73e5b0eff7f8f1c | 95 | ex | Elixir | lib/gen_event_sourced.ex | slashmili/gen_event_sourced | d2cfa6337256ded910b5a315169be927c9dd589b | [
"MIT"
] | null | null | null | lib/gen_event_sourced.ex | slashmili/gen_event_sourced | d2cfa6337256ded910b5a315169be927c9dd589b | [
"MIT"
] | null | null | null | lib/gen_event_sourced.ex | slashmili/gen_event_sourced | d2cfa6337256ded910b5a315169be927c9dd589b | [
"MIT"
] | null | null | null | defmodule GenEventSourced do
@moduledoc """
Documentation for `GenEventSourced`.
"""
end
| 15.833333 | 38 | 0.726316 |
e85cd56540aaf96b3c4175779f404d36bb06b607 | 612 | ex | Elixir | lib/EventStage/event_dispatcher.ex | ElinksFr/alchemy | 4c64e5c619977a62a5674dbd2b1ef29f76f6f44e | [
"MIT"
] | 163 | 2017-03-01T09:02:35.000Z | 2022-03-09T23:31:48.000Z | lib/EventStage/event_dispatcher.ex | ElinksFr/alchemy | 4c64e5c619977a62a5674dbd2b1ef29f76f6f44e | [
"MIT"
] | 91 | 2017-02-23T23:23:35.000Z | 2021-12-29T23:47:44.000Z | lib/EventStage/event_dispatcher.ex | ElinksFr/alchemy | 4c64e5c619977a62a5674dbd2b1ef29f76f6f44e | [
"MIT"
] | 38 | 2017-03-23T13:16:44.000Z | 2022-02-26T15:53:32.000Z | defmodule Alchemy.EventStage.EventDispatcher do
# Serves as a small consumer of the 3rd stage,
@moduledoc false
# forwarding events to notify processes subscribed in the EventRegistry
use GenStage
alias Alchemy.Cogs.EventRegistry
alias Alchemy.EventStage.Cacher
def start_link(limit) do
GenStage.start... | 26.608696 | 73 | 0.72549 |
e85ce9a1c0364df4cc9134d0e07ea71e825bb805 | 1,655 | ex | Elixir | clients/civic_info/lib/google_api/civic_info/v2/model/point_proto.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/civic_info/lib/google_api/civic_info/v2/model/point_proto.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/civic_info/lib/google_api/civic_info/v2/model/point_proto.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | # Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, s... | 31.226415 | 99 | 0.706949 |
e85cf05716e269038d33ebf5cb77fdc7d4b70ddd | 1,234 | ex | Elixir | apps/neoscan_web/lib/neoscan_web/channels/user_socket.ex | vincentgeneste/neo-scan | 4a654575331eeb3eb12d4fd61696a7bd6dbca3ce | [
"MIT"
] | 75 | 2017-07-23T02:45:32.000Z | 2021-12-13T11:04:17.000Z | apps/neoscan_web/lib/neoscan_web/channels/user_socket.ex | vincentgeneste/neo-scan | 4a654575331eeb3eb12d4fd61696a7bd6dbca3ce | [
"MIT"
] | 252 | 2017-07-13T19:36:00.000Z | 2021-07-28T18:40:00.000Z | apps/neoscan_web/lib/neoscan_web/channels/user_socket.ex | vincentgeneste/neo-scan | 4a654575331eeb3eb12d4fd61696a7bd6dbca3ce | [
"MIT"
] | 87 | 2017-07-23T02:45:34.000Z | 2022-03-02T14:54:27.000Z | defmodule NeoscanWeb.UserSocket do
use Phoenix.Socket
@moduledoc false
## Channels
channel("room:*", NeoscanWeb.RoomChannel)
## Transports
transport(:websocket, Phoenix.Transports.WebSocket)
# transport :longpoll, Phoenix.Transports.LongPoll
# Socket params are passed from the client and can
# be u... | 30.097561 | 67 | 0.679903 |
e85cf5c1c415dc99955612a3e70243c22c89dc91 | 1,549 | ex | Elixir | lib/renraku_web/views/error_helpers.ex | moroz/renraku | 845e6a72573f138094ba8f868ac91b7f3440bdab | [
"BSD-3-Clause"
] | null | null | null | lib/renraku_web/views/error_helpers.ex | moroz/renraku | 845e6a72573f138094ba8f868ac91b7f3440bdab | [
"BSD-3-Clause"
] | null | null | null | lib/renraku_web/views/error_helpers.ex | moroz/renraku | 845e6a72573f138094ba8f868ac91b7f3440bdab | [
"BSD-3-Clause"
] | null | null | null | defmodule RenrakuWeb.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_tag(... | 32.270833 | 76 | 0.665591 |
e85cf7ac78389ffddc69541b1af1603f3e3fdb14 | 82 | exs | Elixir | test/bus_kiosk_web/views/page_view_test.exs | mitchellhenke/bus_kiosk | 9814b0b10190bb06c823b00315616391100c5bfa | [
"BSD-3-Clause"
] | 2 | 2020-02-21T15:40:27.000Z | 2020-12-06T21:50:39.000Z | test/bus_kiosk_web/views/page_view_test.exs | mitchellhenke/bus_kiosk | 9814b0b10190bb06c823b00315616391100c5bfa | [
"BSD-3-Clause"
] | 3 | 2020-02-19T17:06:24.000Z | 2020-04-20T14:33:07.000Z | test/bus_kiosk_web/views/page_view_test.exs | mitchellhenke/bus_kiosk | 9814b0b10190bb06c823b00315616391100c5bfa | [
"BSD-3-Clause"
] | null | null | null | defmodule BusKioskWeb.PageViewTest do
use BusKioskWeb.ConnCase, async: true
end
| 20.5 | 39 | 0.829268 |
e85cfc3daf112eadb51c2856f332136b9a9bb533 | 9,806 | ex | Elixir | lib/elixir/lib/integer.ex | davidsulc/elixir | dd4fd6ab742acd75862e34e26dbdb86e0cf6453f | [
"Apache-2.0"
] | null | null | null | lib/elixir/lib/integer.ex | davidsulc/elixir | dd4fd6ab742acd75862e34e26dbdb86e0cf6453f | [
"Apache-2.0"
] | null | null | null | lib/elixir/lib/integer.ex | davidsulc/elixir | dd4fd6ab742acd75862e34e26dbdb86e0cf6453f | [
"Apache-2.0"
] | null | null | null | defmodule Integer do
@moduledoc """
Functions for working with integers.
"""
import Bitwise
@doc """
Determines if `integer` is odd.
Returns `true` if the given `integer` is an odd number,
otherwise it returns `false`.
Allowed in guard clauses.
## Examples
iex> Integer.is_odd(5)
tr... | 22.964871 | 99 | 0.628697 |
e85d337e1e3c896c51080001c623e46b588e98fd | 12,148 | ex | Elixir | lib/pardall_markdown/cache.ex | rockchalkwushock/pardall_markdown | 82188d6090a419f346618997d40539a0435ea4d5 | [
"Apache-2.0"
] | 75 | 2021-09-11T15:36:34.000Z | 2022-03-28T17:21:55.000Z | lib/pardall_markdown/cache.ex | rockchalkwushock/pardall_markdown | 82188d6090a419f346618997d40539a0435ea4d5 | [
"Apache-2.0"
] | 33 | 2021-09-11T15:34:29.000Z | 2021-11-21T03:47:05.000Z | lib/pardall_markdown/cache.ex | rockchalkwushock/pardall_markdown | 82188d6090a419f346618997d40539a0435ea4d5 | [
"Apache-2.0"
] | 4 | 2021-09-27T03:34:35.000Z | 2022-01-31T23:42:58.000Z | defmodule PardallMarkdown.Cache do
require Logger
alias PardallMarkdown.Content.{Post, Link}
import PardallMarkdown.Content.Filters
import PardallMarkdown.Content.Utils
@cache_name Application.get_env(:pardall_markdown, PardallMarkdown.Content)[:cache_name]
@index_cache_name Application.get_env(:pardall_ma... | 26.294372 | 97 | 0.601169 |
e85d3a4eb276dd20f978f1d265a6bfb8cd1f4b91 | 1,704 | ex | Elixir | clients/games/lib/google_api/games/v1/model/player_name.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/games/lib/google_api/games/v1/model/player_name.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/games/lib/google_api/games/v1/model/player_name.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... | 34.08 | 139 | 0.721831 |
e85d9665cc552487deff782f8a8679cd1918f7d3 | 1,461 | exs | Elixir | test/gradient/elixir_checker_test.exs | esl/gradient | 822da399872a38b77440858971f4147694e85fac | [
"Apache-2.0"
] | 75 | 2021-11-17T11:55:13.000Z | 2022-03-28T04:35:04.000Z | test/gradient/elixir_checker_test.exs | esl/gradient | 822da399872a38b77440858971f4147694e85fac | [
"Apache-2.0"
] | 48 | 2021-11-15T13:56:14.000Z | 2022-03-31T15:55:47.000Z | test/gradient/elixir_checker_test.exs | esl/gradient | 822da399872a38b77440858971f4147694e85fac | [
"Apache-2.0"
] | 6 | 2021-12-22T20:41:27.000Z | 2022-03-09T09:07:38.000Z | defmodule Gradient.ElixirCheckerTest do
use ExUnit.Case
doctest Gradient.ElixirChecker
alias Gradient.ElixirChecker
import Gradient.TestHelpers
test "checker options" do
ast = load("Elixir.SpecWrongName.beam")
assert [] = ElixirChecker.check(ast, ex_check: false)
assert [] != ElixirChecker.che... | 27.566038 | 67 | 0.645448 |
e85d9bf9014f6f9cb1b81d51054457c1ab2eea7c | 2,032 | exs | Elixir | mix.exs | DylanGuedes/forensic | 16ea59bb6aeefe636012b747a7caab26e0b7f686 | [
"Apache-2.0"
] | null | null | null | mix.exs | DylanGuedes/forensic | 16ea59bb6aeefe636012b747a7caab26e0b7f686 | [
"Apache-2.0"
] | null | null | null | mix.exs | DylanGuedes/forensic | 16ea59bb6aeefe636012b747a7caab26e0b7f686 | [
"Apache-2.0"
] | null | null | null | defmodule Forensic.Mixfile do
use Mix.Project
def project do
[app: :forensic,
version: "0.0.1",
elixir: "~> 1.2",
elixirc_paths: elixirc_paths(Mix.env),
compilers: [:phoenix, :gettext] ++ Mix.compilers,
test_coverage: [tool: ExCoveralls],
preferred_cli_env: ["coveralls": :test, "c... | 31.75 | 122 | 0.590059 |
e85dc090f576a5827d1f0a699f56675711d80ac5 | 324 | exs | Elixir | test/advent_of_code/day_13_test.exs | MarcusCemes/advent-of-code-2021 | 703aff2701be89031631342a094ae6976e7d3c1b | [
"MIT"
] | 1 | 2021-12-19T04:13:00.000Z | 2021-12-19T04:13:00.000Z | test/advent_of_code/day_13_test.exs | MarcusCemes/advent-of-code-2021 | 703aff2701be89031631342a094ae6976e7d3c1b | [
"MIT"
] | null | null | null | test/advent_of_code/day_13_test.exs | MarcusCemes/advent-of-code-2021 | 703aff2701be89031631342a094ae6976e7d3c1b | [
"MIT"
] | 1 | 2021-12-15T19:15:20.000Z | 2021-12-15T19:15:20.000Z | defmodule AdventOfCode.Day13Test do
use ExUnit.Case
import AdventOfCode.Day13
import AdventOfCode.Utils
test "part1" do
input = read_data(13, :sample)
result = part1(input)
assert result == 17
end
@tag :skip
test "part2" do
input = nil
result = part2(input)
assert result
end
... | 15.428571 | 35 | 0.669753 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.