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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
7374a466d820e6601bd666aceac8118aa7ea56d2 | 1,224 | exs | Elixir | mix.exs | lkoller/open_graph | 21e218b44dfabb10cd364c71f070da9d48a9a63c | [
"MIT"
] | null | null | null | mix.exs | lkoller/open_graph | 21e218b44dfabb10cd364c71f070da9d48a9a63c | [
"MIT"
] | null | null | null | mix.exs | lkoller/open_graph | 21e218b44dfabb10cd364c71f070da9d48a9a63c | [
"MIT"
] | null | null | null | defmodule OpenGraph.Mixfile do
use Mix.Project
def project do
[
app: :open_graph,
version: "0.0.3",
elixir: "~> 1.8",
build_embedded: Mix.env() == :prod,
start_permanent: Mix.env() == :prod,
deps: deps(),
description: description(),
package: package()
]
end... | 21.857143 | 77 | 0.571895 |
7374b301cc48e50baa0f562a8bc0528a7dbc7fce | 561 | exs | Elixir | test/views/error_view_test.exs | silppuri/daily | a31034dedbcc2eb74bd2e07e703df836c5b3607f | [
"MIT"
] | null | null | null | test/views/error_view_test.exs | silppuri/daily | a31034dedbcc2eb74bd2e07e703df836c5b3607f | [
"MIT"
] | null | null | null | test/views/error_view_test.exs | silppuri/daily | a31034dedbcc2eb74bd2e07e703df836c5b3607f | [
"MIT"
] | 1 | 2019-09-05T12:37:23.000Z | 2019-09-05T12:37:23.000Z | defmodule Daily.ErrorViewTest do
use DailyWeb.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(Daily.ErrorView, "404.html", []) ==
"Page not found"
end
test "render 500.html" do
... | 25.5 | 66 | 0.672014 |
7374cc576eb721320c79edb53eeb5a9aaa357923 | 3,748 | exs | Elixir | test/httpoison/retry_test.exs | everilae/httpoison_retry | aa11029bf7a7f0169d76ed8749ad7a8203ccaf7b | [
"MIT"
] | null | null | null | test/httpoison/retry_test.exs | everilae/httpoison_retry | aa11029bf7a7f0169d76ed8749ad7a8203ccaf7b | [
"MIT"
] | null | null | null | test/httpoison/retry_test.exs | everilae/httpoison_retry | aa11029bf7a7f0169d76ed8749ad7a8203ccaf7b | [
"MIT"
] | 1 | 2019-12-29T05:32:23.000Z | 2019-12-29T05:32:23.000Z | defmodule HTTPoison.RetryTest do
use ExUnit.Case
import HTTPoison.Retry
doctest HTTPoison.Retry
test "max_attempts" do
{:ok, agent} = Agent.start fn -> 0 end
request = fn ->
Agent.update agent, fn(i) -> i + 1 end
{:error, %HTTPoison.Error{id: nil, reason: :nxdomain}}
end
assert {:er... | 33.464286 | 114 | 0.60032 |
7374d29c3f8dc2e58f25fc50d320a50619b6650b | 2,490 | exs | Elixir | ros/ros_ui_station/config/prod.exs | kujua/elixir-handbook | 4185ad8da7f652fdb59c799dc58bcb33fda10475 | [
"Apache-2.0"
] | 1 | 2019-07-01T18:47:28.000Z | 2019-07-01T18:47:28.000Z | ros/ros_ui_station/config/prod.exs | kujua/elixir-handbook | 4185ad8da7f652fdb59c799dc58bcb33fda10475 | [
"Apache-2.0"
] | 4 | 2020-07-17T16:57:18.000Z | 2021-05-09T23:50:52.000Z | ros/ros_ui_station/config/prod.exs | kujua/elixir-handbook | 4185ad8da7f652fdb59c799dc58bcb33fda10475 | [
"Apache-2.0"
] | null | null | null | use Mix.Config
# For production, don't forget to configure the url host
# to something meaningful, Phoenix uses this information
# when generating URLs.
#
# Note we also include the path to a cache manifest
# containing the digested version of static files. This
# manifest is generated by the `mix phx.digest` task,
# ... | 34.583333 | 69 | 0.716466 |
7374e6a11bc21474471e43d67501401f7887f966 | 115 | exs | Elixir | tests/examples/elixir/std/test.expected/app/user_test.exs | rogeriochaves/un | 5825fffd560951c61294b39c3d52e220bf729a40 | [
"MIT"
] | 4 | 2020-07-24T06:56:01.000Z | 2021-01-02T23:31:26.000Z | tests/examples/elixir/std/test.expected/app/user_test.exs | rogeriochaves/un | 5825fffd560951c61294b39c3d52e220bf729a40 | [
"MIT"
] | 3 | 2020-10-08T17:28:13.000Z | 2021-11-07T23:57:44.000Z | tests/examples/elixir/std/test.expected/app/user_test.exs | rogeriochaves/unit | 5825fffd560951c61294b39c3d52e220bf729a40 | [
"MIT"
] | null | null | null | defmodule App.UserTest do
use ExUnit.Case
alias App.User
test "it works" do
assert 1 + 1 == 2
end
end
| 12.777778 | 25 | 0.652174 |
7374f2f3662530e19388603c4bb096be1742a0da | 3,606 | ex | Elixir | lib/adaptable_costs_evaluator/computations.ex | patrotom/adaptable-costs-evaluator | c97e65af1e021d7c6acf6564f4671c60321346e3 | [
"MIT"
] | null | null | null | lib/adaptable_costs_evaluator/computations.ex | patrotom/adaptable-costs-evaluator | c97e65af1e021d7c6acf6564f4671c60321346e3 | [
"MIT"
] | 4 | 2021-12-07T12:26:50.000Z | 2021-12-30T14:17:25.000Z | lib/adaptable_costs_evaluator/computations.ex | patrotom/adaptable-costs-evaluator | c97e65af1e021d7c6acf6564f4671c60321346e3 | [
"MIT"
] | null | null | null | defmodule AdaptableCostsEvaluator.Computations do
@moduledoc """
The Computations context.
"""
import Ecto.Query, warn: false
alias AdaptableCostsEvaluator.Repo
alias AdaptableCostsEvaluator.Computations.Computation
alias AdaptableCostsEvaluator.Users.User
alias AdaptableCostsEvaluator.{Users, Organiz... | 24.868966 | 87 | 0.682751 |
737500af951ab424a12577e6980583074dd6f1c7 | 679 | ex | Elixir | kubeojo/lib/jenkins/jenkins_junit_filter.ex | marcosvm/kubeojo | 61182997a9e27ac100c79e854f2d79bb8b5c6818 | [
"MIT"
] | null | null | null | kubeojo/lib/jenkins/jenkins_junit_filter.ex | marcosvm/kubeojo | 61182997a9e27ac100c79e854f2d79bb8b5c6818 | [
"MIT"
] | null | null | null | kubeojo/lib/jenkins/jenkins_junit_filter.ex | marcosvm/kubeojo | 61182997a9e27ac100c79e854f2d79bb8b5c6818 | [
"MIT"
] | null | null | null | # filter junit data
defmodule Kubeojo.Jenkins.JunitParser do
def name_and_status(%{"suites" => suites}) do
status = get_in(suites, [Access.all(), "cases", Access.all(), "status"]) |> List.flatten()
name = get_in(suites, [Access.all(), "cases", Access.all(), "name"]) |> List.flatten()
Enum.zip(name, status... | 32.333333 | 94 | 0.643594 |
73755c810642d297bb983d2dd37d45e58f1bf207 | 198 | exs | Elixir | priv/repo/migrations/20200302182818_add_suspended_boolean_to_user.exs | smartlogic/Challenge_gov | b4203d1fcfb742dd17ecfadb9e9c56ad836d4254 | [
"CC0-1.0"
] | 9 | 2020-02-26T20:24:38.000Z | 2022-03-22T21:14:52.000Z | priv/repo/migrations/20200302182818_add_suspended_boolean_to_user.exs | smartlogic/Challenge_gov | b4203d1fcfb742dd17ecfadb9e9c56ad836d4254 | [
"CC0-1.0"
] | 15 | 2020-04-22T19:33:24.000Z | 2022-03-26T15:11:17.000Z | priv/repo/migrations/20200302182818_add_suspended_boolean_to_user.exs | smartlogic/Challenge_gov | b4203d1fcfb742dd17ecfadb9e9c56ad836d4254 | [
"CC0-1.0"
] | 4 | 2020-04-27T22:58:57.000Z | 2022-01-14T13:42:09.000Z | defmodule ChallengeGov.Repo.Migrations.AddSuspendedBooleanToUser do
use Ecto.Migration
def change do
alter table(:users) do
add :suspended, :boolean, default: false
end
end
end
| 19.8 | 67 | 0.737374 |
73759812469a51b54cd9b6470a6396dbfca30adf | 1,839 | ex | Elixir | clients/document_ai/lib/google_api/document_ai/v1beta2/model/google_cloud_documentai_v1beta1_document_entity_relation.ex | MasashiYokota/elixir-google-api | 975dccbff395c16afcb62e7a8e411fbb58e9ab01 | [
"Apache-2.0"
] | null | null | null | clients/document_ai/lib/google_api/document_ai/v1beta2/model/google_cloud_documentai_v1beta1_document_entity_relation.ex | MasashiYokota/elixir-google-api | 975dccbff395c16afcb62e7a8e411fbb58e9ab01 | [
"Apache-2.0"
] | 1 | 2020-12-18T09:25:12.000Z | 2020-12-18T09:25:12.000Z | clients/document_ai/lib/google_api/document_ai/v1beta2/model/google_cloud_documentai_v1beta1_document_entity_relation.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... | 31.706897 | 98 | 0.725938 |
7375a95f24339d8147a3262b4bd594d089339ebf | 9,601 | exs | Elixir | test/epicenter_web/live/case_investigation_clinical_details_live_test.exs | geometricservices/epi-viewpoin | ecb5316ea0f3f7299d5ff63e2de588539005ac1c | [
"Apache-2.0"
] | 5 | 2021-02-25T18:43:09.000Z | 2021-02-27T06:00:35.000Z | test/epicenter_web/live/case_investigation_clinical_details_live_test.exs | geometricservices/epi-viewpoint | ecb5316ea0f3f7299d5ff63e2de588539005ac1c | [
"Apache-2.0"
] | 3 | 2021-12-13T17:52:47.000Z | 2021-12-17T01:35:31.000Z | test/epicenter_web/live/case_investigation_clinical_details_live_test.exs | geometricservices/epi-viewpoint | ecb5316ea0f3f7299d5ff63e2de588539005ac1c | [
"Apache-2.0"
] | 1 | 2022-01-27T23:26:38.000Z | 2022-01-27T23:26:38.000Z | defmodule EpicenterWeb.CaseInvestigationClinicalDetailsLiveTest do
use EpicenterWeb.ConnCase, async: true
alias Epicenter.Cases
alias Epicenter.Test
alias EpicenterWeb.Test.Pages
import Epicenter.Test.RevisionAssertions
setup :register_and_log_in_user
setup %{user: user} do
person = Test.Fixtures.... | 39.673554 | 142 | 0.68722 |
7375af3103a4aab71e4645771935f3275d8efd42 | 1,736 | ex | Elixir | lib/distcount_web.ex | cabol/distcount | b0b42f66dcc130ec6e349ab8b915cfb6f5b77c7b | [
"MIT"
] | null | null | null | lib/distcount_web.ex | cabol/distcount | b0b42f66dcc130ec6e349ab8b915cfb6f5b77c7b | [
"MIT"
] | null | null | null | lib/distcount_web.ex | cabol/distcount | b0b42f66dcc130ec6e349ab8b915cfb6f5b77c7b | [
"MIT"
] | null | null | null | defmodule DistcountWeb do
@moduledoc """
The entrypoint for defining your web interface, such
as controllers, views, channels and so on.
This can be used in your application as:
use DistcountWeb, :controller
use DistcountWeb, :view
The definitions below will be executed for every view,
contro... | 22.842105 | 76 | 0.689516 |
7375d80f681794d96b540dc4f8dd3ecfc7d1578e | 1,044 | exs | Elixir | chapter13/issues/mix.exs | PaoloLaurenti/programming_elixir | b243097dafac7d95632ada1035e8ab62248bbff6 | [
"MIT"
] | null | null | null | chapter13/issues/mix.exs | PaoloLaurenti/programming_elixir | b243097dafac7d95632ada1035e8ab62248bbff6 | [
"MIT"
] | null | null | null | chapter13/issues/mix.exs | PaoloLaurenti/programming_elixir | b243097dafac7d95632ada1035e8ab62248bbff6 | [
"MIT"
] | 2 | 2018-03-22T01:47:28.000Z | 2018-06-29T00:37:22.000Z | defmodule Issues.Mixfile do
use Mix.Project
def project do
[
app: :issues,
escript: escript_config(),
version: "0.0.1",
name: "Issues",
source: "https://github.com/pragdave/issues",
build_embedded: Mix.env == :prod,
star... | 22.695652 | 77 | 0.538314 |
7375e2baaa79ac5ada58b86ae8266c416ccd33d2 | 10,979 | ex | Elixir | lib/aws/generated/lookout_metrics.ex | justinludwig/aws-elixir | c66dfebecec62587dada50602c31c76d307d812c | [
"Apache-2.0"
] | null | null | null | lib/aws/generated/lookout_metrics.ex | justinludwig/aws-elixir | c66dfebecec62587dada50602c31c76d307d812c | [
"Apache-2.0"
] | null | null | null | lib/aws/generated/lookout_metrics.ex | justinludwig/aws-elixir | c66dfebecec62587dada50602c31c76d307d812c | [
"Apache-2.0"
] | null | null | null | # WARNING: DO NOT EDIT, AUTO-GENERATED CODE!
# See https://github.com/aws-beam/aws-codegen for more details.
defmodule AWS.LookoutMetrics do
@moduledoc """
This is the *Amazon Lookout for Metrics API Reference*.
For an introduction to the service with tutorials for getting started, visit
[Amazon Lookout for M... | 19.194056 | 102 | 0.57355 |
7375e6d7ce20e6d5cefee8c43a9ff5c8369d258b | 8,257 | ex | Elixir | lib/data/chunk_reader.ex | bzzt/bigtable | 215b104a60596dde6cd459efb73baf8bccdb6b50 | [
"MIT"
] | 17 | 2019-01-22T12:59:38.000Z | 2021-12-13T10:41:52.000Z | lib/data/chunk_reader.ex | bzzt/bigtable | 215b104a60596dde6cd459efb73baf8bccdb6b50 | [
"MIT"
] | 17 | 2019-01-27T18:11:33.000Z | 2020-02-24T10:16:08.000Z | lib/data/chunk_reader.ex | bzzt/bigtable | 215b104a60596dde6cd459efb73baf8bccdb6b50 | [
"MIT"
] | 3 | 2019-02-04T17:08:09.000Z | 2021-04-07T07:13:53.000Z | defmodule Bigtable.ChunkReader do
@moduledoc """
Reads chunks from `Google.Bigtable.V2.ReadRowsResponse` and parses them into complete cells grouped by rowkey.
"""
use Agent, restart: :temporary
defmodule ReadCell do
@moduledoc """
A finished cell produced by `Bigtable.ChunkReader`.
"""
@typ... | 22.621918 | 112 | 0.577449 |
73760a6613d3b3b944c481b99de273b6526bf391 | 2,151 | ex | Elixir | lib/multi_tenancex_web/controllers/admin/company_controller.ex | dreamingechoes/multi_tenancex | cfe3feb6b7eb25559f9abaa4da89e4aafc9ad2ec | [
"MIT"
] | 30 | 2018-06-27T17:51:53.000Z | 2021-04-24T03:17:55.000Z | lib/multi_tenancex_web/controllers/admin/company_controller.ex | dreamingechoes/multi_tenancex | cfe3feb6b7eb25559f9abaa4da89e4aafc9ad2ec | [
"MIT"
] | null | null | null | lib/multi_tenancex_web/controllers/admin/company_controller.ex | dreamingechoes/multi_tenancex | cfe3feb6b7eb25559f9abaa4da89e4aafc9ad2ec | [
"MIT"
] | 7 | 2018-07-24T17:56:14.000Z | 2019-12-31T02:10:13.000Z | defmodule MultiTenancexWeb.Admin.CompanyController do
use MultiTenancexWeb, :controller
alias MultiTenancex.Companies
alias MultiTenancex.Companies.Company
def index(conn, _params) do
companies = Companies.list_companies(conn.assigns.current_tenant)
render(conn, "index.html", companies: companies)
e... | 31.173913 | 73 | 0.667132 |
73765c9e8e8a5801e9cade790798361eb0dad2c9 | 534 | ex | Elixir | lib/arrow_web/views/api/disruption_revision_view.ex | paulswartz/arrow | c1ba1ce52107c0ed94ce9bca2fef2bfeb606b8f9 | [
"MIT"
] | null | null | null | lib/arrow_web/views/api/disruption_revision_view.ex | paulswartz/arrow | c1ba1ce52107c0ed94ce9bca2fef2bfeb606b8f9 | [
"MIT"
] | null | null | null | lib/arrow_web/views/api/disruption_revision_view.ex | paulswartz/arrow | c1ba1ce52107c0ed94ce9bca2fef2bfeb606b8f9 | [
"MIT"
] | null | null | null | defmodule ArrowWeb.API.DisruptionRevisionView do
use ArrowWeb, :view
use JaSerializer.PhoenixView
attributes([:start_date, :end_date, :is_active, :inserted_at])
has_many :adjustments,
serializer: ArrowWeb.API.AdjustmentView,
include: true
has_many :days_of_week,
serializer: ArrowWeb.API.DayOfWe... | 23.217391 | 64 | 0.752809 |
7376838762751ea6220c4a8d900962b638c23d01 | 12,499 | ex | Elixir | clients/compute/lib/google_api/compute/v1/api/routes.ex | leandrocp/elixir-google-api | a86e46907f396d40aeff8668c3bd81662f44c71e | [
"Apache-2.0"
] | null | null | null | clients/compute/lib/google_api/compute/v1/api/routes.ex | leandrocp/elixir-google-api | a86e46907f396d40aeff8668c3bd81662f44c71e | [
"Apache-2.0"
] | null | null | null | clients/compute/lib/google_api/compute/v1/api/routes.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... | 53.643777 | 1,213 | 0.703096 |
737683db20038cae19173c873e7be51c4c539113 | 78 | exs | Elixir | test/pelemay_test.exs | muramasa8191/pelemay | f6b51ad8acc9b6fc66280e238a67364293b2b7d5 | [
"Apache-2.0"
] | null | null | null | test/pelemay_test.exs | muramasa8191/pelemay | f6b51ad8acc9b6fc66280e238a67364293b2b7d5 | [
"Apache-2.0"
] | null | null | null | test/pelemay_test.exs | muramasa8191/pelemay | f6b51ad8acc9b6fc66280e238a67364293b2b7d5 | [
"Apache-2.0"
] | null | null | null | defmodule PelemayTest do
use ExUnit.Case, async: true
doctest Pelemay
end
| 15.6 | 30 | 0.782051 |
7376abb2b30ec50d85e6940ec2675926219f16e7 | 23,612 | ex | Elixir | lib/uuid.ex | ryanwinchester/elixir-uuids | e51629e88331d82ce8099da7cdd5dd8263b69c0d | [
"Apache-2.0"
] | 7 | 2020-10-15T01:39:48.000Z | 2022-03-24T16:26:23.000Z | lib/uuid.ex | ryanwinchester/elixir-uuids | e51629e88331d82ce8099da7cdd5dd8263b69c0d | [
"Apache-2.0"
] | 11 | 2020-10-14T17:44:23.000Z | 2021-03-12T19:51:39.000Z | lib/uuid.ex | ryanwinchester/elixir-uuids | e51629e88331d82ce8099da7cdd5dd8263b69c0d | [
"Apache-2.0"
] | null | null | null | defmodule UUID do
@moduledoc """
UUID generator and utilities for [Elixir](http://elixir-lang.org/).
See [RFC 4122](http://www.ietf.org/rfc/rfc4122.txt).
"""
use Bitwise, only_operators: true
alias UUID.Info
@typedoc "One of representations of UUID."
@type t :: str | raw | hex | urn | slug
@typedo... | 30.664935 | 117 | 0.60626 |
7376b9ed6a5b2d584cc1cbcaa8d9753d61962a9b | 1,746 | ex | Elixir | clients/bigtable_admin/lib/google_api/bigtable_admin/v2/model/restore_info.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2021-12-20T03:40:53.000Z | 2021-12-20T03:40:53.000Z | clients/bigtable_admin/lib/google_api/bigtable_admin/v2/model/restore_info.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2020-08-18T00:11:23.000Z | 2020-08-18T00:44:16.000Z | clients/bigtable_admin/lib/google_api/bigtable_admin/v2/model/restore_info.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... | 34.92 | 184 | 0.73425 |
7376bba19fb82bdcf594655f2e9d0f3e35bdc8ba | 283 | exs | Elixir | backend/priv/repo/migrations/20190801185906_add_batch_size_and_spawn_columns.exs | ui-icts/aptamer-web | a28502c22a4e55ab1fbae8bbeaa6b11c9a477c06 | [
"MIT"
] | null | null | null | backend/priv/repo/migrations/20190801185906_add_batch_size_and_spawn_columns.exs | ui-icts/aptamer-web | a28502c22a4e55ab1fbae8bbeaa6b11c9a477c06 | [
"MIT"
] | 7 | 2019-02-08T18:28:49.000Z | 2022-02-12T06:44:59.000Z | backend/priv/repo/migrations/20190801185906_add_batch_size_and_spawn_columns.exs | ui-icts/aptamer-web | a28502c22a4e55ab1fbae8bbeaa6b11c9a477c06 | [
"MIT"
] | null | null | null | defmodule Aptamer.Repo.Migrations.AddBatchSizeAndSpawnColumns do
use Ecto.Migration
def change do
alter table(:create_graph_options) do
add(:spawn, :boolean, default: true, null: false)
add(:batch_size, :integer, default: 10_000, null: false)
end
end
end
| 23.583333 | 64 | 0.720848 |
7376e5a7f301575543efb894e1364fb081639119 | 1,477 | ex | Elixir | pub_sub_test/lib/pub_sub_test_web/endpoint.ex | KeenMate/phoenix-websocket-auction | 412148ad5621b511c0690b9395f4b6c9ce3a3352 | [
"MIT"
] | null | null | null | pub_sub_test/lib/pub_sub_test_web/endpoint.ex | KeenMate/phoenix-websocket-auction | 412148ad5621b511c0690b9395f4b6c9ce3a3352 | [
"MIT"
] | null | null | null | pub_sub_test/lib/pub_sub_test_web/endpoint.ex | KeenMate/phoenix-websocket-auction | 412148ad5621b511c0690b9395f4b6c9ce3a3352 | [
"MIT"
] | null | null | null | defmodule PubSubTestWeb.Endpoint do
use Phoenix.Endpoint, otp_app: :pub_sub_test
# The session will be stored in the cookie and signed,
# this means its contents can be read but not tampered with.
# Set :encryption_salt if you would also like to encrypt it.
@session_options [
store: :cookie,
key: "_p... | 28.403846 | 97 | 0.716994 |
7376f1541cd9d1d625d013e26ead2e4a5d391780 | 2,396 | ex | Elixir | lib/knock.ex | aglassman/knock-elixir | 2bd813f2e34d635dbd2634d6b0961dadeff02f8d | [
"MIT"
] | 11 | 2021-05-10T10:31:17.000Z | 2022-03-22T18:29:31.000Z | lib/knock.ex | aglassman/knock-elixir | 2bd813f2e34d635dbd2634d6b0961dadeff02f8d | [
"MIT"
] | 1 | 2021-11-04T21:34:34.000Z | 2021-11-04T21:34:34.000Z | lib/knock.ex | aglassman/knock-elixir | 2bd813f2e34d635dbd2634d6b0961dadeff02f8d | [
"MIT"
] | 3 | 2021-11-01T22:36:56.000Z | 2022-03-24T09:50:19.000Z | defmodule Knock do
@moduledoc """
Official SDK for interacting with Knock.
## Example usage
### As a module
The recommended way to configure Knock is as a module in your application. Doing so will
allow you to customize the options via configuration in your app.
```elixir
# lib/my_app/knock.ex
de... | 25.763441 | 123 | 0.670701 |
7376f5397fe76bd40d50e5e7fcb4fd956f912799 | 1,040 | ex | Elixir | bricks/lib/errors/unknown_options.ex | jjl/bricks.ex | 318db55c0b316fe88c701a962d8a3fd24019130e | [
"Apache-2.0"
] | null | null | null | bricks/lib/errors/unknown_options.ex | jjl/bricks.ex | 318db55c0b316fe88c701a962d8a3fd24019130e | [
"Apache-2.0"
] | null | null | null | bricks/lib/errors/unknown_options.ex | jjl/bricks.ex | 318db55c0b316fe88c701a962d8a3fd24019130e | [
"Apache-2.0"
] | null | null | null | # Copyright (c) 2018 James Laver
#
# 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 wr... | 31.515152 | 74 | 0.720192 |
7376fe06cda2437a4cff6dcd62cd1091a9b762f0 | 473 | ex | Elixir | lib/absinthe_trace_reporter/context.ex | maartenvanvliet/absinthe_trace_reporter | 237d508286b63f09862aec11accfe183b0792876 | [
"MIT"
] | 11 | 2018-12-13T08:40:48.000Z | 2020-11-10T00:06:18.000Z | lib/absinthe_trace_reporter/context.ex | maartenvanvliet/absinthe_trace_reporter | 237d508286b63f09862aec11accfe183b0792876 | [
"MIT"
] | 14 | 2019-02-27T04:25:35.000Z | 2021-12-20T04:02:05.000Z | lib/absinthe_trace_reporter/context.ex | maartenvanvliet/absinthe_trace_reporter | 237d508286b63f09862aec11accfe183b0792876 | [
"MIT"
] | 2 | 2019-03-23T18:44:11.000Z | 2020-05-27T14:07:41.000Z | defmodule AbsintheTraceReporter.Context do
def init(opts), do: opts
def call(conn, _) do
info = build_trace_info(conn)
conn = Absinthe.Plug.put_options(conn, %{a: 1})
options = Map.merge(conn.private[:absinthe], info)
conn = Absinthe.Plug.put_options(conn, context: options)
end
def build_trace... | 22.52381 | 60 | 0.638478 |
73771b3e817fe6cdb63d74d1048cb3fc23529277 | 1,822 | exs | Elixir | test/core/sup_tree_core/executor_pool/usage_reporter_test.exs | sylph01/antikythera | 47a93f3d4c70975f7296725c9bde2ea823867436 | [
"Apache-2.0"
] | 144 | 2018-04-27T07:24:49.000Z | 2022-03-15T05:19:37.000Z | test/core/sup_tree_core/executor_pool/usage_reporter_test.exs | sylph01/antikythera | 47a93f3d4c70975f7296725c9bde2ea823867436 | [
"Apache-2.0"
] | 123 | 2018-05-01T02:54:43.000Z | 2022-01-28T01:30:52.000Z | test/core/sup_tree_core/executor_pool/usage_reporter_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 AntikytheraCore.ExecutorPool.UsageReporterTest do
use Croma.TestCase
alias Antikythera.Time
alias Antikythera.Test.ProcessHelper
alias Antikythera.Test.GenServerHelper
alias AntikytheraCore.ExecutorPool
alias AntikytheraCore.ExecutorP... | 39.608696 | 93 | 0.717344 |
73775aab048d1c6dc7f89b2b9dfaada69a98f8a4 | 256 | ex | Elixir | lib/liquex/render/tag.ex | merchant-ly/liquex | 3ba72f82e9c2c57f11ef045a2028a5fc1add0d93 | [
"MIT"
] | 19 | 2020-02-29T01:37:11.000Z | 2022-03-15T06:45:20.000Z | lib/liquex/render/tag.ex | merchant-ly/liquex | 3ba72f82e9c2c57f11ef045a2028a5fc1add0d93 | [
"MIT"
] | 19 | 2020-09-02T19:35:08.000Z | 2022-03-31T21:42:16.000Z | lib/liquex/render/tag.ex | merchant-ly/liquex | 3ba72f82e9c2c57f11ef045a2028a5fc1add0d93 | [
"MIT"
] | 4 | 2020-10-20T08:22:43.000Z | 2022-01-19T17:21:32.000Z | defmodule Liquex.Render.Tag do
@moduledoc false
@behaviour Liquex.Render
@impl Liquex.Render
def render({{:custom_tag, module}, contents}, context) when is_atom(module),
do: module.render(contents, context)
def render(_, _), do: false
end
| 21.333333 | 78 | 0.71875 |
73775b50c1369e15886e08a19f6cda13ed9d4696 | 128,197 | ex | Elixir | clients/app_engine/lib/google_api/app_engine/v1/api/apps.ex | matehat/elixir-google-api | c1b2523c2c4cdc9e6ca4653ac078c94796b393c3 | [
"Apache-2.0"
] | null | null | null | clients/app_engine/lib/google_api/app_engine/v1/api/apps.ex | matehat/elixir-google-api | c1b2523c2c4cdc9e6ca4653ac078c94796b393c3 | [
"Apache-2.0"
] | null | null | null | clients/app_engine/lib/google_api/app_engine/v1/api/apps.ex | matehat/elixir-google-api | c1b2523c2c4cdc9e6ca4653ac078c94796b393c3 | [
"Apache-2.0"
] | null | null | null | # Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in ... | 47.515567 | 916 | 0.622183 |
7377b34359c4d90f23e64dc53b0b8452cfdffbfc | 1,065 | ex | Elixir | lib/sass/compiler.ex | scottdavis/sass-ex | bf6312907acf9d87daec18344f3fbd625ea55114 | [
"MIT"
] | 6 | 2016-12-26T01:07:10.000Z | 2022-01-28T09:33:53.000Z | lib/sass/compiler.ex | scottdavis/sass-ex | bf6312907acf9d87daec18344f3fbd625ea55114 | [
"MIT"
] | null | null | null | lib/sass/compiler.ex | scottdavis/sass-ex | bf6312907acf9d87daec18344f3fbd625ea55114 | [
"MIT"
] | 4 | 2017-09-18T12:42:28.000Z | 2021-03-24T11:45:30.000Z | defmodule Sass.Compiler do
@moduledoc """
Connection to the NIF for sass
"""
@on_load { :init, 0 }
@nifname 'sass_nif'
defp app do
:sass
end
@doc """
Loads the sass.so library
"""
def init do
:ok = :erlang.load_nif(nif_path(), 0)
end
@doc """
A noop that gets overwritten by... | 19.017857 | 69 | 0.570892 |
7377ca8a571c099eb2818b229a4ae63266434954 | 523 | exs | Elixir | string_compression/test/string_compression/day09_test.exs | alex-dukhno/elixir-tdd-katas | 57e25fc275c4274c889f2b3760276cc8a393de9e | [
"MIT"
] | null | null | null | string_compression/test/string_compression/day09_test.exs | alex-dukhno/elixir-tdd-katas | 57e25fc275c4274c889f2b3760276cc8a393de9e | [
"MIT"
] | null | null | null | string_compression/test/string_compression/day09_test.exs | alex-dukhno/elixir-tdd-katas | 57e25fc275c4274c889f2b3760276cc8a393de9e | [
"MIT"
] | null | null | null | defmodule StringCompression.Day09Test do
use ExUnit.Case, async: true
alias StringCompression.Day09, as: StringCompression
test "compress empty string", do:
assert StringCompression.compress("") == ""
test "compress single char string", do:
assert StringCompression.compress("a") == "1a"
test "comp... | 29.055556 | 59 | 0.722753 |
737809c146619b7a265bc6d437b0b6b022032a9f | 3,457 | ex | Elixir | clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_content_location.ex | mocknen/elixir-google-api | dac4877b5da2694eca6a0b07b3bd0e179e5f3b70 | [
"Apache-2.0"
] | null | null | null | clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_content_location.ex | mocknen/elixir-google-api | dac4877b5da2694eca6a0b07b3bd0e179e5f3b70 | [
"Apache-2.0"
] | null | null | null | clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_content_location.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... | 54.873016 | 556 | 0.763379 |
73784011d49a3af1a11fa1ba007400db377e3675 | 2,101 | ex | Elixir | lib/store/peer.ex | ElixiumNetwork/elixium_core | 85014da4b0683ab8ec86c893b7c1146161da114a | [
"MIT"
] | 164 | 2018-06-23T01:17:51.000Z | 2021-08-19T03:16:31.000Z | lib/store/peer.ex | alexdovzhanyn/ultradark | 85014da4b0683ab8ec86c893b7c1146161da114a | [
"MIT"
] | 37 | 2018-06-28T18:07:27.000Z | 2019-08-22T18:43:43.000Z | lib/store/peer.ex | alexdovzhanyn/ultradark | 85014da4b0683ab8ec86c893b7c1146161da114a | [
"MIT"
] | 26 | 2018-06-22T00:58:34.000Z | 2021-08-19T03:16:40.000Z | defmodule Elixium.Store.Peer do
use Elixium.Store
@moduledoc """
Store and load data related to peers that a node has communicated with.
This includes authentication data
"""
@store_dir "peers"
def initialize do
initialize(@store_dir)
end
def reorder_peers(ip) do
transact @store_dir do... | 24.149425 | 91 | 0.609234 |
73785856b31d3b2193bb2e0fc4ffc99a5de689f2 | 315 | ex | Elixir | lib/elirc/controllers/bot.ex | rockerBOO/elirc_twitch | 6399f717c012df10df7914c216f5d3f9c425844c | [
"MIT"
] | 20 | 2015-06-18T03:30:58.000Z | 2021-01-11T19:55:00.000Z | lib/elirc/controllers/bot.ex | rockerBOO/elirc_twitch | 6399f717c012df10df7914c216f5d3f9c425844c | [
"MIT"
] | 1 | 2015-06-24T01:03:31.000Z | 2015-06-24T12:41:21.000Z | lib/elirc/controllers/bot.ex | rockerBOO/elirc_twitch | 6399f717c012df10df7914c216f5d3f9c425844c | [
"MIT"
] | 7 | 2015-06-22T14:25:12.000Z | 2016-01-21T03:39:02.000Z | defmodule Elirc.BotController do
def msg(event, state, data) do
end
def echo(msg, state, data) do
IO.puts "catch_all"
IO.inspect data
IO.inspect msg
{:reply, {:text, ""}, state}
end
def echo(message, state) do
# IO.inspect message
{:reply, {:text, message}, state}
end
end | 15 | 37 | 0.622222 |
73785e82949b26b1380fe69791bf9f6d06d0b730 | 100 | ex | Elixir | test/examples/guard_fail_pattern.ex | staring-frog/dialyxir | b78735f75b325238b7db20d9eed22f018cca5f26 | [
"Apache-2.0"
] | 1,455 | 2015-01-03T02:53:19.000Z | 2022-03-12T00:31:25.000Z | test/examples/guard_fail_pattern.ex | staring-frog/dialyxir | b78735f75b325238b7db20d9eed22f018cca5f26 | [
"Apache-2.0"
] | 330 | 2015-05-14T13:53:13.000Z | 2022-03-29T17:12:23.000Z | test/examples/guard_fail_pattern.ex | staring-frog/dialyxir | b78735f75b325238b7db20d9eed22f018cca5f26 | [
"Apache-2.0"
] | 146 | 2015-02-03T18:19:43.000Z | 2022-03-07T10:05:20.000Z | defmodule Dialyxir.Examples.GuardFailPattern do
def ok(n = 0) when not n < 1 do
:ok
end
end
| 16.666667 | 47 | 0.69 |
7378709d2fe0d87abc2c409b9c7c91ed304ebf3c | 1,143 | ex | Elixir | lib/air_vantage/operations/system.ex | pvp-technologies/ex_vantage | 3f04dbc5c952f0c44a06132992e9112a1e367915 | [
"MIT"
] | null | null | null | lib/air_vantage/operations/system.ex | pvp-technologies/ex_vantage | 3f04dbc5c952f0c44a06132992e9112a1e367915 | [
"MIT"
] | null | null | null | lib/air_vantage/operations/system.ex | pvp-technologies/ex_vantage | 3f04dbc5c952f0c44a06132992e9112a1e367915 | [
"MIT"
] | null | null | null | defmodule AirVantage.Operations.System do
@moduledoc """
The system is the core representation used in AirVantage to define and interact with a real system. A system is composed of:
- a gateway: the physical module enabling the connectivity of the system
- a subscription: a subscription is the configuration of ... | 36.870968 | 136 | 0.709536 |
7378975e434468350ba966cc2c6b091f0a8f2b24 | 1,015 | ex | Elixir | src/mailer/lib/mailer_web/router.ex | alexjoybc/elixir-kafka-phoenix | c3d20415f980455081102f3bd4287647bf2292ba | [
"Apache-2.0"
] | null | null | null | src/mailer/lib/mailer_web/router.ex | alexjoybc/elixir-kafka-phoenix | c3d20415f980455081102f3bd4287647bf2292ba | [
"Apache-2.0"
] | null | null | null | src/mailer/lib/mailer_web/router.ex | alexjoybc/elixir-kafka-phoenix | c3d20415f980455081102f3bd4287647bf2292ba | [
"Apache-2.0"
] | null | null | null | defmodule MailerWeb.Router do
use MailerWeb, :router
pipeline :api do
plug :accepts, ["json"]
end
scope "/api", MailerWeb do
pipe_through :api
resources "/businesses", BusinessController, except: [:new, :edit]
end
pipeline :browser do
plug(:accepts, ["html"])
end
scope "/", MailerWeb... | 26.710526 | 70 | 0.699507 |
7378b5e4a98744842f064ff693983129ebbcb55f | 878 | ex | Elixir | Phoenix_Sockets/example1/test/support/conn_case.ex | shubhamagiwal/DOSFall2017 | 3c1522c4163f57402f147b50614d4051b05a080f | [
"MIT"
] | 3 | 2019-10-28T21:02:55.000Z | 2020-10-01T02:29:37.000Z | Phoenix_Sockets/example1/test/support/conn_case.ex | shubhamagiwal/DOSFall2017 | 3c1522c4163f57402f147b50614d4051b05a080f | [
"MIT"
] | null | null | null | Phoenix_Sockets/example1/test/support/conn_case.ex | shubhamagiwal/DOSFall2017 | 3c1522c4163f57402f147b50614d4051b05a080f | [
"MIT"
] | 4 | 2019-10-12T19:41:58.000Z | 2021-09-24T20:24:47.000Z | defmodule Example1Web.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 th... | 25.085714 | 58 | 0.730068 |
7378b736722a2035407466e52bdf3e835824f603 | 1,196 | ex | Elixir | lib/mix/tasks/eunit.ex | radixpool/mix-erlang-tasks | d8709b47f67b505519fcb0567a41c6657c0f300b | [
"MIT"
] | 18 | 2015-04-02T12:13:09.000Z | 2021-01-16T15:51:42.000Z | lib/mix/tasks/eunit.ex | radixpool/mix-erlang-tasks | d8709b47f67b505519fcb0567a41c6657c0f300b | [
"MIT"
] | 3 | 2015-08-31T12:58:12.000Z | 2016-12-31T01:10:10.000Z | lib/mix/tasks/eunit.ex | radixpool/mix-erlang-tasks | d8709b47f67b505519fcb0567a41c6657c0f300b | [
"MIT"
] | 11 | 2015-04-02T12:13:29.000Z | 2022-01-31T14:41:15.000Z | defmodule Mix.Tasks.Eunit do
use Mix.Task
@shortdoc "Run the project's EUnit test suite"
@moduledoc """
# Command line options
* `--verbose`, `-v` - verbose mode
* other options supported by `compile*` tasks
"""
def run(args) do
{opts, args, rem_opts} = OptionParser.parse(args, strict: [ver... | 30.666667 | 106 | 0.685619 |
7378cdd32351eb06834f5a2becaa431f772afc96 | 4,694 | ex | Elixir | clients/you_tube/lib/google_api/you_tube/v3/model/comment_snippet.ex | mcrumm/elixir-google-api | 544f22797cec52b3a23dfb6e39117f0018448610 | [
"Apache-2.0"
] | null | null | null | clients/you_tube/lib/google_api/you_tube/v3/model/comment_snippet.ex | mcrumm/elixir-google-api | 544f22797cec52b3a23dfb6e39117f0018448610 | [
"Apache-2.0"
] | null | null | null | clients/you_tube/lib/google_api/you_tube/v3/model/comment_snippet.ex | mcrumm/elixir-google-api | 544f22797cec52b3a23dfb6e39117f0018448610 | [
"Apache-2.0"
] | null | null | null | # Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, s... | 52.741573 | 294 | 0.693651 |
73790589499e035e086cc53a696d6cedc5ef0d39 | 6,331 | exs | Elixir | config/config.exs | wvffle/analytics | 2c0fd55bc67f74af1fe1e2641678d44e9fee61d5 | [
"MIT"
] | 1 | 2020-10-08T13:33:04.000Z | 2020-10-08T13:33:04.000Z | config/config.exs | wvffle/analytics | 2c0fd55bc67f74af1fe1e2641678d44e9fee61d5 | [
"MIT"
] | null | null | null | config/config.exs | wvffle/analytics | 2c0fd55bc67f74af1fe1e2641678d44e9fee61d5 | [
"MIT"
] | null | null | null | use Mix.Config
base_url = System.get_env("BASE_URL", "http://localhost:8000")
|> URI.parse
config :plausible,
admin_user: System.get_env("ADMIN_USER_NAME", "admin"),
admin_email: System.get_env("ADMIN_USER_EMAIL", "admin@plausible.local"),
mailer_email: System.get_env("MAILER_EMAIL", "hello@plausible... | 30.882927 | 97 | 0.715685 |
737922e351b1f1e543871f1111b3f0414092589c | 693 | ex | Elixir | lib/bolt_sips/error.ex | Badiapp/bolt_sips | ea5e1ae3295700a9f9b0324d26d953845da17050 | [
"Apache-2.0"
] | null | null | null | lib/bolt_sips/error.ex | Badiapp/bolt_sips | ea5e1ae3295700a9f9b0324d26d953845da17050 | [
"Apache-2.0"
] | null | null | null | lib/bolt_sips/error.ex | Badiapp/bolt_sips | ea5e1ae3295700a9f9b0324d26d953845da17050 | [
"Apache-2.0"
] | null | null | null | defmodule Bolt.Sips.Error do
@moduledoc """
represents an error message
"""
alias __MODULE__
@type t :: %__MODULE__{}
defstruct [:code, :message]
def new(%Boltex.Error{code: code, connection_id: cid, function: f, message: message, type: t}) do
{:error,
struct(Error, %{
code: code,
... | 23.896552 | 99 | 0.572872 |
73792b3eaf8d3561587dca6d73e9119e0e933ff3 | 19,567 | ex | Elixir | clients/you_tube/lib/google_api/you_tube/v3/api/watermarks.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2021-12-20T03:40:53.000Z | 2021-12-20T03:40:53.000Z | clients/you_tube/lib/google_api/you_tube/v3/api/watermarks.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2020-08-18T00:11:23.000Z | 2020-08-18T00:44:16.000Z | clients/you_tube/lib/google_api/you_tube/v3/api/watermarks.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... | 51.901857 | 729 | 0.645883 |
737941f8cd9bdf3c8746669200937772c0d88a0e | 378 | ex | Elixir | lib/bike_brigade/messaging/scheduled_message.ex | bikebrigade/dispatch | eb622fe4f6dab7c917d678d3d7a322a01f97da44 | [
"Apache-2.0"
] | 28 | 2021-10-11T01:53:53.000Z | 2022-03-24T17:45:55.000Z | lib/bike_brigade/messaging/scheduled_message.ex | bikebrigade/dispatch | eb622fe4f6dab7c917d678d3d7a322a01f97da44 | [
"Apache-2.0"
] | 20 | 2021-10-21T08:12:31.000Z | 2022-03-31T13:35:53.000Z | lib/bike_brigade/messaging/scheduled_message.ex | bikebrigade/dispatch | eb622fe4f6dab7c917d678d3d7a322a01f97da44 | [
"Apache-2.0"
] | null | null | null | defmodule BikeBrigade.Messaging.ScheduledMessage do
use BikeBrigade.Schema
alias BikeBrigade.Delivery.Campaign
import Ecto.Changeset
schema "scheduled_messages" do
field :send_at, :utc_datetime
belongs_to :campaign, Campaign
timestamps()
end
def changeset(struct, params \\ %{}) do
struc... | 18.9 | 51 | 0.722222 |
7379722eb64fc6941203f6a17192cb7d2fc10085 | 519 | exs | Elixir | config/test.exs | jeojoe/catapalt-chat | 1a8c94bb38535d517837e1e9c53d2e8de0f2b7ae | [
"Apache-2.0"
] | null | null | null | config/test.exs | jeojoe/catapalt-chat | 1a8c94bb38535d517837e1e9c53d2e8de0f2b7ae | [
"Apache-2.0"
] | null | null | null | config/test.exs | jeojoe/catapalt-chat | 1a8c94bb38535d517837e1e9c53d2e8de0f2b7ae | [
"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 :catapalt_chat, CatapaltChat.Endpoint,
http: [port: 4001],
server: false
# Print only warnings and errors during test
config :logger, level: :warn
# Configure your database
config :catapalt_ch... | 25.95 | 56 | 0.747592 |
737990185d7cdbb1da3d544d34bc29586b6ffcfa | 41 | exs | Elixir | .dialyzer_ignore.exs | ambareesha7/node-zaryn | 136e542801bf9b6fa4a015d3464609fdf3dacee8 | [
"Apache-2.0"
] | 1 | 2021-07-06T19:47:14.000Z | 2021-07-06T19:47:14.000Z | .dialyzer_ignore.exs | ambareesha7/node-zaryn | 136e542801bf9b6fa4a015d3464609fdf3dacee8 | [
"Apache-2.0"
] | null | null | null | .dialyzer_ignore.exs | ambareesha7/node-zaryn | 136e542801bf9b6fa4a015d3464609fdf3dacee8 | [
"Apache-2.0"
] | null | null | null | [
{"lib/zaryn/utils.ex", :call, 537}
]
| 10.25 | 36 | 0.536585 |
7379937adbcc4dbf51b9125d5975fc63597ec25f | 302 | exs | Elixir | test/versionary/plug/phoenix_error_handler_test.exs | kianmeng/versionary | 227b035e23c65394e7dec39dba252bf5bb7843e7 | [
"MIT"
] | 35 | 2017-04-05T19:47:08.000Z | 2022-02-12T22:05:17.000Z | test/versionary/plug/phoenix_error_handler_test.exs | kianmeng/versionary | 227b035e23c65394e7dec39dba252bf5bb7843e7 | [
"MIT"
] | 16 | 2017-03-23T14:36:53.000Z | 2021-09-23T17:31:46.000Z | test/versionary/plug/phoenix_error_handler_test.exs | kianmeng/versionary | 227b035e23c65394e7dec39dba252bf5bb7843e7 | [
"MIT"
] | 6 | 2017-03-19T03:04:34.000Z | 2021-08-10T14:05:27.000Z | defmodule Versionary.Plug.PhoenixErrorHandlerTest do
use ExUnit.Case
use Plug.Test
alias Versionary.Plug.PhoenixErrorHandler
test "respond with a status of 406" do
assert_raise(Phoenix.NotAcceptableError, fn() ->
conn(:get, "/")
|> PhoenixErrorHandler.call
end)
end
end
| 21.571429 | 52 | 0.718543 |
7379a4e9f84c996901cfa11e6d5868248eb8bc70 | 1,114 | exs | Elixir | test/elastix/alias_test.exs | macoshita/elastix | cfffda3319ec095dcc3f62141ade74e7ccf117d5 | [
"Naumen",
"Condor-1.1",
"MS-PL"
] | null | null | null | test/elastix/alias_test.exs | macoshita/elastix | cfffda3319ec095dcc3f62141ade74e7ccf117d5 | [
"Naumen",
"Condor-1.1",
"MS-PL"
] | null | null | null | test/elastix/alias_test.exs | macoshita/elastix | cfffda3319ec095dcc3f62141ade74e7ccf117d5 | [
"Naumen",
"Condor-1.1",
"MS-PL"
] | null | null | null | defmodule Elastix.AliasTest do
use ExUnit.Case
alias Elastix.Alias
alias Elastix.Index
@test_url Elastix.config(:test_url)
@test_index Elastix.config(:test_index)
setup do
Index.delete(@test_url, @test_index)
:ok
end
test "aliases actions on existing index should respond with 200" do
ass... | 30.108108 | 87 | 0.620287 |
7379a5c0ca420d8cc459dec00cd936d8cead6de0 | 754 | exs | Elixir | kousa/test/broth/user/get_bots_test.exs | LeonardSSH/dogehouse | 584055ad407bc37fa35cdf36ebb271622e29d436 | [
"MIT"
] | 9 | 2021-03-17T03:56:18.000Z | 2021-09-24T22:45:14.000Z | kousa/test/broth/user/get_bots_test.exs | LeonardSSH/dogehouse | 584055ad407bc37fa35cdf36ebb271622e29d436 | [
"MIT"
] | 12 | 2021-07-06T12:51:13.000Z | 2022-03-16T12:38:18.000Z | kousa/test/broth/user/get_bots_test.exs | LeonardSSH/dogehouse | 584055ad407bc37fa35cdf36ebb271622e29d436 | [
"MIT"
] | 4 | 2021-07-15T20:33:50.000Z | 2022-03-27T12:46:47.000Z | defmodule BrothTest.User.GetBotsTest do
use ExUnit.Case, async: true
use KousaTest.Support.EctoSandbox
alias Beef.Schemas.User
alias BrothTest.WsClient
alias BrothTest.WsClientFactory
alias KousaTest.Support.Factory
require WsClient
setup do
user = Factory.create(User)
client_ws = WsClientFac... | 24.322581 | 97 | 0.68435 |
7379a5c11183ba6af53123049b45b9e1af4bc7db | 2,343 | ex | Elixir | lib/absinthe_permission/middleware/has_permission.ex | kianmeng/absinthe_permission | 5085045c04582d9b9e461ec2e36d6511ba5555fa | [
"MIT"
] | 16 | 2020-10-28T16:12:00.000Z | 2022-01-31T17:03:47.000Z | lib/absinthe_permission/middleware/has_permission.ex | kianmeng/absinthe_permission | 5085045c04582d9b9e461ec2e36d6511ba5555fa | [
"MIT"
] | null | null | null | lib/absinthe_permission/middleware/has_permission.ex | kianmeng/absinthe_permission | 5085045c04582d9b9e461ec2e36d6511ba5555fa | [
"MIT"
] | 1 | 2020-10-30T11:45:30.000Z | 2020-10-30T11:45:30.000Z | defmodule AbsinthePermission.Middleware.HasPermission do
@behaviour Absinthe.Middleware
alias AbsinthePermission.PolicyChecker
# check permission
def call(
%{
state: :unresolved,
arguments: arguments,
context: %{current_user: _current_user, permissions: user_perms} = cont... | 26.033333 | 92 | 0.571063 |
7379b0751bda8a8ce5a2720d0dd3c660c014b1b8 | 3,680 | exs | Elixir | test/consumer_test.exs | esl/buildex_jobs | 928d36541c25fa0ad998278cc7fe609644562140 | [
"Apache-2.0"
] | 2 | 2020-05-28T12:23:00.000Z | 2021-03-11T23:23:57.000Z | test/consumer_test.exs | esl/buildex_jobs | 928d36541c25fa0ad998278cc7fe609644562140 | [
"Apache-2.0"
] | null | null | null | test/consumer_test.exs | esl/buildex_jobs | 928d36541c25fa0ad998278cc7fe609644562140 | [
"Apache-2.0"
] | 2 | 2021-03-11T23:27:28.000Z | 2022-03-06T10:20:51.000Z | defmodule RepoJobs.ConsumerTest do
# async: false to appease the ExUnit.CaptureLog
use ExUnit.Case, async: false
import ExUnit.CaptureLog
alias ExRabbitPool.FakeRabbitMQ
alias ExRabbitPool.Worker.{RabbitConnection, SetupQueue}
alias RepoJobs.Consumer
@queue "test.queue"
setup do
n = :rand.unifor... | 31.724138 | 94 | 0.657337 |
7379d6af3c7e58ac4f89f1ba39b414eab9a30516 | 1,751 | exs | Elixir | mix.exs | JeffyMesquita/elixirHeat | 3ec3c59021e90058f00c2eb288a5e6c286e96342 | [
"MIT"
] | null | null | null | mix.exs | JeffyMesquita/elixirHeat | 3ec3c59021e90058f00c2eb288a5e6c286e96342 | [
"MIT"
] | null | null | null | mix.exs | JeffyMesquita/elixirHeat | 3ec3c59021e90058f00c2eb288a5e6c286e96342 | [
"MIT"
] | null | null | null | defmodule ElixirHeat.MixProject do
use Mix.Project
def project do
[
app: :elixirHeat,
version: "0.1.0",
elixir: "~> 1.7",
elixirc_paths: elixirc_paths(Mix.env()),
compilers: [:phoenix, :gettext] ++ Mix.compilers(),
start_permanent: Mix.env() == :prod,
aliases: aliases(... | 27.359375 | 84 | 0.585951 |
737a0a9a87963ee8f6633790e78607cd33a192e2 | 3,661 | ex | Elixir | lib/changelog_web/meta/title.ex | boneskull/changelog.com | 2fa2e356bb0e8fcf038c46a4a947fef98822e37d | [
"MIT"
] | null | null | null | lib/changelog_web/meta/title.ex | boneskull/changelog.com | 2fa2e356bb0e8fcf038c46a4a947fef98822e37d | [
"MIT"
] | null | null | null | lib/changelog_web/meta/title.ex | boneskull/changelog.com | 2fa2e356bb0e8fcf038c46a4a947fef98822e37d | [
"MIT"
] | null | null | null | defmodule ChangelogWeb.Meta.Title do
alias ChangelogWeb.{AuthView, EpisodeView, LiveView, NewsItemView, NewsSourceView,
PageView, PersonView, PodcastView, PostView, TopicView, SearchView}
@suffix "News and podcasts for developers | Changelog"
def page_title(assigns), do: assigns |> get |>... | 33.898148 | 117 | 0.665119 |
737a4a5e56c4d84d9fa54aa6909037b883f09fb1 | 640 | ex | Elixir | lib/exkeychain_web/views/account_view.ex | ctxhaard/exkeychain | 1109316f182ab35d0f01a5607260afd35b87e7ff | [
"Apache-2.0"
] | 1 | 2021-02-15T08:56:17.000Z | 2021-02-15T08:56:17.000Z | lib/exkeychain_web/views/account_view.ex | ctxhaard/exkeychain | 1109316f182ab35d0f01a5607260afd35b87e7ff | [
"Apache-2.0"
] | null | null | null | lib/exkeychain_web/views/account_view.ex | ctxhaard/exkeychain | 1109316f182ab35d0f01a5607260afd35b87e7ff | [
"Apache-2.0"
] | null | null | null | defmodule ExkeychainWeb.AccountView do
use ExkeychainWeb, :view
def render("authentication.json", _) do
%{ status: "ok" }
end
def render("index.json", %{accounts: accounts}) do
%{ data: render_many(accounts, ExkeychainWeb.AccountView, "account.json")}
end
def render("show.json", %{account: accoun... | 22.857143 | 78 | 0.646875 |
737a7b23956ef164e86293c62c55d91bffd1b90f | 215 | ex | Elixir | web/serializers/ticket_serializer.ex | Pianist038801/SprintPoker | ae14f79b8cd4254a1c5f5fef698db1cf2d20cf9c | [
"MIT"
] | null | null | null | web/serializers/ticket_serializer.ex | Pianist038801/SprintPoker | ae14f79b8cd4254a1c5f5fef698db1cf2d20cf9c | [
"MIT"
] | null | null | null | web/serializers/ticket_serializer.ex | Pianist038801/SprintPoker | ae14f79b8cd4254a1c5f5fef698db1cf2d20cf9c | [
"MIT"
] | null | null | null | defimpl Poison.Encoder, for: SprintPoker.Ticket do
def encode(ticket, options) do
%{
id: ticket.id,
name: ticket.name,
points: ticket.points
} |> Poison.Encoder.encode(options)
end
end
| 21.5 | 50 | 0.651163 |
737a7e063acca17c296069efcf34e1e35aeee275 | 735 | ex | Elixir | lib/crew/persons/person_tagging.ex | anamba/crew | c25f6a1d6ddbe0b58da9d556ff53a641c4d2a7b1 | [
"BSL-1.0"
] | null | null | null | lib/crew/persons/person_tagging.ex | anamba/crew | c25f6a1d6ddbe0b58da9d556ff53a641c4d2a7b1 | [
"BSL-1.0"
] | 5 | 2020-07-20T01:49:01.000Z | 2021-09-08T00:17:04.000Z | lib/crew/persons/person_tagging.ex | anamba/crew | c25f6a1d6ddbe0b58da9d556ff53a641c4d2a7b1 | [
"BSL-1.0"
] | null | null | null | defmodule Crew.Persons.PersonTagging do
use Ecto.Schema
import Ecto.Changeset
alias Crew.Persons.{Person, PersonTag}
@foreign_key_type :binary_id
schema "person_taggings" do
belongs_to :person, Person
belongs_to :tag, PersonTag, foreign_key: :person_tag_id
field :name, :string
field :value... | 23.709677 | 73 | 0.711565 |
737a84b972c79b4f56e0e693f1a9fc54a58a43f1 | 2,500 | exs | Elixir | test/utils_test.exs | ospaarmann/exdgraph | 4a80822c4f4c8521f5df71e9bdf7238b302f9786 | [
"Apache-2.0"
] | 108 | 2018-02-23T15:20:09.000Z | 2021-05-26T11:48:17.000Z | test/utils_test.exs | ospaarmann/exdgraph | 4a80822c4f4c8521f5df71e9bdf7238b302f9786 | [
"Apache-2.0"
] | 28 | 2018-02-25T09:30:38.000Z | 2021-12-22T03:57:39.000Z | test/utils_test.exs | ospaarmann/exdgraph | 4a80822c4f4c8521f5df71e9bdf7238b302f9786 | [
"Apache-2.0"
] | 14 | 2018-03-01T17:19:56.000Z | 2021-03-02T16:57:58.000Z | defmodule ExDgraph.Utils.Test do
use ExUnit.Case, async: true
doctest ExDgraph.Utils
alias ExDgraph.Utils
test "as_rendered/1 float" do
assert Utils.as_rendered(3.14) == "3.14"
end
test "as_rendered/1 bool" do
assert Utils.as_rendered(true) == "true"
end
test "as_rendered/1 int" do
asser... | 27.777778 | 95 | 0.6608 |
737ac7ab2707638e256f23f345773a1a0d6ac5d8 | 471 | exs | Elixir | config/test.exs | rob05c/tox | f54847ca058ad24b909341ad65d595a4069d2471 | [
"Apache-2.0"
] | 2 | 2016-11-16T17:24:21.000Z | 2019-02-15T05:38:27.000Z | config/test.exs | rob05c/tox | f54847ca058ad24b909341ad65d595a4069d2471 | [
"Apache-2.0"
] | null | null | null | config/test.exs | rob05c/tox | f54847ca058ad24b909341ad65d595a4069d2471 | [
"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 :tox, Tox.Endpoint,
http: [port: 4001],
server: false
# Print only warnings and errors during test
config :logger, level: :warn
# Configure your database
config :tox, Tox.Repo,
adapter: Ecto... | 23.55 | 56 | 0.721868 |
737af09573b5a68f789656c8381b2ad9a0708c29 | 134 | ex | Elixir | debian/neheglqt.cron.d.ex | rzr/neheglqt | b80cbb859ec76e80c74ac646b94fafa44259431d | [
"Linux-OpenIB"
] | 1 | 2021-02-06T01:34:45.000Z | 2021-02-06T01:34:45.000Z | debian/neheglqt.cron.d.ex | rzr/neheglqt | b80cbb859ec76e80c74ac646b94fafa44259431d | [
"Linux-OpenIB"
] | null | null | null | debian/neheglqt.cron.d.ex | rzr/neheglqt | b80cbb859ec76e80c74ac646b94fafa44259431d | [
"Linux-OpenIB"
] | null | null | null | #
# Regular cron jobs for the neheglqt package
#
0 4 * * * root [ -x /usr/bin/neheglqt_maintenance ] && /usr/bin/neheglqt_maintenance
| 26.8 | 84 | 0.708955 |
737afc84d4daec1bb8e8a40497ccbcc41a6fd8f1 | 1,907 | ex | Elixir | client/lib/collector/collector.ex | vfournie/udp-playground | c180004344d5b673730dae04848294902e6a75ee | [
"MIT"
] | null | null | null | client/lib/collector/collector.ex | vfournie/udp-playground | c180004344d5b673730dae04848294902e6a75ee | [
"MIT"
] | null | null | null | client/lib/collector/collector.ex | vfournie/udp-playground | c180004344d5b673730dae04848294902e6a75ee | [
"MIT"
] | null | null | null | defmodule UdpClient.Collector do
use GenServer
require Logger
## Client API
def start_link() do
GenServer.start_link(__MODULE__, :ok, name: __MODULE__)
end
def inc_counter(counter) do
GenServer.call(__MODULE__, {:inc_counter, counter})
end
def get_raw_stats() do
GenServe... | 25.77027 | 98 | 0.543262 |
737b173208e2771ef61de59e41320505a5e25be0 | 7,903 | ex | Elixir | lib/elixir/lib/calendar/iso.ex | TurtleAI/elixir | 2fb41ebef4d06315dd6c05ee00899572b27ee50a | [
"Apache-2.0"
] | null | null | null | lib/elixir/lib/calendar/iso.ex | TurtleAI/elixir | 2fb41ebef4d06315dd6c05ee00899572b27ee50a | [
"Apache-2.0"
] | null | null | null | lib/elixir/lib/calendar/iso.ex | TurtleAI/elixir | 2fb41ebef4d06315dd6c05ee00899572b27ee50a | [
"Apache-2.0"
] | null | null | null | defmodule Calendar.ISO do
@moduledoc """
A calendar implementation that follows to ISO8601.
This calendar implements the proleptic Gregorian calendar and
is therefore compatible with the calendar used in most countries
today. The proleptic means the Gregorian rules for leap years are
applied for all time, ... | 30.992157 | 97 | 0.644818 |
737b275b70749dd065cd660c3043ebf972733993 | 668 | ex | Elixir | lib/sentinel.ex | hexedpackets/sentinel | 578b6a92832c0a81fd15eac3f3064579ecfbf9bd | [
"MIT"
] | null | null | null | lib/sentinel.ex | hexedpackets/sentinel | 578b6a92832c0a81fd15eac3f3064579ecfbf9bd | [
"MIT"
] | 6 | 2019-05-01T21:20:34.000Z | 2019-05-01T21:30:14.000Z | lib/sentinel.ex | hexedpackets/sentinel | 578b6a92832c0a81fd15eac3f3064579ecfbf9bd | [
"MIT"
] | null | null | null | defmodule Sentinel do
@doc """
Generate a GitHub client authenticated with a JWT.
"""
def client() do
Tentacat.Client.new(%{jwt: Sentinel.Auth.token()})
end
@doc """
Generate a GitHub client for a specific installation
"""
def client(installation) when is_integer(installation) do
token = Sent... | 23.034483 | 65 | 0.670659 |
737b2d65ca448acd17e8784e206f31ba0b790b59 | 1,338 | exs | Elixir | lib/elixir/test/elixir/range_test.exs | knewter/elixir | 8310d62499e292d78d5c9d79d5d15a64e32fb738 | [
"Apache-2.0"
] | null | null | null | lib/elixir/test/elixir/range_test.exs | knewter/elixir | 8310d62499e292d78d5c9d79d5d15a64e32fb738 | [
"Apache-2.0"
] | null | null | null | lib/elixir/test/elixir/range_test.exs | knewter/elixir | 8310d62499e292d78d5c9d79d5d15a64e32fb738 | [
"Apache-2.0"
] | null | null | null | Code.require_file "test_helper.exs", __DIR__
defmodule RangeTest do
use ExUnit.Case, async: true
test :precedence do
assert Enum.to_list(1..3+2) == [1, 2, 3, 4, 5]
assert 1..3 |> Enum.to_list == [1, 2, 3]
end
test :first do
assert Range.new(first: 1, last: 3).first == 1
end
test :last do
... | 20.90625 | 50 | 0.577728 |
737b3f38a99d8360989da95bb5a4266e310ff5cd | 1,225 | ex | Elixir | lib/obelisk/site.ex | knewter/obelisk | 360425914d36c1c6094820ae035a4555a177ed00 | [
"MIT"
] | 1 | 2017-04-04T15:44:25.000Z | 2017-04-04T15:44:25.000Z | lib/obelisk/site.ex | knewter/obelisk | 360425914d36c1c6094820ae035a4555a177ed00 | [
"MIT"
] | null | null | null | lib/obelisk/site.ex | knewter/obelisk | 360425914d36c1c6094820ae035a4555a177ed00 | [
"MIT"
] | null | null | null | defmodule Obelisk.Site do
def initialize do
create_default_theme
create_content_dirs
Obelisk.Post.create("Welcome to Obelisk")
File.write './site.yml', Obelisk.Templates.config
end
def clean do
File.rm_rf "./build"
File.mkdir "./build"
end
def create_default_theme do
File.mkdir ... | 27.222222 | 82 | 0.713469 |
737b76ab2195675f673a610b9bafcb551a5d8b22 | 622 | ex | Elixir | web/models/user_properties.ex | mijkenator/elapi | 55a85edf6fcadd89e390a682404c79bab93282b0 | [
"Artistic-2.0"
] | null | null | null | web/models/user_properties.ex | mijkenator/elapi | 55a85edf6fcadd89e390a682404c79bab93282b0 | [
"Artistic-2.0"
] | null | null | null | web/models/user_properties.ex | mijkenator/elapi | 55a85edf6fcadd89e390a682404c79bab93282b0 | [
"Artistic-2.0"
] | null | null | null | defmodule Elapi.UserProperties do
use Elapi.Web, :model
schema "user_properties" do
belongs_to :user, Elapi.User
field :data, Elapi.Json.Type
timestamps
end
@required_fields ~w(user_id)
@optional_fields ~w(data)
@doc """
Creates a changeset based on the `model` and `params`.
If no param... | 19.4375 | 61 | 0.689711 |
737b8aab4b58a287c582eacb10f2feca9f74559f | 1,001 | ex | Elixir | lib/pelemay_fp_benchmark/logistic_map.ex | al2o3cr/pelemay_fp_benchmark | 27f33e1a0990b964183d1e65414e01a7c333b5b2 | [
"Apache-2.0"
] | null | null | null | lib/pelemay_fp_benchmark/logistic_map.ex | al2o3cr/pelemay_fp_benchmark | 27f33e1a0990b964183d1e65414e01a7c333b5b2 | [
"Apache-2.0"
] | 1 | 2020-12-28T08:16:26.000Z | 2021-01-05T20:04:51.000Z | lib/pelemay_fp_benchmark/logistic_map.ex | al2o3cr/pelemay_fp_benchmark | 27f33e1a0990b964183d1e65414e01a7c333b5b2 | [
"Apache-2.0"
] | 1 | 2020-12-28T00:10:38.000Z | 2020-12-28T00:10:38.000Z | defmodule LogisticMap do
import Pelemay
def logistic_map(v) do
rem(22 * v * (v + 1), 6_700_417)
end
def logistic_map_10(v) do
logistic_map(v)
|> logistic_map()
|> logistic_map()
|> logistic_map()
|> logistic_map()
|> logistic_map()
|> logistic_map()
|> logistic_map()
|>... | 27.054054 | 54 | 0.514486 |
737b9ad4a1ae2068bc60b9ede290d307856fe42b | 7,882 | exs | Elixir | apps/site/test/site/realtime_schedule_test.exs | paulswartz/dotcom | 73e43e7c61afd96b1928608ce8316a7ed0eb1440 | [
"MIT"
] | null | null | null | apps/site/test/site/realtime_schedule_test.exs | paulswartz/dotcom | 73e43e7c61afd96b1928608ce8316a7ed0eb1440 | [
"MIT"
] | 65 | 2021-05-06T18:38:33.000Z | 2022-03-28T20:50:04.000Z | apps/site/test/site/realtime_schedule_test.exs | paulswartz/dotcom | 73e43e7c61afd96b1928608ce8316a7ed0eb1440 | [
"MIT"
] | null | null | null | defmodule Site.RealtimeScheduleTest do
use ExUnit.Case
alias Alerts.Alert
alias Alerts.InformedEntity, as: IE
alias Alerts.InformedEntitySet, as: IESet
alias Predictions.Prediction
alias RoutePatterns.RoutePattern
alias Routes.Route
alias Schedules.{Schedule, Trip}
alias Site.JsonHelpers
alias Site... | 26.538721 | 80 | 0.502791 |
737bc5ac6064d066773e6545b76bed2453761aa2 | 909 | ex | Elixir | apps/peedy_f/lib/watermarker.ex | poteto/peedy | df9d5ee7fcbceb30b5939b36224a257249a180ea | [
"Apache-2.0"
] | 34 | 2017-05-07T08:50:59.000Z | 2021-11-25T00:27:11.000Z | apps/peedy_f/lib/watermarker.ex | poteto/peedy | df9d5ee7fcbceb30b5939b36224a257249a180ea | [
"Apache-2.0"
] | null | null | null | apps/peedy_f/lib/watermarker.ex | poteto/peedy | df9d5ee7fcbceb30b5939b36224a257249a180ea | [
"Apache-2.0"
] | 7 | 2017-05-10T12:42:30.000Z | 2021-11-03T01:21:02.000Z | defmodule PeedyF.Watermarker do
require Logger
alias PeedyF.Strategies.{Pdfkit, Erlguten}
@after_compile __MODULE__
@nodejs Application.get_env(:peedy_f, :executables)[:nodejs]
@pdfkit Application.get_env(:peedy_f, :executables)[:pdfkit]
def create(text, strategy: :pdfkit) when is_binary(text),
do: Pd... | 30.3 | 81 | 0.705171 |
737bdb77d4955d77e35c9ba5f00b5052118d4c6a | 5,428 | ex | Elixir | clients/sheets/lib/google_api/sheets/v4/model/banding_properties.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/sheets/lib/google_api/sheets/v4/model/banding_properties.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/sheets/lib/google_api/sheets/v4/model/banding_properties.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | # Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, s... | 54.828283 | 169 | 0.738025 |
737bf52e9ff29a6d441cda712b1d60c0c7f1ae5e | 231 | exs | Elixir | priv/repo/migrations/20201019210311_change_current_url_and_pathname_fields_type_to_text.exs | ZmagoD/papercups | dff9a5822b809edc4fd8ecf198566f9b14ab613f | [
"MIT"
] | 4,942 | 2020-07-20T22:35:28.000Z | 2022-03-31T15:38:51.000Z | priv/repo/migrations/20201019210311_change_current_url_and_pathname_fields_type_to_text.exs | ZmagoD/papercups | dff9a5822b809edc4fd8ecf198566f9b14ab613f | [
"MIT"
] | 552 | 2020-07-22T01:39:04.000Z | 2022-02-01T00:26:35.000Z | priv/repo/migrations/20201019210311_change_current_url_and_pathname_fields_type_to_text.exs | ZmagoD/papercups | dff9a5822b809edc4fd8ecf198566f9b14ab613f | [
"MIT"
] | 396 | 2020-07-22T19:27:48.000Z | 2022-03-31T05:25:24.000Z | defmodule ChatApi.Repo.Migrations.ChangeCurrentUrlAndPathnameFieldsTypeToText do
use Ecto.Migration
def change do
alter table(:customers) do
modify :current_url, :text
modify :pathname, :text
end
end
end
| 21 | 80 | 0.74026 |
737c07d00c982e4a3cf39e9d0031619fdc4d8c42 | 1,157 | ex | Elixir | lib/horde/cluster.ex | SvenW/horde | 6db5b835d188382b2ad6ebe026871bf7558224b2 | [
"MIT"
] | null | null | null | lib/horde/cluster.ex | SvenW/horde | 6db5b835d188382b2ad6ebe026871bf7558224b2 | [
"MIT"
] | null | null | null | lib/horde/cluster.ex | SvenW/horde | 6db5b835d188382b2ad6ebe026871bf7558224b2 | [
"MIT"
] | null | null | null | defmodule Horde.Cluster do
require Logger
@moduledoc """
Public functions to join and leave hordes.
Calling `Horde.Cluster.set_members/2` will join the given members in a cluster. Cluster membership is propagated via a CRDT, so setting it once on a single node is sufficient.
```elixir
{:ok, sup1} = Horde.... | 36.15625 | 177 | 0.681936 |
737c3186971469e139857b8b2b0207726330aa01 | 268 | exs | Elixir | test/atfirs_web/views/layout_view_test.exs | iboss-ptk/Atfirs | 1361c8f1b86971317b33212f9269aaffa0f09110 | [
"MIT"
] | 2 | 2021-01-23T09:23:20.000Z | 2021-02-12T09:15:45.000Z | test/atfirs_web/views/layout_view_test.exs | iboss-ptk/Atfirs | 1361c8f1b86971317b33212f9269aaffa0f09110 | [
"MIT"
] | null | null | null | test/atfirs_web/views/layout_view_test.exs | iboss-ptk/Atfirs | 1361c8f1b86971317b33212f9269aaffa0f09110 | [
"MIT"
] | null | null | null | defmodule AtfirsWeb.LayoutViewTest do
use AtfirsWeb.ConnCase, async: true
# When testing helpers, you may want to import Phoenix.HTML and
# use functions such as safe_to_string() to convert the helper
# result into an HTML string.
# import Phoenix.HTML
end
| 29.777778 | 65 | 0.764925 |
737c44b9622ef6256bd87a4d4bc9ccddc2845604 | 2,530 | ex | Elixir | clients/service_usage/lib/google_api/service_usage/v1/model/auth_requirement.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/service_usage/lib/google_api/service_usage/v1/model/auth_requirement.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/service_usage/lib/google_api/service_usage/v1/model/auth_requirement.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... | 35.633803 | 125 | 0.721344 |
737c5cb53dad98d549e28f780b75ca9cce02e9c5 | 221 | exs | Elixir | test/dmage_web/live/main_live_test.exs | Devotu/dmage | 54d8e55bf010f2e0beb2bd0c21157366f0375bd3 | [
"MIT"
] | null | null | null | test/dmage_web/live/main_live_test.exs | Devotu/dmage | 54d8e55bf010f2e0beb2bd0c21157366f0375bd3 | [
"MIT"
] | null | null | null | test/dmage_web/live/main_live_test.exs | Devotu/dmage | 54d8e55bf010f2e0beb2bd0c21157366f0375bd3 | [
"MIT"
] | null | null | null | defmodule DmageWeb.MainLiveTest do
use DmageWeb.ConnCase
import Phoenix.LiveViewTest
test "disconnected and connected render", %{conn: conn} do
{:ok, page_live, _disconnected_html} = live(conn, "/")
end
end
| 22.1 | 60 | 0.733032 |
737c6b5c17b92cf22d3a112cca933f49cdafed32 | 14,766 | exs | Elixir | test/twirp/plug_test.exs | rahmatullah5/twirp-elixir | 9177cda4beb2fc89efb0a0c9239ff4d28a6a6ce6 | [
"Apache-2.0"
] | 30 | 2019-11-03T16:30:13.000Z | 2020-06-23T19:38:53.000Z | test/twirp/plug_test.exs | rahmatullah5/twirp-elixir | 9177cda4beb2fc89efb0a0c9239ff4d28a6a6ce6 | [
"Apache-2.0"
] | 16 | 2020-03-13T17:56:16.000Z | 2020-06-11T10:40:02.000Z | test/twirp/plug_test.exs | rahmatullah5/twirp-elixir | 9177cda4beb2fc89efb0a0c9239ff4d28a6a6ce6 | [
"Apache-2.0"
] | 3 | 2019-12-05T16:43:15.000Z | 2020-05-11T21:34:44.000Z | defmodule Twirp.PlugTest do
use ExUnit.Case, async: false
use Plug.Test
alias Twirp.Error
defmodule Size do
@moduledoc false
use Protobuf, syntax: :proto3
defstruct [:inches]
field :inches, 1, type: :int32
end
defmodule Hat do
@moduledoc false
use Protobuf, syntax: :proto3
... | 27.243542 | 164 | 0.613165 |
737c7507121c376a1634d4a36a0962f93c344a12 | 7,959 | ex | Elixir | lib/faker/internet.ex | subvisual/faker | ee055a15d0669f50316fcb8799ab0fffd0ea0715 | [
"MIT"
] | null | null | null | lib/faker/internet.ex | subvisual/faker | ee055a15d0669f50316fcb8799ab0fffd0ea0715 | [
"MIT"
] | 57 | 2018-12-24T10:39:32.000Z | 2020-12-28T10:13:00.000Z | lib/faker/internet.ex | subvisual/faker | ee055a15d0669f50316fcb8799ab0fffd0ea0715 | [
"MIT"
] | 1 | 2019-02-03T17:04:21.000Z | 2019-02-03T17:04:21.000Z | defmodule Faker.Internet do
alias Faker.Lorem
alias Faker.Name.En, as: Name
alias Faker.Util
import Faker.Util, only: [pick: 1]
@moduledoc """
Functions for generating internet related data
"""
@doc """
Returns a complete random domain name
## Examples
iex> Faker.Internet.domain_name()
... | 23.972892 | 85 | 0.616032 |
737c7db5bf065078f0168712684bd9df38acb728 | 519 | exs | Elixir | apps/reaper/config/dev.exs | jakeprem/smartcitiesdata | da309ac0d2261527278951cbae88604455207589 | [
"Apache-2.0"
] | 1 | 2021-04-05T19:17:18.000Z | 2021-04-05T19:17:18.000Z | apps/reaper/config/dev.exs | SmartColumbusOS/smartcitiesdata | c8553d34631c822b034945eebf396994bf1001ff | [
"Apache-2.0"
] | 11 | 2020-01-07T15:43:42.000Z | 2020-12-22T15:23:25.000Z | apps/reaper/config/dev.exs | jakeprem/smartcitiesdata | da309ac0d2261527278951cbae88604455207589 | [
"Apache-2.0"
] | null | null | null | use Mix.Config
host =
case System.get_env("HOST_IP") do
nil -> "127.0.0.1"
defined -> defined
end
config :libcluster,
topologies: [
sculler_cluster: [
strategy: Elixir.Cluster.Strategy.Epmd,
config: [
hosts: [:"a@127.0.0.1", :"b@127.0.0.1"]
]
]
]
config :redix, :args... | 17.896552 | 54 | 0.597303 |
737cc31a1880ce7479266e8cf881a5407556ae73 | 2,419 | exs | Elixir | mix.exs | tdnguyen85/blog-elixir | 6bf7ebb3968a2c535cef9d61866bd0a11338be54 | [
"MIT"
] | null | null | null | mix.exs | tdnguyen85/blog-elixir | 6bf7ebb3968a2c535cef9d61866bd0a11338be54 | [
"MIT"
] | null | null | null | mix.exs | tdnguyen85/blog-elixir | 6bf7ebb3968a2c535cef9d61866bd0a11338be54 | [
"MIT"
] | null | null | null | defmodule RealWorld.Mixfile do
use Mix.Project
def project do
[
app: :real_world,
version: "0.0.1",
elixir: "~> 1.5",
elixirc_paths: elixirc_paths(Mix.env()),
compilers: [:phoenix, :gettext] ++ Mix.compilers(),
start_permanent: Mix.env() == :prod,
aliases: aliases(),
... | 30.2375 | 90 | 0.570484 |
737cc44c784b39e121c7d1bd27efa1017883c18b | 7,736 | ex | Elixir | lib/sqlite_db_connection/protocol.ex | danielspofford/sqlite_ecto2 | 7ba0b627108b0e1eb73d46741210bd7a11d4fd8b | [
"MIT"
] | 62 | 2017-01-13T21:01:39.000Z | 2018-07-24T12:57:01.000Z | lib/sqlite_db_connection/protocol.ex | danielspofford/sqlite_ecto2 | 7ba0b627108b0e1eb73d46741210bd7a11d4fd8b | [
"MIT"
] | 206 | 2016-12-24T01:56:29.000Z | 2018-06-18T01:47:50.000Z | lib/sqlite_db_connection/protocol.ex | danielspofford/sqlite_ecto2 | 7ba0b627108b0e1eb73d46741210bd7a11d4fd8b | [
"MIT"
] | 27 | 2018-12-22T04:02:30.000Z | 2021-02-18T20:20:57.000Z | defmodule Sqlite.DbConnection.Protocol do
@moduledoc false
alias Sqlite.DbConnection.Query
use DBConnection
defstruct [db: nil, path: nil, checked_out?: false]
@type state :: %__MODULE__{db: pid, path: String.t, checked_out?: boolean}
@spec connect(Keyword.t) :: {:ok, state}
def connect(opts) do
d... | 34.079295 | 90 | 0.634566 |
737ccdd09ecd701e2992d8a57ac0a7a14db9d3c4 | 6,937 | ex | Elixir | lib/100/p10.ex | penqen/yukicoder-elixir | 4f3e9e4694a14434cc3700280e9205226434733b | [
"MIT"
] | null | null | null | lib/100/p10.ex | penqen/yukicoder-elixir | 4f3e9e4694a14434cc3700280e9205226434733b | [
"MIT"
] | null | null | null | lib/100/p10.ex | penqen/yukicoder-elixir | 4f3e9e4694a14434cc3700280e9205226434733b | [
"MIT"
] | null | null | null | defmodule P10 do
@moduledoc """
- 入力: N, Total, A[n]
- 複数回答の場合 {+,*} の順の辞書列順の最初
- (((((A[0]) ? A[1]) ? A[2]) ? A[3]) ... A[n - 1]) = Total
以下の関係式を考える。 このとき、`?`オペランドは、`{/,-}`である。
```
R(n) = Total
R(n - 1) = R(n) ? A[n - 1]
R(n - 2) = R(n - 1) ? A[n - 2]
...
R(i) = R(i - 1) ? A[i]
...
R(1) = R... | 31.107623 | 170 | 0.466628 |
737ce03bf989f549f250f2f7fa362117f11ffe74 | 992 | ex | Elixir | web/views/error_helpers.ex | nsarno/sailship | 1b94440d722e9a95981360ae6eae62ad8e230714 | [
"MIT"
] | null | null | null | web/views/error_helpers.ex | nsarno/sailship | 1b94440d722e9a95981360ae6eae62ad8e230714 | [
"MIT"
] | null | null | null | web/views/error_helpers.ex | nsarno/sailship | 1b94440d722e9a95981360ae6eae62ad8e230714 | [
"MIT"
] | null | null | null | defmodule Sailship.ErrorHelpers do
@moduledoc """
Conveniences for translating and building error messages.
"""
@doc """
Translates an error message using gettext.
"""
def translate_error({msg, opts}) do
# Because error messages were defined within Ecto, we must
# call the Gettext module passing ... | 33.066667 | 74 | 0.670363 |
737cf14aa3f2a0a5ec1c7dbf2f5752a0a685306e | 1,169 | exs | Elixir | config/config.exs | croqaz/FsWatch | 35ec83491d54eb08b278b0925b9490116d5fc46f | [
"MIT"
] | null | null | null | config/config.exs | croqaz/FsWatch | 35ec83491d54eb08b278b0925b9490116d5fc46f | [
"MIT"
] | null | null | null | config/config.exs | croqaz/FsWatch | 35ec83491d54eb08b278b0925b9490116d5fc46f | [
"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
config :porcelain, driver: Porcelain.Driver.Basic
# This configuration is loaded before any dependency and is restricted
# to this project. If another project depends on this proje... | 34.382353 | 73 | 0.75278 |
737d210af678d21692eed6286de580c362f98228 | 12,411 | exs | Elixir | test/spf_dns_test.exs | hertogp/SpfCheck | bee61300f9be1850e274b75aca31228b70c93e34 | [
"MIT"
] | 2 | 2021-11-20T23:32:58.000Z | 2022-01-15T14:07:20.000Z | test/spf_dns_test.exs | hertogp/spfcheck | bee61300f9be1850e274b75aca31228b70c93e34 | [
"MIT"
] | null | null | null | test/spf_dns_test.exs | hertogp/spfcheck | bee61300f9be1850e274b75aca31228b70c93e34 | [
"MIT"
] | null | null | null | defmodule SpfDNSTest do
use ExUnit.Case
doctest Spf.DNS, import: true
describe "DNS cache" do
test "00 - caches zonedata from heredoc" do
zonedata = """
example.com A 1.2.3.4
example.com AAAA 2001::1
example.com MX 10 mail.example.com
example.com TXT v=spf1 -all
example.co... | 32.4047 | 99 | 0.560148 |
737d549c19c836424a1bca34b98d063e27c796a6 | 61 | ex | Elixir | lib/fighter_web/views/user_view.ex | gautambaghel/fighter | 970a098f0d234892af351070b6b2b596b9a2d83c | [
"Apache-2.0"
] | null | null | null | lib/fighter_web/views/user_view.ex | gautambaghel/fighter | 970a098f0d234892af351070b6b2b596b9a2d83c | [
"Apache-2.0"
] | null | null | null | lib/fighter_web/views/user_view.ex | gautambaghel/fighter | 970a098f0d234892af351070b6b2b596b9a2d83c | [
"Apache-2.0"
] | null | null | null | defmodule FighterWeb.UserView do
use FighterWeb, :view
end
| 15.25 | 32 | 0.803279 |
737d57fc1cec8600bed4a3146c561fc93e3a1861 | 167 | exs | Elixir | apps/omg/config/dev.exs | PinkDiamond1/elixir-omg | 70dfd24a0a1ddf5d1d9d71aab61ea25300f889f7 | [
"Apache-2.0"
] | 1 | 2020-05-01T12:30:09.000Z | 2020-05-01T12:30:09.000Z | apps/omg/config/dev.exs | PinkDiamond1/elixir-omg | 70dfd24a0a1ddf5d1d9d71aab61ea25300f889f7 | [
"Apache-2.0"
] | null | null | null | apps/omg/config/dev.exs | PinkDiamond1/elixir-omg | 70dfd24a0a1ddf5d1d9d71aab61ea25300f889f7 | [
"Apache-2.0"
] | 1 | 2021-12-04T00:37:46.000Z | 2021-12-04T00:37:46.000Z | # dev config necessary to load project in iex
use Mix.Config
config :omg,
ethereum_events_check_interval_ms: 500,
coordinator_eth_height_check_interval_ms: 1_000
| 23.857143 | 49 | 0.826347 |
737d7c459256aed3f0b71e00fb56063cac3f1d94 | 5,128 | ex | Elixir | lib/step_flow/amqp/common_consumer.ex | mathiaHT/ex_step_flow | 6496e9511239de64f00119428476338dfcde9dea | [
"MIT"
] | 4 | 2019-12-07T05:18:26.000Z | 2020-11-06T23:28:43.000Z | lib/step_flow/amqp/common_consumer.ex | mathiaHT/ex_step_flow | 6496e9511239de64f00119428476338dfcde9dea | [
"MIT"
] | 53 | 2020-01-06T11:23:09.000Z | 2021-06-25T15:30:07.000Z | lib/step_flow/amqp/common_consumer.ex | mathiaHT/ex_step_flow | 6496e9511239de64f00119428476338dfcde9dea | [
"MIT"
] | 3 | 2020-01-30T15:37:40.000Z | 2020-10-27T14:10:02.000Z | defmodule StepFlow.Amqp.CommonConsumer do
@moduledoc """
Definition of a Common Consumer of RabbitMQ queue.
To implement a consumer,
```elixir
defmodule MyModule do
use StepFlow.Amqp.CommonConsumer, %{
queue: "name_of_the_rabbit_mq_queue",
consumer: &MyModule.consume/4
}
def consume... | 29.813953 | 103 | 0.596139 |
737d88c2feae6b2eda98148195dbe139cff67f26 | 5,685 | exs | Elixir | test/plug/adapters/cowboy2_test.exs | qcam/plug | c547f2bd7a64aec7c4759dcc1ed88b6eab0c7499 | [
"Apache-2.0"
] | null | null | null | test/plug/adapters/cowboy2_test.exs | qcam/plug | c547f2bd7a64aec7c4759dcc1ed88b6eab0c7499 | [
"Apache-2.0"
] | null | null | null | test/plug/adapters/cowboy2_test.exs | qcam/plug | c547f2bd7a64aec7c4759dcc1ed88b6eab0c7499 | [
"Apache-2.0"
] | null | null | null | defmodule Plug.Adapters.Cowboy2Test do
use ExUnit.Case, async: true
import Plug.Adapters.Cowboy2
@moduletag :cowboy2
def init([]) do
[foo: :bar]
end
handler = {:_, [], Plug.Adapters.Cowboy2.Handler, {Plug.Adapters.Cowboy2Test, [foo: :bar]}}
@dispatch [{:_, [], [handler]}]
if function_exported?(... | 34.246988 | 98 | 0.577661 |
737d9d3e1f16513d4c035e62ff86a5338fcb980b | 1,652 | ex | Elixir | lib/hex/shell/process.ex | Benjamin-Philip/hex | 19860cfb33fee0a80c49d38ef1d5f407baa72148 | [
"Apache-2.0"
] | 824 | 2015-01-05T09:12:36.000Z | 2022-03-28T12:02:29.000Z | lib/hex/shell/process.ex | Benjamin-Philip/hex | 19860cfb33fee0a80c49d38ef1d5f407baa72148 | [
"Apache-2.0"
] | 737 | 2015-01-01T05:48:46.000Z | 2022-03-29T12:56:12.000Z | lib/hex/shell/process.ex | Benjamin-Philip/hex | 19860cfb33fee0a80c49d38ef1d5f407baa72148 | [
"Apache-2.0"
] | 220 | 2015-03-14T17:55:11.000Z | 2022-03-23T22:17:07.000Z | defmodule Hex.Shell.Process do
@moduledoc false
@behaviour Mix.Shell
def flush(callback \\ fn x -> x end) do
receive do
{:mix_shell, _, _} = message ->
callback.(message)
flush(callback)
{:mix_shell_input, _, _} = message ->
callback.(message)
flush(callback)
... | 21.454545 | 61 | 0.595642 |
737da21a2762f0a70d3dae7b670f642854781832 | 1,041 | ex | Elixir | lib/pgex/result.ex | karlseguin/pgex | 2921f350c9f8c8f72cc75c7ede85728ea5dba1bf | [
"MIT"
] | null | null | null | lib/pgex/result.ex | karlseguin/pgex | 2921f350c9f8c8f72cc75c7ede85728ea5dba1bf | [
"MIT"
] | null | null | null | lib/pgex/result.ex | karlseguin/pgex | 2921f350c9f8c8f72cc75c7ede85728ea5dba1bf | [
"MIT"
] | null | null | null | defmodule PgEx.Result do
@moduledoc """
Represents the result of a query
"""
defstruct [:it, :rows, :columns, :affected]
@typedoc """
The enumerable result returned by a query.
"""
@type t :: %__MODULE__{
it: [any],
rows: [any],
columns: [String.t],
affected: non_neg_integer,
}
... | 26.025 | 87 | 0.626321 |
737da3043e5828427b3683b9d212127286d870fb | 122 | exs | Elixir | .formatter.exs | gamache/ets_deque | dbd949b0f461d70d19e47c3d910f9bb029c7369e | [
"MIT"
] | 2 | 2020-01-27T16:15:45.000Z | 2020-01-29T18:14:04.000Z | .formatter.exs | gamache/ets_deque | dbd949b0f461d70d19e47c3d910f9bb029c7369e | [
"MIT"
] | null | null | null | .formatter.exs | gamache/ets_deque | dbd949b0f461d70d19e47c3d910f9bb029c7369e | [
"MIT"
] | 1 | 2021-03-18T10:33:30.000Z | 2021-03-18T10:33:30.000Z | # Used by "mix format"
[
inputs: ["{mix,.formatter}.exs", "{config,lib,test}/**/*.{ex,exs}"],
trailing_comma: true,
]
| 20.333333 | 70 | 0.590164 |
737dd179d61dd476b5e334a08a5d49e35ba37c1a | 1,601 | ex | Elixir | clients/plus/lib/google_api/plus/v1/model/activity_object_plusoners.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | 1 | 2021-12-20T03:40:53.000Z | 2021-12-20T03:40:53.000Z | clients/plus/lib/google_api/plus/v1/model/activity_object_plusoners.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | 1 | 2020-08-18T00:11:23.000Z | 2020-08-18T00:44:16.000Z | clients/plus/lib/google_api/plus/v1/model/activity_object_plusoners.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | 1 | 2020-10-04T10:12:44.000Z | 2020-10-04T10:12:44.000Z | # Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, s... | 32.02 | 118 | 0.722049 |
737dd6b0221b7ef5de59ae2ed27b3be5fd47179a | 310 | ex | Elixir | lib/daily_meals/users/delete.ex | vinolivae/daily_meals | 8f375cbb7eaf54abfa6b683705bb8075067f9078 | [
"MIT"
] | null | null | null | lib/daily_meals/users/delete.ex | vinolivae/daily_meals | 8f375cbb7eaf54abfa6b683705bb8075067f9078 | [
"MIT"
] | null | null | null | lib/daily_meals/users/delete.ex | vinolivae/daily_meals | 8f375cbb7eaf54abfa6b683705bb8075067f9078 | [
"MIT"
] | null | null | null | defmodule DailyMeals.Users.Delete do
alias DailyMeals.{Error, Repo, User}
@spec delete(uuid :: String.t()) :: User.t() | Error.t()
def delete(uuid) do
case Repo.get(User, uuid) do
nil -> {:error, Error.build_not_found_error("User not found")}
user -> Repo.delete(user)
end
end
end
| 25.833333 | 68 | 0.648387 |
737dfe4de89d61986860b71239ecfebc8d0b7144 | 76 | exs | Elixir | test/seren_web/views/page_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/page_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/page_view_test.exs | allen-garvey/seren | f61cb7edcd7d3f927d2929db14b2a4a1578a3925 | [
"MIT"
] | null | null | null | defmodule SerenWeb.PageViewTest do
use SerenWeb.ConnCase, async: true
end
| 19 | 36 | 0.815789 |
737dffe4769988ab585762ec407da3b51c29bb61 | 385 | ex | Elixir | redfour/physics/lib/physics/rocketry.ex | mdeilman/ElixirCode | d0560c7b135b4cb146dccb8202b9e4dede199a1b | [
"Apache-2.0"
] | null | null | null | redfour/physics/lib/physics/rocketry.ex | mdeilman/ElixirCode | d0560c7b135b4cb146dccb8202b9e4dede199a1b | [
"Apache-2.0"
] | null | null | null | redfour/physics/lib/physics/rocketry.ex | mdeilman/ElixirCode | d0560c7b135b4cb146dccb8202b9e4dede199a1b | [
"Apache-2.0"
] | null | null | null |
defmodule Physics.Planet do
defstruct [
name: "Earth",
radius_m: 6.371e6,
mass_kg: 5.97e24
]
def escape_velocity(planet) do
g = 6.67e-11
gmr = 2 * g * planet.mass_kg/planet.radius_m
vms = :math.sqrt gmr
vkms = vms/1000
Float.ceil vkms, 1
end
end
v = %Physics.Planet{} |> Physi... | 16.73913 | 57 | 0.649351 |
737e09f9da7f1fd4aaca922cfd58a407b0be4010 | 370 | exs | Elixir | priv/repo/migrations/20200531151254_create_redirects.exs | meltingice/conductor | 630440adc1081a0991d3dba17ced775a9dd05055 | [
"MIT"
] | null | null | null | priv/repo/migrations/20200531151254_create_redirects.exs | meltingice/conductor | 630440adc1081a0991d3dba17ced775a9dd05055 | [
"MIT"
] | 2 | 2021-03-10T20:23:26.000Z | 2021-05-11T15:56:49.000Z | priv/repo/migrations/20200531151254_create_redirects.exs | meltingice/conductor | 630440adc1081a0991d3dba17ced775a9dd05055 | [
"MIT"
] | 1 | 2020-06-05T02:34:58.000Z | 2020-06-05T02:34:58.000Z | defmodule Conductor.Repo.Migrations.CreateRedirects do
use Ecto.Migration
def change do
create table(:redirects, primary_key: false) do
add :id, :uuid, primary_key: true
add :code, :string
add :destination, :text
add :views, :integer, default: 0
timestamps()
end
create i... | 21.764706 | 54 | 0.662162 |
737e2139ce5da09e9cad0f622c9da85c6050d918 | 2,586 | ex | Elixir | clients/dialogflow/lib/google_api/dialogflow/v3/model/google_cloud_dialogflow_v2beta1_original_detect_intent_request.ex | renovate-bot/elixir-google-api | 1da34cd39b670c99f067011e05ab90af93fef1f6 | [
"Apache-2.0"
] | 1 | 2021-12-20T03:40:53.000Z | 2021-12-20T03:40:53.000Z | clients/dialogflow/lib/google_api/dialogflow/v3/model/google_cloud_dialogflow_v2beta1_original_detect_intent_request.ex | swansoffiee/elixir-google-api | 9ea6d39f273fb430634788c258b3189d3613dde0 | [
"Apache-2.0"
] | 1 | 2020-08-18T00:11:23.000Z | 2020-08-18T00:44:16.000Z | clients/dialogflow/lib/google_api/dialogflow/v3/model/google_cloud_dialogflow_v2beta1_original_detect_intent_request.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... | 44.586207 | 591 | 0.734339 |
737e48ad5213cbbd49cf40846313824c6bceda35 | 871 | ex | Elixir | lib/rocketpay_web/controllers/accounts_controller.ex | lucas-sachet/NLW04 | 1c678764d49d421d73d6beb942036593863397e0 | [
"MIT"
] | null | null | null | lib/rocketpay_web/controllers/accounts_controller.ex | lucas-sachet/NLW04 | 1c678764d49d421d73d6beb942036593863397e0 | [
"MIT"
] | null | null | null | lib/rocketpay_web/controllers/accounts_controller.ex | lucas-sachet/NLW04 | 1c678764d49d421d73d6beb942036593863397e0 | [
"MIT"
] | null | null | null | defmodule RocketpayWeb.AccountsController do
use RocketpayWeb, :controller
alias Rocketpay.Accounts.Transaction.Response, as: TransactionResponse
alias Rocketpay.Account
action_fallback RocketpayWeb.FallbackController
def deposit(conn, params) do
with {:ok, %Account{} = account} <- Rocketpay.deposit(pa... | 26.393939 | 88 | 0.677382 |
737e657f0c4e38af5172a3d2afa4ed7e31d5990d | 17,317 | exs | Elixir | test/ethereumex/http_client_test.exs | InoMurko/ethereumex | f8e18f8aa2d2f1719a67c69f11486621416ac324 | [
"MIT"
] | 158 | 2018-11-05T23:45:47.000Z | 2022-03-21T18:58:31.000Z | test/ethereumex/http_client_test.exs | hawku-com/ethereumex | 19a5cf1a4fcfd6c06aae3f97554c8a9af3f2d89b | [
"MIT"
] | 43 | 2018-11-02T18:45:50.000Z | 2022-02-28T09:09:46.000Z | test/ethereumex/http_client_test.exs | hawku-com/ethereumex | 19a5cf1a4fcfd6c06aae3f97554c8a9af3f2d89b | [
"MIT"
] | 28 | 2018-11-13T16:33:31.000Z | 2022-03-31T17:49:11.000Z | defmodule Ethereumex.HttpClientTest do
use ExUnit.Case
alias Ethereumex.HttpClient
@tag :web3
describe "HttpClient.web3_client_version/0" do
test "returns client version" do
result = HttpClient.web3_client_version()
{:ok, <<_::binary>>} = result
end
end
@tag :web3
describe "HttpClie... | 26.559816 | 145 | 0.674828 |
737e7500bf8e7eb28e0d8ef60c51420690946c4d | 2,801 | exs | Elixir | test/mongo/retryable_reads_test.exs | aenglisc/elixir-mongodb-driver | a8a72fbb8690f44ac349e0449616ac2cfbf50640 | [
"Apache-2.0"
] | 140 | 2019-04-10T09:23:53.000Z | 2022-03-27T12:37:02.000Z | test/mongo/retryable_reads_test.exs | aenglisc/elixir-mongodb-driver | a8a72fbb8690f44ac349e0449616ac2cfbf50640 | [
"Apache-2.0"
] | 99 | 2019-04-11T07:46:45.000Z | 2022-03-31T07:23:28.000Z | test/mongo/retryable_reads_test.exs | aenglisc/elixir-mongodb-driver | a8a72fbb8690f44ac349e0449616ac2cfbf50640 | [
"Apache-2.0"
] | 45 | 2019-07-15T07:06:21.000Z | 2021-11-24T09:23:21.000Z | defmodule Mongo.RetryableReadsTest do
use CollectionCase
alias Mongo.Error
alias Mongo.Session
test "find_one", %{pid: top, catcher: catcher} do
coll = unique_collection()
Mongo.insert_one(top, coll, %{name: "Greta", age: 10})
Mongo.insert_one(top, coll, %{name: "Tom", age: 13})
Mongo.insert... | 33.746988 | 143 | 0.622992 |
737e7be5160eaca36dc29f7ed1717361e1c31967 | 753 | ex | Elixir | lib/firestorm_web/forums/thread.ex | chriswk/firestorm | 7440d4e84db34a093a7c8761973c737561f53b45 | [
"MIT"
] | null | null | null | lib/firestorm_web/forums/thread.ex | chriswk/firestorm | 7440d4e84db34a093a7c8761973c737561f53b45 | [
"MIT"
] | 4 | 2021-03-01T21:25:42.000Z | 2022-02-10T23:50:11.000Z | lib/firestorm_web/forums/thread.ex | chriswk/firestorm | 7440d4e84db34a093a7c8761973c737561f53b45 | [
"MIT"
] | null | null | null | defmodule FirestormWeb.Forums.Thread do
@moduledoc """
Schema for forum threads.
"""
use Ecto.Schema
alias FirestormWeb.Forums.{Category, Post, Watch, User}
alias FirestormWeb.Forums.Slugs.ThreadTitleSlug
schema "forums_threads" do
field :title, :string
field :slug, ThreadTitleSlug.Type
fie... | 30.12 | 114 | 0.719788 |
737e95c1aead721728a340405ddcc4a7b3dbd487 | 388 | exs | Elixir | test/level/feature_flags_test.exs | pradyumna2905/level | 186878a128521074923edd7171eda2f1b181b4f4 | [
"Apache-2.0"
] | 1 | 2019-06-11T20:20:32.000Z | 2019-06-11T20:20:32.000Z | test/level/feature_flags_test.exs | pradyumna2905/level | 186878a128521074923edd7171eda2f1b181b4f4 | [
"Apache-2.0"
] | null | null | null | test/level/feature_flags_test.exs | pradyumna2905/level | 186878a128521074923edd7171eda2f1b181b4f4 | [
"Apache-2.0"
] | null | null | null | defmodule Level.FeatureFlagsTest do
use Level.DataCase, async: true
alias Level.FeatureFlags
describe "signups_enabled?/1" do
test "is true in non-prod environments" do
assert FeatureFlags.signups_enabled?(:test)
assert FeatureFlags.signups_enabled?(:dev)
end
test "is false in prod" do
... | 22.823529 | 49 | 0.719072 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.