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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
331ff2de55b49ccf076cc425151958bccb387072 | 2,907 | exs | Elixir | apps/reaper/test/integration/reaper/data_slurper/sftp_test.exs | msomji/smartcitiesdata | fc96abc1ef1306f7af6bd42bbcb4ed041a6d922c | [
"Apache-2.0"
] | null | null | null | apps/reaper/test/integration/reaper/data_slurper/sftp_test.exs | msomji/smartcitiesdata | fc96abc1ef1306f7af6bd42bbcb4ed041a6d922c | [
"Apache-2.0"
] | null | null | null | apps/reaper/test/integration/reaper/data_slurper/sftp_test.exs | msomji/smartcitiesdata | fc96abc1ef1306f7af6bd42bbcb4ed041a6d922c | [
"Apache-2.0"
] | null | null | null | defmodule Reaper.SftpExtractorTest do
use ExUnit.Case
use Divo
use Placebo
alias SmartCity.TestDataGenerator, as: TDG
import SmartCity.TestHelper
import SmartCity.Event, only: [dataset_update: 0]
@endpoints Application.get_env(:reaper, :elsa_brokers)
@output_topic_prefix Application.get_env(:reaper, :o... | 27.951923 | 80 | 0.599243 |
3320329a9cea66ed699c9ed7c59086383947fde5 | 14,116 | ex | Elixir | lib/ex_unit/lib/ex_unit/diff.ex | davidsulc/elixir | dd4fd6ab742acd75862e34e26dbdb86e0cf6453f | [
"Apache-2.0"
] | null | null | null | lib/ex_unit/lib/ex_unit/diff.ex | davidsulc/elixir | dd4fd6ab742acd75862e34e26dbdb86e0cf6453f | [
"Apache-2.0"
] | null | null | null | lib/ex_unit/lib/ex_unit/diff.ex | davidsulc/elixir | dd4fd6ab742acd75862e34e26dbdb86e0cf6453f | [
"Apache-2.0"
] | null | null | null | defmodule ExUnit.Diff do
@moduledoc false
@doc """
Returns an edit script representing the difference between `left` and `right`.
Returns `nil` if they are not the same data type,
or if the given data type is not supported.
"""
def script(left, right)
def script(term, term)
when is_binary(term)... | 30.291845 | 107 | 0.6035 |
33203c73a17acb9eb7bc07417fd5e1daac3d94dc | 957 | ex | Elixir | test/support/test_shard_consumer.ex | slievr/kcl_ex | c1620ba68b56da1802e6e9fafdb3da14155b90d7 | [
"Apache-2.0"
] | 4 | 2017-12-19T15:27:54.000Z | 2021-06-04T13:04:49.000Z | test/support/test_shard_consumer.ex | slievr/kcl_ex | c1620ba68b56da1802e6e9fafdb3da14155b90d7 | [
"Apache-2.0"
] | 2 | 2021-03-05T12:01:24.000Z | 2021-12-03T22:34:24.000Z | test/support/test_shard_consumer.ex | slievr/kcl_ex | c1620ba68b56da1802e6e9fafdb3da14155b90d7 | [
"Apache-2.0"
] | 3 | 2021-02-17T16:14:11.000Z | 2021-12-10T05:26:25.000Z | defmodule KinesisClient.TestShardConsumer do
@behaviour Broadway
@impl Broadway
def handle_message(processor, msg, context) do
case Map.get(context, :notify_pid) do
nil -> send(self(), {:handle_message, processor, msg, context})
pid when is_pid(pid) -> send(pid, {:handle_message, processor, msg, ... | 28.147059 | 96 | 0.682341 |
33205a271d8932940364e7c00c0f8ea376081a44 | 75 | ex | Elixir | lib/mockatron/mailer.ex | rzcastilho/mockatron | 237b2bad3e1bf167a6ebac218c7a46b74a9063ee | [
"MIT"
] | 1 | 2018-12-13T16:52:22.000Z | 2018-12-13T16:52:22.000Z | lib/mockatron/mailer.ex | rzcastilho/mockatron | 237b2bad3e1bf167a6ebac218c7a46b74a9063ee | [
"MIT"
] | 28 | 2019-07-04T08:42:33.000Z | 2022-03-28T08:24:07.000Z | lib/mockatron/mailer.ex | rzcastilho/mockatron | 237b2bad3e1bf167a6ebac218c7a46b74a9063ee | [
"MIT"
] | null | null | null | defmodule Mockatron.Mailer do
use Bamboo.Mailer, otp_app: :mockatron
end
| 18.75 | 40 | 0.8 |
33205b9910e4090e60ec1c3b9afdbbb785571314 | 2,048 | exs | Elixir | test/paddle/product/product_test.exs | MMore/paddlex | f84bb525446a13fe5d8af20975276eb712149744 | [
"MIT"
] | 7 | 2021-09-27T10:10:30.000Z | 2022-03-31T09:44:35.000Z | test/paddle/product/product_test.exs | MMore/paddlex | f84bb525446a13fe5d8af20975276eb712149744 | [
"MIT"
] | 2 | 2021-09-29T16:57:41.000Z | 2022-01-25T12:43:26.000Z | test/paddle/product/product_test.exs | MMore/paddlex | f84bb525446a13fe5d8af20975276eb712149744 | [
"MIT"
] | 2 | 2021-09-27T10:12:40.000Z | 2022-01-24T21:28:20.000Z | defmodule Paddle.ProductTest do
use ExUnit.Case
setup do
bypass = Bypass.open(port: 12_345)
{:ok, bypass: bypass}
end
test "list products", %{bypass: bypass} do
Bypass.expect(bypass, fn conn ->
Plug.Conn.resp(conn, 200, ~s(
{
"success": true,
"response": {
... | 29.681159 | 88 | 0.421387 |
3320ae9818ee1730c8a325aa2ec423e3bc988075 | 1,840 | ex | Elixir | clients/service_networking/lib/google_api/service_networking/v1/model/list_operations_response.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | null | null | null | clients/service_networking/lib/google_api/service_networking/v1/model/list_operations_response.ex | medikent/elixir-google-api | 98a83d4f7bfaeac15b67b04548711bb7e49f9490 | [
"Apache-2.0"
] | 1 | 2020-12-18T09:25:12.000Z | 2020-12-18T09:25:12.000Z | clients/service_networking/lib/google_api/service_networking/v1/model/list_operations_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... | 36.8 | 176 | 0.747826 |
3320c4544a46482cb403ec78afeef2343ee4b459 | 11,808 | ex | Elixir | lib/blue_jet/app/catalogue/product.ex | freshcom/freshcom-api | 4f2083277943cf4e4e8fd4c4d443c7309f285ad7 | [
"BSD-3-Clause"
] | 44 | 2018-05-09T01:08:57.000Z | 2021-01-19T07:25:26.000Z | lib/blue_jet/app/catalogue/product.ex | freshcom/freshcom-api | 4f2083277943cf4e4e8fd4c4d443c7309f285ad7 | [
"BSD-3-Clause"
] | 36 | 2018-05-08T23:59:54.000Z | 2018-09-28T13:50:30.000Z | lib/blue_jet/app/catalogue/product.ex | freshcom/freshcom-api | 4f2083277943cf4e4e8fd4c4d443c7309f285ad7 | [
"BSD-3-Clause"
] | 9 | 2018-05-09T14:09:19.000Z | 2021-03-21T21:04:04.000Z | defmodule BlueJet.Catalogue.Product do
@behaviour BlueJet.Data
use BlueJet, :data
alias BlueJet.Catalogue.Price
alias __MODULE__.{Query, Proxy}
schema "products" do
field :account_id, UUID
field :account, :map, virtual: true
field :status, :string, default: "draft"
field :code, :string
... | 26.77551 | 106 | 0.629488 |
3320c54b8aad9598b0176c19e0e3a1680abb558d | 2,085 | ex | Elixir | lib/scaffolding/protocols/permission_protocol.ex | noizu-labs/advanced_elixir_scaffolding | 9e7a1199a4b25fcc16fc5a795104b926d2f238df | [
"MIT"
] | null | null | null | lib/scaffolding/protocols/permission_protocol.ex | noizu-labs/advanced_elixir_scaffolding | 9e7a1199a4b25fcc16fc5a795104b926d2f238df | [
"MIT"
] | null | null | null | lib/scaffolding/protocols/permission_protocol.ex | noizu-labs/advanced_elixir_scaffolding | 9e7a1199a4b25fcc16fc5a795104b926d2f238df | [
"MIT"
] | null | null | null | #-------------------------------------------------------------------------------
# Author: Keith Brings <keith.brings@noizu.com>
# Copyright (C) 2021 Noizu Labs Inc. All rights reserved.
#-------------------------------------------------------------------------------
defprotocol Noizu.Permission.Protocol do
@doc "Ch... | 40.882353 | 82 | 0.607674 |
3320d747277d9eb1c4b4d1a550c0c0687efaafaf | 20,614 | ex | Elixir | lib/elixir/lib/io/ansi/docs.ex | brandondrew/elixir | 0bbd33fa9a2411920dce505340097a6c0e73bc46 | [
"Apache-2.0"
] | null | null | null | lib/elixir/lib/io/ansi/docs.ex | brandondrew/elixir | 0bbd33fa9a2411920dce505340097a6c0e73bc46 | [
"Apache-2.0"
] | null | null | null | lib/elixir/lib/io/ansi/docs.ex | brandondrew/elixir | 0bbd33fa9a2411920dce505340097a6c0e73bc46 | [
"Apache-2.0"
] | null | null | null | defmodule IO.ANSI.Docs do
@moduledoc false
@bullets [?*, ?-, ?+]
@spaces [" ", "\n", "\t"]
@doc """
The default options used by this module.
The supported keys are:
* `:enabled` - toggles coloring on and off (true)
* `:doc_bold` - bold text (bright)
* `:doc_code` ... | 31.045181 | 98 | 0.628262 |
3320da54682bb923b8398986ce44912bf0d348cc | 18,509 | exs | Elixir | test/teslamate/vehicles/vehicle/suspend_test.exs | wishbone1138/teslamate | 6047e1306a67241cbfccf3e33dc2cf2636c55a66 | [
"MIT"
] | null | null | null | test/teslamate/vehicles/vehicle/suspend_test.exs | wishbone1138/teslamate | 6047e1306a67241cbfccf3e33dc2cf2636c55a66 | [
"MIT"
] | null | null | null | test/teslamate/vehicles/vehicle/suspend_test.exs | wishbone1138/teslamate | 6047e1306a67241cbfccf3e33dc2cf2636c55a66 | [
"MIT"
] | null | null | null | defmodule TeslaMate.Vehicles.Vehicle.SuspendTest do
use TeslaMate.VehicleCase, async: true
alias TeslaMate.Vehicles.Vehicle
test "suspends when idling", %{test: name} do
suspendable =
online_event(
drive_state: %{timestamp: 0, latitude: 0.0, longitude: 0.0},
climate_state: %{is_precond... | 29.998379 | 96 | 0.61154 |
3320ee4e3f337228f80c118a1debd9160c856d6b | 3,175 | ex | Elixir | clients/firestore/lib/google_api/firestore/v1beta1/model/field_transform.ex | mocknen/elixir-google-api | dac4877b5da2694eca6a0b07b3bd0e179e5f3b70 | [
"Apache-2.0"
] | null | null | null | clients/firestore/lib/google_api/firestore/v1beta1/model/field_transform.ex | mocknen/elixir-google-api | dac4877b5da2694eca6a0b07b3bd0e179e5f3b70 | [
"Apache-2.0"
] | null | null | null | clients/firestore/lib/google_api/firestore/v1beta1/model/field_transform.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.741379 | 565 | 0.757795 |
3320f3799cbd3b2763d02c66ef9cda24da8aa9b0 | 534 | ex | Elixir | lib/cadet/devices/device.ex | chownces/cadet | 0d8b264e4fad1c9aaab7ef3f037ac4e07a4c9b22 | [
"Apache-2.0"
] | 27 | 2018-01-20T05:56:24.000Z | 2021-05-24T03:21:55.000Z | lib/cadet/devices/device.ex | chownces/cadet | 0d8b264e4fad1c9aaab7ef3f037ac4e07a4c9b22 | [
"Apache-2.0"
] | 731 | 2018-04-16T13:25:49.000Z | 2021-06-22T07:16:12.000Z | lib/cadet/devices/device.ex | chownces/cadet | 0d8b264e4fad1c9aaab7ef3f037ac4e07a4c9b22 | [
"Apache-2.0"
] | 43 | 2018-01-20T06:35:46.000Z | 2021-05-05T03:22:35.000Z | defmodule Cadet.Devices.Device do
@moduledoc """
Represents a remote execution device.
"""
use Cadet, :model
schema "devices" do
field(:secret, :string)
field(:type, :string)
field(:client_key, :binary)
field(:client_cert, :binary)
timestamps()
end
@required_fields ~w(secret type)... | 19.777778 | 57 | 0.67603 |
3320f37df14a72d4ede14f438d0e38c756bdfbe5 | 191 | exs | Elixir | priv/test_repo/migrations/20170211134230_article_user.exs | nickolaich/formex_ecto | 322907daa4924d1c297acc7f9e60f99bc8f2f6f3 | [
"MIT"
] | 20 | 2017-06-25T12:30:03.000Z | 2021-04-25T06:43:31.000Z | priv/test_repo/migrations/20170211134230_article_user.exs | nickolaich/formex_ecto | 322907daa4924d1c297acc7f9e60f99bc8f2f6f3 | [
"MIT"
] | 8 | 2017-11-19T17:15:32.000Z | 2020-02-02T12:50:03.000Z | priv/test_repo/migrations/20170211134230_article_user.exs | nickolaich/formex_ecto | 322907daa4924d1c297acc7f9e60f99bc8f2f6f3 | [
"MIT"
] | 9 | 2018-03-30T22:14:13.000Z | 2021-11-15T12:12:56.000Z | defmodule App.Repo.Migrations.ArticleUser do
use Ecto.Migration
def change do
alter table(:articles) do
add :user_id, references(:users, on_delete: :nothing)
end
end
end
| 19.1 | 59 | 0.712042 |
3321431f3feb45f9b573aa467df767486c2cad73 | 624 | exs | Elixir | projects/hermit/mix.exs | erik/sketches | 0a454ada58dee6db576e93cb2216dd750290329e | [
"MIT"
] | 1 | 2020-02-11T06:00:11.000Z | 2020-02-11T06:00:11.000Z | projects/hermit/mix.exs | erik/sketches | 0a454ada58dee6db576e93cb2216dd750290329e | [
"MIT"
] | 1 | 2017-09-23T19:41:29.000Z | 2017-09-25T05:12:38.000Z | projects/hermit/mix.exs | erik/sketches | 0a454ada58dee6db576e93cb2216dd750290329e | [
"MIT"
] | null | null | null | defmodule Hermit.Mixfile do
use Mix.Project
def project do
[app: :hermit,
version: "0.1.0",
elixir: "~> 1.4",
build_embedded: Mix.env == :prod,
start_permanent: Mix.env == :prod,
deps: deps()]
end
# Configuration for the OTP application
#
# Type "mix help compile.app" for more... | 21.517241 | 62 | 0.591346 |
33217843b407339b959a246efaae05dcc974b819 | 1,574 | ex | Elixir | examples/phoenix_app/lib/phoenix_app_web/endpoint.ex | kianmeng/bakeware | 3c008a1c149ccf22cb3924126f2b8f0be522191f | [
"Apache-2.0"
] | 828 | 2020-09-12T18:56:48.000Z | 2022-03-01T22:34:39.000Z | examples/phoenix_app/lib/phoenix_app_web/endpoint.ex | kianmeng/bakeware | 3c008a1c149ccf22cb3924126f2b8f0be522191f | [
"Apache-2.0"
] | 54 | 2020-10-23T15:01:10.000Z | 2022-03-22T23:23:15.000Z | examples/phoenix_app/lib/phoenix_app_web/endpoint.ex | kianmeng/bakeware | 3c008a1c149ccf22cb3924126f2b8f0be522191f | [
"Apache-2.0"
] | 25 | 2020-09-14T12:01:54.000Z | 2022-02-23T03:30:08.000Z | defmodule PhoenixAppWeb.Endpoint do
use Phoenix.Endpoint, otp_app: :phoenix_app
# 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: "_ph... | 29.148148 | 97 | 0.720457 |
3321a100eece84400428383eb332c8b2bf3a788c | 719 | exs | Elixir | config/test.exs | awochna/quick_polls | b599918b795728feda338e6a00f295a97faba08a | [
"MIT"
] | null | null | null | config/test.exs | awochna/quick_polls | b599918b795728feda338e6a00f295a97faba08a | [
"MIT"
] | 6 | 2017-04-10T05:01:04.000Z | 2017-04-21T06:02:03.000Z | config/test.exs | awochna/quick_polls | b599918b795728feda338e6a00f295a97faba08a | [
"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 :quick_polls, QuickPolls.Web.Endpoint,
http: [port: 4001],
server: false
# Print only warnings and errors during test
config :logger, level: :warn
# Drop requirements for password hashing inte... | 29.958333 | 60 | 0.751043 |
3321e5ad9e1d12ad69c494b15b3faff683033704 | 120 | ex | Elixir | redis_cache/lib/redis_cache/standalone.ex | cabol/nebulex_examples | 21bd2673eecfc0b5c7a2807a3a47488d99a7d725 | [
"MIT"
] | 25 | 2017-07-30T01:27:54.000Z | 2021-12-10T16:41:03.000Z | redis_cache/lib/redis_cache/standalone.ex | cabol/nebulex_examples | 21bd2673eecfc0b5c7a2807a3a47488d99a7d725 | [
"MIT"
] | 2 | 2019-11-12T09:41:26.000Z | 2021-11-08T13:51:24.000Z | redis_cache/lib/redis_cache/standalone.ex | cabol/nebulex_examples | 21bd2673eecfc0b5c7a2807a3a47488d99a7d725 | [
"MIT"
] | 1 | 2019-01-08T19:06:54.000Z | 2019-01-08T19:06:54.000Z | defmodule RedisCache.Standalone do
use Nebulex.Cache,
otp_app: :redis_cache,
adapter: NebulexRedisAdapter
end
| 20 | 34 | 0.775 |
33221b2bfa4df70eb9c040ec180559516e317f6e | 194 | ex | Elixir | lib/parser/reboot_response.ex | smiyabe/cwmp_ex | 9db322497aa3208b5985ccf496ada5286cde3925 | [
"Artistic-2.0"
] | 3 | 2017-11-29T05:07:35.000Z | 2019-12-18T17:16:41.000Z | lib/parser/reboot_response.ex | smiyabe/cwmp_ex | 9db322497aa3208b5985ccf496ada5286cde3925 | [
"Artistic-2.0"
] | 1 | 2021-12-02T19:35:28.000Z | 2022-03-29T09:40:52.000Z | lib/parser/reboot_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.RebootResponse do
use CWMP.Protocol.ParserHelpers
alias CWMP.Protocol.Messages.RebootResponse
def initial_acc do
%RebootResponse{}
end
end
| 17.636364 | 57 | 0.793814 |
33221eafe2c88a19b1b728279a98651b3e80e1e4 | 503 | ex | Elixir | lib/show_me_the_code_web/views/error_view.ex | intellild/show-me-the-code | 767461d631e57c4a1d56a959d41abe611d5ce51f | [
"MIT"
] | 161 | 2018-07-11T09:49:17.000Z | 2021-11-16T12:43:36.000Z | lib/show_me_the_code_web/views/error_view.ex | intellild/show-me-the-code | 767461d631e57c4a1d56a959d41abe611d5ce51f | [
"MIT"
] | 8 | 2018-08-16T06:46:58.000Z | 2021-08-25T03:37:42.000Z | lib/show_me_the_code_web/views/error_view.ex | intellild/show-me-the-code | 767461d631e57c4a1d56a959d41abe611d5ce51f | [
"MIT"
] | 18 | 2018-10-16T10:42:14.000Z | 2022-03-11T10:49:24.000Z | defmodule ShowMeTheCodeWeb.ErrorView do
use ShowMeTheCodeWeb, :view
# If you want to customize a particular status code
# for a certain format, you may uncomment below.
# def render("500.html", _assigns) do
# "Internal Server Error"
# end
# By default, Phoenix returns the status message from
# the t... | 29.588235 | 61 | 0.741551 |
332223bc07b74da40090e3ea82e0fa04cc17ec64 | 5,434 | ex | Elixir | lib/pigeon/adm.ex | stefanzvkvc/pigeon | 3de4179db924e0f003edb0a480a60e616699739e | [
"MIT"
] | 1 | 2021-09-05T13:34:21.000Z | 2021-09-05T13:34:21.000Z | lib/pigeon/adm.ex | stefanzvkvc/pigeon | 3de4179db924e0f003edb0a480a60e616699739e | [
"MIT"
] | null | null | null | lib/pigeon/adm.ex | stefanzvkvc/pigeon | 3de4179db924e0f003edb0a480a60e616699739e | [
"MIT"
] | null | null | null | defmodule Pigeon.ADM do
@moduledoc """
Amazon Device Messaging (ADM)
"""
alias Pigeon.ADM.{Config, Notification, Worker}
@typedoc ~S"""
Async callback for push notifications response.
## Examples
handler = fn(%Pigeon.ADM.Notification{response: response}) ->
case response do
:su... | 29.215054 | 80 | 0.621457 |
33223f1990607d2ed8f05b25d5361078005f8722 | 113 | exs | Elixir | .formatter.exs | JamesFerguson/exq | 4457ea50ad4c8a6a7e127da5acafc130960822bb | [
"Apache-2.0"
] | null | null | null | .formatter.exs | JamesFerguson/exq | 4457ea50ad4c8a6a7e127da5acafc130960822bb | [
"Apache-2.0"
] | null | null | null | .formatter.exs | JamesFerguson/exq | 4457ea50ad4c8a6a7e127da5acafc130960822bb | [
"Apache-2.0"
] | null | null | null | [
inputs: [
"config/**/*.{ex,exs}",
"lib/**/*.{ex,exs}",
"test/**/*.{ex,exs}",
"mix.exs"
]
]
| 12.555556 | 27 | 0.353982 |
33227349339de62177347a53f1e56084dc6a6006 | 8,387 | ex | Elixir | lib/iex/lib/iex/introspection.ex | fishcakez/elixir | 1b8ab9ae0b28ddbbb867a85f86fcdaa15ef522a0 | [
"Apache-2.0"
] | null | null | null | lib/iex/lib/iex/introspection.ex | fishcakez/elixir | 1b8ab9ae0b28ddbbb867a85f86fcdaa15ef522a0 | [
"Apache-2.0"
] | null | null | null | lib/iex/lib/iex/introspection.ex | fishcakez/elixir | 1b8ab9ae0b28ddbbb867a85f86fcdaa15ef522a0 | [
"Apache-2.0"
] | null | null | null | # Convenience helpers for showing docs, specs and types
# from modules. Invoked directly from IEX.Helpers.
defmodule IEx.Introspection do
@moduledoc false
import IEx, only: [dont_display_result: 0]
@doc false
def h(module) when is_atom(module) do
case Code.ensure_loaded(module) do
{ :module, _ } ->
... | 26.795527 | 135 | 0.593776 |
332285cd35a30ac59b12d8c232ed809257e95631 | 5,162 | exs | Elixir | deps/phoenix_pubsub/test/shared/pubsub_test.exs | hallebadkapp/rumbl-ms | ae2ef9975658115f8c4d5c49c28d8bde00a74b83 | [
"MIT"
] | null | null | null | deps/phoenix_pubsub/test/shared/pubsub_test.exs | hallebadkapp/rumbl-ms | ae2ef9975658115f8c4d5c49c28d8bde00a74b83 | [
"MIT"
] | null | null | null | deps/phoenix_pubsub/test/shared/pubsub_test.exs | hallebadkapp/rumbl-ms | ae2ef9975658115f8c4d5c49c28d8bde00a74b83 | [
"MIT"
] | null | null | null | defmodule Phoenix.PubSubTest do
@moduledoc """
Sets up PubSub Adapter testcases
## Usage
To test a PubSub adapter, set the `:pubsub_test_adapter` on the `:phoenix`
configuration and require this file, ie:
# your_pubsub_adapter_test.exs
Application.put_env(:phoenix, :pubsub_test_adapter, Phoeni... | 32.465409 | 101 | 0.657885 |
3322baae5338af5215eec70d315ed5c43b54d678 | 3,119 | exs | Elixir | test/wallaby/http_client_test.exs | JonRowe/wallaby | 00a7b4efdfecb374e4827fa106503e689a4dd967 | [
"MIT"
] | null | null | null | test/wallaby/http_client_test.exs | JonRowe/wallaby | 00a7b4efdfecb374e4827fa106503e689a4dd967 | [
"MIT"
] | null | null | null | test/wallaby/http_client_test.exs | JonRowe/wallaby | 00a7b4efdfecb374e4827fa106503e689a4dd967 | [
"MIT"
] | null | null | null | defmodule Wallaby.HTTPClientTest do
use Wallaby.HttpClientCase, async: true
alias Wallaby.HTTPClient, as: Client
describe "request/4" do
test "sends the request with the correct params and headers", %{bypass: bypass} do
Bypass.expect bypass, fn conn ->
conn = parse_body(conn)
assert co... | 29.704762 | 105 | 0.572299 |
3322e3254732781f7546bf0ae2575237ddfae88b | 1,297 | ex | Elixir | web/router.ex | mule/phoenix-elm-auth | 6b7b3019c53673bf3b4b2b41fa3eec8f75d08947 | [
"MIT"
] | 1 | 2016-07-06T02:06:31.000Z | 2016-07-06T02:06:31.000Z | web/router.ex | mule/phoenix-elm-auth | 6b7b3019c53673bf3b4b2b41fa3eec8f75d08947 | [
"MIT"
] | 1 | 2017-04-07T12:58:38.000Z | 2017-04-07T12:58:38.000Z | web/router.ex | mule/phoenix-elm-auth | 6b7b3019c53673bf3b4b2b41fa3eec8f75d08947 | [
"MIT"
] | null | null | null | defmodule PhoenixAuthKata.Router do
use PhoenixAuthKata.Web, :router
pipeline :browser do
plug :accepts, ["html"]
plug :fetch_session
plug :fetch_flash
plug :protect_from_forgery
plug :put_secure_browser_headers
plug PhoenixAuthKata.Auth, repo: PhoenixAuthKata.Repo
end... | 26.469388 | 82 | 0.651503 |
3322ed7f54eaf3c72c7cbbe5ea0471000abbb3ca | 1,622 | exs | Elixir | test/elixir/test/partition_helpers.exs | mtenrero/couchdb-vetcontrol | b7ede3ededdf0072c73f08d8f1217cb723b03f7a | [
"Apache-2.0"
] | 1 | 2020-09-11T19:23:27.000Z | 2020-09-11T19:23:27.000Z | test/elixir/test/partition_helpers.exs | mtenrero/couchdb-vetcontrol | b7ede3ededdf0072c73f08d8f1217cb723b03f7a | [
"Apache-2.0"
] | null | null | null | test/elixir/test/partition_helpers.exs | mtenrero/couchdb-vetcontrol | b7ede3ededdf0072c73f08d8f1217cb723b03f7a | [
"Apache-2.0"
] | null | null | null | defmodule PartitionHelpers do
use ExUnit.Case
def create_partition_docs(db_name, pk1 \\ "foo", pk2 \\ "bar") do
docs =
for i <- 1..100 do
id =
if rem(i, 2) == 0 do
"#{pk1}:#{i}"
else
"#{pk2}:#{i}"
end
group =
if rem(i, 3) ==... | 21.064935 | 80 | 0.48397 |
3322edbbb0148d1b9dd490382783954513ef6061 | 5,515 | ex | Elixir | test/support/test_fixture_helpers.ex | sladyn98/papercups | 3b17ccc4c974ac6e16c9962a576e64a832dafdb9 | [
"MIT"
] | null | null | null | test/support/test_fixture_helpers.ex | sladyn98/papercups | 3b17ccc4c974ac6e16c9962a576e64a832dafdb9 | [
"MIT"
] | null | null | null | test/support/test_fixture_helpers.ex | sladyn98/papercups | 3b17ccc4c974ac6e16c9962a576e64a832dafdb9 | [
"MIT"
] | null | null | null | defmodule ChatApi.TestFixtureHelpers do
@moduledoc false
alias ChatApi.{
Repo,
Accounts,
BrowserSessions,
BrowserReplayEvents,
Customers,
Conversations,
SlackConversationThreads,
EventSubscriptions,
Messages,
SlackAuthorizations,
Tags,
WidgetSettings,
Users,
U... | 25.892019 | 81 | 0.609429 |
3323305b4470fce1cce170e2140b18995fb9a7ae | 93 | exs | Elixir | test/conduit/encoding/gzip_test.exs | log4b/conduit | 5ecf5aa0edd831f54c28d596f1cb2d414fc99c6e | [
"MIT"
] | 119 | 2016-11-21T13:19:22.000Z | 2021-11-07T17:29:05.000Z | test/conduit/encoding/gzip_test.exs | log4b/conduit | 5ecf5aa0edd831f54c28d596f1cb2d414fc99c6e | [
"MIT"
] | 104 | 2018-02-02T20:42:46.000Z | 2021-08-03T05:36:09.000Z | test/conduit/encoding/gzip_test.exs | log4b/conduit | 5ecf5aa0edd831f54c28d596f1cb2d414fc99c6e | [
"MIT"
] | 21 | 2018-08-03T02:38:21.000Z | 2022-03-16T18:26:58.000Z | defmodule Conduit.Encoding.GZipTest do
use ExUnit.Case
doctest Conduit.Encoding.GZip
end
| 18.6 | 38 | 0.817204 |
33233ac15a8e2d580156ff45c5a347d5a54a57dd | 724 | ex | Elixir | lib/rumbl/repo.ex | brunorafa/rumbl | 910e6ecfaae8da8e54da9e67871a02885c2f383f | [
"MIT"
] | null | null | null | lib/rumbl/repo.ex | brunorafa/rumbl | 910e6ecfaae8da8e54da9e67871a02885c2f383f | [
"MIT"
] | null | null | null | lib/rumbl/repo.ex | brunorafa/rumbl | 910e6ecfaae8da8e54da9e67871a02885c2f383f | [
"MIT"
] | null | null | null | defmodule Rumbl.Repo do
# use Ecto.Repo,
# otp_app: :rumbl,
# adapter: Ecto.Adapters.Postgres
@moduledoc """
In memory repository.
"""
def all(Rumbl.User) do
[
%Rumbl.User{id: "1", name: "José", username: "josevalim", password: "elixir"},
%Rumbl.User{id: "2", name: "Chris", username: ... | 24.965517 | 84 | 0.592541 |
33233ac76bb1a1e6663677a2bd80879c76fe328c | 561 | exs | Elixir | services/interop-proxy/test/interop_proxy_web/controllers/controller_helpers_test.exs | RemusW/orchestra | 688c0d2a25d8f73c9c5a6e27d4fe4b2460c2c198 | [
"MIT"
] | 1 | 2020-10-08T14:37:36.000Z | 2020-10-08T14:37:36.000Z | services/interop-proxy/test/interop_proxy_web/controllers/controller_helpers_test.exs | RemusW/orchestra | 688c0d2a25d8f73c9c5a6e27d4fe4b2460c2c198 | [
"MIT"
] | 33 | 2017-10-31T22:36:42.000Z | 2021-01-10T22:15:54.000Z | services/interop-proxy/test/interop_proxy_web/controllers/controller_helpers_test.exs | RemusW/orchestra | 688c0d2a25d8f73c9c5a6e27d4fe4b2460c2c198 | [
"MIT"
] | 3 | 2018-10-07T21:36:02.000Z | 2020-02-07T01:13:53.000Z | defmodule InteropProxyWeb.ControllerHelpersTest do
use ExUnit.Case, async: true
alias InteropProxyWeb.ControllerHelpers
test "is_truthy() returns true and false when expected" do
assert ControllerHelpers.is_truthy("1")
assert ControllerHelpers.is_truthy("true")
assert ControllerHelpers.is_truthy("Tr... | 31.166667 | 60 | 0.782531 |
332351cc362fd0de44afdba0fbbe226ce7a7ee6c | 351 | ex | Elixir | lib/ja_serializer/formatter/relationship.ex | strzibny/ja_serializer | 9823ada739ec1f0db9f14bd29f62a701dbd3b094 | [
"Apache-2.0"
] | 322 | 2016-11-18T22:58:17.000Z | 2022-01-18T15:07:24.000Z | lib/ja_serializer/formatter/relationship.ex | strzibny/ja_serializer | 9823ada739ec1f0db9f14bd29f62a701dbd3b094 | [
"Apache-2.0"
] | 150 | 2016-11-17T20:14:51.000Z | 2021-03-12T03:56:57.000Z | lib/ja_serializer/formatter/relationship.ex | strzibny/ja_serializer | 9823ada739ec1f0db9f14bd29f62a701dbd3b094 | [
"Apache-2.0"
] | 104 | 2016-11-17T18:02:36.000Z | 2021-04-06T09:52:16.000Z | defimpl JaSerializer.Formatter, for: JaSerializer.Builder.Relationship do
alias JaSerializer.Formatter.Utils
def format(rel) do
json =
%{}
|> Utils.add_data_if_present(JaSerializer.Formatter.format(rel.data))
|> Utils.put_if_present("links", Utils.array_to_hash(rel.links))
{Utils.format_... | 27 | 75 | 0.720798 |
33236542b72627c3e1cb9559e20602e8baa0680b | 5,462 | exs | Elixir | test/credo/config_file_test.exs | sevenseacat/credo | 48837401040d9c2340b5fb9c7d786d31f89f6426 | [
"MIT"
] | null | null | null | test/credo/config_file_test.exs | sevenseacat/credo | 48837401040d9c2340b5fb9c7d786d31f89f6426 | [
"MIT"
] | null | null | null | test/credo/config_file_test.exs | sevenseacat/credo | 48837401040d9c2340b5fb9c7d786d31f89f6426 | [
"MIT"
] | null | null | null | defmodule Credo.ConfigFileTest do
use ExUnit.Case
alias Credo.ConfigFile
def assert_sorted_equality(%ConfigFile{files: files1, checks: checks1},
%ConfigFile{files: files2, checks: checks2}) do
assert files1 == files2
assert_sorted_equality checks1, checks2
end
def asser... | 35.699346 | 107 | 0.482424 |
332369a6da3caddbd029a9b76dec1266b7f03f68 | 1,206 | ex | Elixir | lib/codes/codes_x52.ex | badubizzle/icd_code | 4c625733f92b7b1d616e272abc3009bb8b916c0c | [
"Apache-2.0"
] | null | null | null | lib/codes/codes_x52.ex | badubizzle/icd_code | 4c625733f92b7b1d616e272abc3009bb8b916c0c | [
"Apache-2.0"
] | null | null | null | lib/codes/codes_x52.ex | badubizzle/icd_code | 4c625733f92b7b1d616e272abc3009bb8b916c0c | [
"Apache-2.0"
] | null | null | null | defmodule IcdCode.ICDCode.Codes_X52 do
alias IcdCode.ICDCode
def _X52XXXA do
%ICDCode{full_code: "X52XXXA",
category_code: "X52",
short_code: "XXXA",
full_name: "Prolonged stay in weightless environment, initial encounter",
short_name: "Prolonged stay in weightless environ... | 35.470588 | 89 | 0.670813 |
332389ce912039ceb1a3b4def34635c241434981 | 539 | ex | Elixir | lib/geonames/endpoints/find_nearby_wikipedia.ex | vheathen/geonames-elixir | b47ef0e38462c3bdbfb1a5b710f53993d9d3056d | [
"MIT"
] | null | null | null | lib/geonames/endpoints/find_nearby_wikipedia.ex | vheathen/geonames-elixir | b47ef0e38462c3bdbfb1a5b710f53993d9d3056d | [
"MIT"
] | null | null | null | lib/geonames/endpoints/find_nearby_wikipedia.ex | vheathen/geonames-elixir | b47ef0e38462c3bdbfb1a5b710f53993d9d3056d | [
"MIT"
] | null | null | null | defmodule Geonames.Endpoints.FindNearbyWikipedia do
@moduledoc false
@behaviour Geonames.Endpoint
@default_arguments %{
lat: nil,
lng: nil,
radius: nil,
postalcode: nil,
country: nil,
maxRows: nil
}
def endpoint, do: "findNearbyWikipediaJSON"
def available_url_parameters, do: Map.k... | 22.458333 | 64 | 0.738404 |
3323b5f9b582ed6a46013526ae1166d111246540 | 425 | ex | Elixir | src/dguweb/web/models/theme.ex | datagovuk/dgu2 | 3e24bdf27b30c22791efc19029ead05488c8f571 | [
"MIT"
] | 2 | 2016-08-09T16:46:52.000Z | 2016-08-09T16:46:59.000Z | src/dguweb/web/models/theme.ex | datagovuk/dgu2 | 3e24bdf27b30c22791efc19029ead05488c8f571 | [
"MIT"
] | 48 | 2016-07-14T15:12:41.000Z | 2016-09-27T16:19:54.000Z | src/dguweb/web/models/theme.ex | datagovuk/dgu2 | 3e24bdf27b30c22791efc19029ead05488c8f571 | [
"MIT"
] | 1 | 2021-04-10T21:23:44.000Z | 2021-04-10T21:23:44.000Z | defmodule DGUWeb.Theme do
use DGUWeb.Web, :model
schema "themes" do
field :name, :string
field :title, :string
field :description, :string
timestamps()
end
@doc """
Builds a changeset based on the `struct` and `params`.
"""
def changeset(struct, params \\ %{}) do
struct
|> cast(... | 20.238095 | 56 | 0.630588 |
3323c4261e71835ad155e3160bcdcbaf9262a843 | 4,640 | ex | Elixir | lib/sendgrid.ex | churcho/sendgrid_elixir | 1bb421d044e21e51bd761f14dfb61b9e431f2eb7 | [
"MIT"
] | null | null | null | lib/sendgrid.ex | churcho/sendgrid_elixir | 1bb421d044e21e51bd761f14dfb61b9e431f2eb7 | [
"MIT"
] | null | null | null | lib/sendgrid.ex | churcho/sendgrid_elixir | 1bb421d044e21e51bd761f14dfb61b9e431f2eb7 | [
"MIT"
] | null | null | null | defmodule SendGrid do
@moduledoc """
Interface to SendGrid's API.
## Configuration
An API key can be set in your application's config.
# Compile-time configured key.
config :sendgrid,
api_key: "sendgrid_api_key"
# Run-time configured key
config :sendgrid,
api_key: {:s... | 26.214689 | 97 | 0.613793 |
3323cc34d1f07c996ee6262c086d9721e94a0478 | 4,126 | exs | Elixir | mix.exs | mnishiguchi/vintage_net | b2c9848c15d1e72f142981e00186b314d47647d7 | [
"Apache-2.0"
] | null | null | null | mix.exs | mnishiguchi/vintage_net | b2c9848c15d1e72f142981e00186b314d47647d7 | [
"Apache-2.0"
] | null | null | null | mix.exs | mnishiguchi/vintage_net | b2c9848c15d1e72f142981e00186b314d47647d7 | [
"Apache-2.0"
] | null | null | null | defmodule VintageNet.MixProject do
use Mix.Project
@version "0.10.3"
@source_url "https://github.com/nerves-networking/vintage_net"
def project do
[
app: :vintage_net,
version: @version,
elixir: "~> 1.9",
elixirc_paths: elixirc_paths(Mix.env()),
test_coverage: [tool: ExCovera... | 27.878378 | 85 | 0.557683 |
3323e03f04faab92ed1e55a3e5f7f2db0895cf6d | 444 | exs | Elixir | test/pummpcomm/history/alarm_pump_test.exs | infinity-aps/pummpcomm | 7380585ecd110ab1c19d2aea3880e51e3f433050 | [
"MIT"
] | 15 | 2017-08-31T00:58:47.000Z | 2020-01-12T03:53:13.000Z | test/pummpcomm/history/alarm_pump_test.exs | vladhj38/pummpcomm | 7380585ecd110ab1c19d2aea3880e51e3f433050 | [
"MIT"
] | 1 | 2017-09-15T02:09:31.000Z | 2017-09-15T02:09:31.000Z | test/pummpcomm/history/alarm_pump_test.exs | vladhj38/pummpcomm | 7380585ecd110ab1c19d2aea3880e51e3f433050 | [
"MIT"
] | 3 | 2017-09-10T17:24:59.000Z | 2019-09-10T19:41:49.000Z | defmodule Pummpcomm.History.AlarmPumpTest do
use ExUnit.Case
test "Alarm Pump" do
{:ok, history_page} = Base.decode16("063D0779730F2CE50F")
decoded_events = Pummpcomm.History.decode_records(history_page, %{})
assert {:alarm_pump,
%{
alarm_type: :reprogram_error,
... | 27.75 | 72 | 0.619369 |
3323f15a126f8f1b782b01e4c4813a7734d53a3e | 104 | exs | Elixir | test/parser_test.exs | appcues/timex | 700643279531bbf1711cd721b3851f025cc28a95 | [
"MIT"
] | null | null | null | test/parser_test.exs | appcues/timex | 700643279531bbf1711cd721b3851f025cc28a95 | [
"MIT"
] | null | null | null | test/parser_test.exs | appcues/timex | 700643279531bbf1711cd721b3851f025cc28a95 | [
"MIT"
] | null | null | null | defmodule Timex.Parser.Test do
use ExUnit.Case, async: true
doctest Timex.Parse.DateTime.Parser
end
| 20.8 | 37 | 0.788462 |
3323fb377e5d7552fd2d59b4b337ab8ece7819e9 | 4,433 | ex | Elixir | lib/goldie/utils.ex | scatterbrain/goldie | db649f9555d453541d01d0707d86b41f41156640 | [
"MIT"
] | null | null | null | lib/goldie/utils.ex | scatterbrain/goldie | db649f9555d453541d01d0707d86b41f41156640 | [
"MIT"
] | null | null | null | lib/goldie/utils.ex | scatterbrain/goldie | db649f9555d453541d01d0707d86b41f41156640 | [
"MIT"
] | null | null | null | defmodule Goldie.Utils do
@moduledoc """
Misc utils
"""
@doc """
min of two numbers
"""
@spec min(number, number) :: number()
def min(x, y) when x < y, do: x
def min(_x, y), do: y
@doc """
max of two numbers
"""
@spec max(number, number) :: number()
def max(x, y) when x > y, do: x
def ma... | 25.624277 | 119 | 0.609068 |
3324097359c70869a829fa5341520ffcc14a46ce | 2,102 | ex | Elixir | clients/notebooks/lib/google_api/notebooks/v1/model/list_instances_response.ex | renovate-bot/elixir-google-api | 1da34cd39b670c99f067011e05ab90af93fef1f6 | [
"Apache-2.0"
] | 1 | 2021-12-20T03:40:53.000Z | 2021-12-20T03:40:53.000Z | clients/notebooks/lib/google_api/notebooks/v1/model/list_instances_response.ex | swansoffiee/elixir-google-api | 9ea6d39f273fb430634788c258b3189d3613dde0 | [
"Apache-2.0"
] | 1 | 2020-08-18T00:11:23.000Z | 2020-08-18T00:44:16.000Z | clients/notebooks/lib/google_api/notebooks/v1/model/list_instances_response.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... | 39.660377 | 225 | 0.726451 |
332438fb9fe8d1098e8cdca925017d46624e7ea2 | 3,010 | ex | Elixir | clients/apigee/lib/google_api/apigee/v1/model/google_iam_v1_audit_config.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2021-12-20T03:40:53.000Z | 2021-12-20T03:40:53.000Z | clients/apigee/lib/google_api/apigee/v1/model/google_iam_v1_audit_config.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2020-08-18T00:11:23.000Z | 2020-08-18T00:44:16.000Z | clients/apigee/lib/google_api/apigee/v1/model/google_iam_v1_audit_config.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | null | null | null | # Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, s... | 60.2 | 1,106 | 0.749834 |
33243f8f712dafc7b26ee6ea1dd2ffbe049feac1 | 1,510 | exs | Elixir | test/delayed_handler_test.exs | idabmat/httparrot | 1bc15bf4c7330341b36f7dc7d933285cda7bbf67 | [
"MIT"
] | null | null | null | test/delayed_handler_test.exs | idabmat/httparrot | 1bc15bf4c7330341b36f7dc7d933285cda7bbf67 | [
"MIT"
] | null | null | null | test/delayed_handler_test.exs | idabmat/httparrot | 1bc15bf4c7330341b36f7dc7d933285cda7bbf67 | [
"MIT"
] | null | null | null | defmodule HTTParrot.DelayedHandlerTest do
use ExUnit.Case
import :meck
import HTTParrot.DelayedHandler
setup do
new HTTParrot.GeneralRequestInfo
new JSX
new :cowboy_req
on_exit fn -> unload() end
:ok
end
test "malformed_request returns false if it's not an integer" do
expect(:cowbo... | 26.964286 | 70 | 0.659603 |
3324486c780677495e286cad4ad153594459ae02 | 423 | ex | Elixir | lib/stabby_flies/utils/socket_id_gen.ex | ramortegui/stabby-flies | f1d0bd61a2b9f3aed33231bbdcec19b011534536 | [
"MIT"
] | null | null | null | lib/stabby_flies/utils/socket_id_gen.ex | ramortegui/stabby-flies | f1d0bd61a2b9f3aed33231bbdcec19b011534536 | [
"MIT"
] | null | null | null | lib/stabby_flies/utils/socket_id_gen.ex | ramortegui/stabby-flies | f1d0bd61a2b9f3aed33231bbdcec19b011534536 | [
"MIT"
] | null | null | null | defmodule StabbyFlies.SocketIdGen do
require Logger
def start_link do
# Agent.stop(__MODULE__)
Agent.start_link(fn -> %{ "id": 0 } end, name: __MODULE__)
end
def gen_id do
x = Enum.random(0..200)
id = get_id + 1
Agent.update(__MODULE__, fn(state) ->
Map.put(state, :id, id)
end)
... | 17.625 | 62 | 0.609929 |
33244c9ed1bde3f6a94b5ea70f47b08e3ccc72c5 | 646 | ex | Elixir | openapi-client/elixir/lib/mail_baby_api/model/mail_order.ex | interserver/mailbaby-api-samples | 0879348474e22463e77dc76ba5e5f7e6300a2b6c | [
"MIT"
] | null | null | null | openapi-client/elixir/lib/mail_baby_api/model/mail_order.ex | interserver/mailbaby-api-samples | 0879348474e22463e77dc76ba5e5f7e6300a2b6c | [
"MIT"
] | 185 | 2022-01-01T23:30:37.000Z | 2022-03-25T01:08:22.000Z | openapi-client/elixir/lib/mail_baby_api/model/mail_order.ex | interserver/mailbaby-api-samples | 0879348474e22463e77dc76ba5e5f7e6300a2b6c | [
"MIT"
] | null | null | null | # NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
# https://openapi-generator.tech
# Do not edit the class manually.
defmodule MailBabyAPI.Model.MailOrder do
@moduledoc """
"""
@derive [Poison.Encoder]
defstruct [
:"id",
:"status",
:"username",
:"pa... | 19 | 91 | 0.619195 |
332454eb5074e376561f44bfa86d0d760cb58efb | 1,451 | ex | Elixir | lib/chat/application.ex | okuramasafumi/elixir-chat-sample | 0bbbda9d86bfbe74399d4ed465d5f0c853c2d5a1 | [
"MIT"
] | null | null | null | lib/chat/application.ex | okuramasafumi/elixir-chat-sample | 0bbbda9d86bfbe74399d4ed465d5f0c853c2d5a1 | [
"MIT"
] | null | null | null | lib/chat/application.ex | okuramasafumi/elixir-chat-sample | 0bbbda9d86bfbe74399d4ed465d5f0c853c2d5a1 | [
"MIT"
] | null | null | null | defmodule Chat.Application do
# See http://elixir-lang.org/docs/stable/elixir/Application.html
# for more information on OTP Applications
@moduledoc false
use Application
def start(_type, _args) do
import Supervisor.Spec, warn: false
# Define workers and child supervisors to be supervised
child... | 31.543478 | 76 | 0.666437 |
33245a44819d7e155eaf4298bd595c3df5100060 | 6,708 | ex | Elixir | lib/mix/tasks/phx.gen.json.ex | zorn/phoenix | ac88958550fbd861e2f1e1af6e3c6b787b1a202e | [
"MIT"
] | 1 | 2019-04-24T09:28:15.000Z | 2019-04-24T09:28:15.000Z | lib/mix/tasks/phx.gen.json.ex | zorn/phoenix | ac88958550fbd861e2f1e1af6e3c6b787b1a202e | [
"MIT"
] | 1 | 2020-07-17T10:07:44.000Z | 2020-07-17T10:07:44.000Z | lib/mix/tasks/phx.gen.json.ex | zorn/phoenix | ac88958550fbd861e2f1e1af6e3c6b787b1a202e | [
"MIT"
] | null | null | null | defmodule Mix.Tasks.Phx.Gen.Json do
@shortdoc "Generates controller, views, and context for a JSON resource"
@moduledoc """
Generates controller, views, and context for a JSON resource.
mix phx.gen.json Accounts User users name:string age:integer
The first argument is the context module followed by the... | 36.655738 | 136 | 0.715862 |
3324732b6d6e4e5921bee0094e4e1515b4aebe4f | 10,668 | ex | Elixir | lib/game/command/skills.ex | stevegrossi/ex_venture | e02d5a63fdb882d92cfb4af3e15f7b48ad7054aa | [
"MIT"
] | null | null | null | lib/game/command/skills.ex | stevegrossi/ex_venture | e02d5a63fdb882d92cfb4af3e15f7b48ad7054aa | [
"MIT"
] | null | null | null | lib/game/command/skills.ex | stevegrossi/ex_venture | e02d5a63fdb882d92cfb4af3e15f7b48ad7054aa | [
"MIT"
] | null | null | null | defmodule Game.Command.Skills do
@moduledoc """
Parse out class skills
"""
use Game.Command
alias Game.Character
alias Game.Command
alias Game.Command.Target
alias Game.Effect
alias Game.Experience
alias Game.Format.Skills, as: FormatSkills
alias Game.Hint
alias Game.Item
alias Game.Session.... | 26.603491 | 121 | 0.6018 |
3324844157e89a88b8b37b01c72753f6ec7ec8a3 | 612 | ex | Elixir | lib/builder/builder.ex | overdb/over_db | 0bc52de49ee684b4d63607e960d522663e17ed6a | [
"Apache-2.0"
] | 7 | 2019-04-13T01:11:18.000Z | 2020-08-11T08:11:03.000Z | lib/builder/builder.ex | overdb/over_db | 0bc52de49ee684b4d63607e960d522663e17ed6a | [
"Apache-2.0"
] | null | null | null | lib/builder/builder.ex | overdb/over_db | 0bc52de49ee684b4d63607e960d522663e17ed6a | [
"Apache-2.0"
] | null | null | null | defmodule OverDB.Builder do
def build(type, modules, value) do
quote do
Map.put(OverDB.Builder.query_map(unquote(modules)), unquote(type), unquote(value))
end
end
def query_map(modules) do
case modules do
{keyspace, table} -> %{
target: "#{keyspace.__struct__.name}.#{table.__stru... | 23.538462 | 88 | 0.594771 |
3324a2bdf50ecc814cba5dd432ad5942a3810d0b | 51,285 | ex | Elixir | lib/phoenix/controller.ex | MarkHoo/phoenix | 3f673093826b0d4db5656dfe6e34393901348ed1 | [
"MIT"
] | null | null | null | lib/phoenix/controller.ex | MarkHoo/phoenix | 3f673093826b0d4db5656dfe6e34393901348ed1 | [
"MIT"
] | null | null | null | lib/phoenix/controller.ex | MarkHoo/phoenix | 3f673093826b0d4db5656dfe6e34393901348ed1 | [
"MIT"
] | null | null | null | defmodule Phoenix.Controller do
import Plug.Conn
alias Plug.Conn.AlreadySentError
require Logger
require Phoenix.Endpoint
@unsent [:unset, :set, :set_chunked, :set_file]
@moduledoc """
Controllers are used to group common functionality in the same
(pluggable) module.
For example, the route:
... | 32.234444 | 137 | 0.676514 |
3324c2e3350c0b5cb53f989bb54dd8dc0a492639 | 1,510 | exs | Elixir | test/apns/config_test.exs | c0deaddict/pigeon | 842c7632a0318a153b933e727c1ebc3c029ace5c | [
"MIT"
] | null | null | null | test/apns/config_test.exs | c0deaddict/pigeon | 842c7632a0318a153b933e727c1ebc3c029ace5c | [
"MIT"
] | null | null | null | test/apns/config_test.exs | c0deaddict/pigeon | 842c7632a0318a153b933e727c1ebc3c029ace5c | [
"MIT"
] | null | null | null | defmodule Pigeon.APNS.ConfigTest do
use ExUnit.Case
doctest Pigeon.APNS.Config, import: true
@invalid_cert_msg ~r/^attempted to start without valid certificate/
@invalid_key_msg ~r/^attempted to start without valid key/
test "raises if configured with invalid cert raw text" do
assert_raise(Pigeon.Config... | 26.964286 | 69 | 0.64106 |
3324f58cd083512eeabf102085a14ae91a2077b6 | 116 | ex | Elixir | web/views/chat_view.ex | helapu/gd_push | 4bfe17194a898232fe8e8a4d54d4f90934ba4125 | [
"MIT"
] | null | null | null | web/views/chat_view.ex | helapu/gd_push | 4bfe17194a898232fe8e8a4d54d4f90934ba4125 | [
"MIT"
] | null | null | null | web/views/chat_view.ex | helapu/gd_push | 4bfe17194a898232fe8e8a4d54d4f90934ba4125 | [
"MIT"
] | null | null | null | defmodule GdPush.ChatView do
use GdPush.Web, :view
# 定义一个方法在template里面使用
def home do
"boom"
end
end
| 11.6 | 28 | 0.681034 |
3325510626b9ce1f6c515487a26079c868ba4965 | 76 | ex | Elixir | lib/planning_poker_web/views/layout_view.ex | Invaern/planning-poker | e7a53bdc0e5b01aaf4574cb7190529021517ba55 | [
"MIT"
] | null | null | null | lib/planning_poker_web/views/layout_view.ex | Invaern/planning-poker | e7a53bdc0e5b01aaf4574cb7190529021517ba55 | [
"MIT"
] | null | null | null | lib/planning_poker_web/views/layout_view.ex | Invaern/planning-poker | e7a53bdc0e5b01aaf4574cb7190529021517ba55 | [
"MIT"
] | null | null | null | defmodule PlanningPokerWeb.LayoutView do
use PlanningPokerWeb, :view
end
| 15.2 | 40 | 0.828947 |
332574e00bb216a917dda50fc4cbc429b6c44f84 | 3,179 | exs | Elixir | test/ex_doc/formatter/epub/templates_test.exs | ScrimpyCat/ex_doc | deabff56abc0c4f4890caebfd4a66630be032146 | [
"Apache-2.0",
"CC-BY-4.0"
] | null | null | null | test/ex_doc/formatter/epub/templates_test.exs | ScrimpyCat/ex_doc | deabff56abc0c4f4890caebfd4a66630be032146 | [
"Apache-2.0",
"CC-BY-4.0"
] | null | null | null | test/ex_doc/formatter/epub/templates_test.exs | ScrimpyCat/ex_doc | deabff56abc0c4f4890caebfd4a66630be032146 | [
"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 do
%ExDoc.Config{
... | 33.114583 | 100 | 0.681032 |
332584460c18b89aa586d67bd772c307f55648f1 | 1,916 | ex | Elixir | lib/mix/tasks/commanded.reset.ex | jwilger/commanded | 2d9950fd3ce76a23a3c410c99857b812f5705d66 | [
"MIT"
] | 9 | 2018-08-07T11:54:33.000Z | 2022-03-11T09:48:45.000Z | lib/mix/tasks/commanded.reset.ex | jwilger/commanded | 2d9950fd3ce76a23a3c410c99857b812f5705d66 | [
"MIT"
] | 91 | 2019-11-11T15:41:26.000Z | 2022-03-21T04:17:18.000Z | lib/mix/tasks/commanded.reset.ex | jwilger/commanded | 2d9950fd3ce76a23a3c410c99857b812f5705d66 | [
"MIT"
] | 3 | 2019-11-13T12:44:41.000Z | 2022-01-06T19:34:26.000Z | defmodule Mix.Tasks.Commanded.Reset do
@moduledoc """
Reset an event handler.
## Usage
mix commanded.reset --app <app> --handler <handler>
## Examples
mix commanded.reset --app MyApp --handler MyHandler
mix commanded.reset -a MyApp -h MyHandler
## Command line options
* `-a`, `--ap... | 22.809524 | 106 | 0.604384 |
3325c6e2a46e004163926125b662acc92168c992 | 4,736 | ex | Elixir | lib/runtime_provider/definition.ex | smartepsh/runtime-provider | 162efa60b720579c6483d07ae045bf0ada98f175 | [
"MIT"
] | null | null | null | lib/runtime_provider/definition.ex | smartepsh/runtime-provider | 162efa60b720579c6483d07ae045bf0ada98f175 | [
"MIT"
] | null | null | null | lib/runtime_provider/definition.ex | smartepsh/runtime-provider | 162efa60b720579c6483d07ae045bf0ada98f175 | [
"MIT"
] | null | null | null | defmodule RuntimeProvider.Definition do
@moduledoc """
DSLs for defines the configuration with ConfigProvider.
"""
alias RuntimeProvider.Expr
defstruct app: nil,
key: nil,
required?: false,
strategy: :all,
value: nil,
fallback: nil,
appe... | 29.974684 | 213 | 0.623311 |
332612755b71b6dad29395cd572af8c0237b1d26 | 17,558 | ex | Elixir | lib/coherence/schema.ex | h1u2i3/coherence | 8a77d62c6d2d39fe9cb2059eac09bd300126590b | [
"MIT"
] | 1 | 2019-03-28T23:27:08.000Z | 2019-03-28T23:27:08.000Z | lib/coherence/schema.ex | h1u2i3/coherence | 8a77d62c6d2d39fe9cb2059eac09bd300126590b | [
"MIT"
] | null | null | null | lib/coherence/schema.ex | h1u2i3/coherence | 8a77d62c6d2d39fe9cb2059eac09bd300126590b | [
"MIT"
] | 1 | 2019-03-21T12:46:55.000Z | 2019-03-21T12:46:55.000Z | defmodule Coherence.Schema do
@moduledoc """
Add Coherence support to a User schema module.
Add `use Coherence.Schema, opts \\ []` to your User module to add a number of
Module functions and helpers.
The optional `opt` parameter can be used to disable options enabled in the
global configuration by passing... | 31.865699 | 140 | 0.643069 |
33262595ee2b00621c2e76d1f7a79be6cfdeb5d7 | 5,653 | ex | Elixir | lib/teiserver/coordinator/consul_voting.ex | Born2Crawl/teiserver | b89601aea1a338cd41b4eabc4092207cb50110f0 | [
"MIT"
] | null | null | null | lib/teiserver/coordinator/consul_voting.ex | Born2Crawl/teiserver | b89601aea1a338cd41b4eabc4092207cb50110f0 | [
"MIT"
] | null | null | null | lib/teiserver/coordinator/consul_voting.ex | Born2Crawl/teiserver | b89601aea1a338cd41b4eabc4092207cb50110f0 | [
"MIT"
] | null | null | null | defmodule Teiserver.Coordinator.ConsulVoting do
require Logger
alias Teiserver.Coordinator.{ConsulServer, ConsulCommands}
alias Teiserver.{Coordinator, Client, User}
alias Teiserver.Account.UserCache
alias Teiserver.Battle.Lobby
import Central.Helpers.NumberHelper, only: [int_parse: 1]
# alias Phoenix.Pub... | 32.676301 | 141 | 0.645498 |
33262b30fe5b4e9d90411e4d6a6d6427ceef18f7 | 1,622 | exs | Elixir | test/credo/check/refactor/append_single_item_test.exs | hrzndhrn/credo | 71a7b24a5ca8e7a48416e0cdfb42cf8a0fef9593 | [
"MIT"
] | 4,590 | 2015-09-28T06:01:43.000Z | 2022-03-29T08:48:57.000Z | test/credo/check/refactor/append_single_item_test.exs | hrzndhrn/credo | 71a7b24a5ca8e7a48416e0cdfb42cf8a0fef9593 | [
"MIT"
] | 890 | 2015-11-16T21:07:07.000Z | 2022-03-29T08:52:07.000Z | test/credo/check/refactor/append_single_item_test.exs | hrzndhrn/credo | 71a7b24a5ca8e7a48416e0cdfb42cf8a0fef9593 | [
"MIT"
] | 479 | 2015-11-17T19:42:40.000Z | 2022-03-29T00:09:21.000Z | defmodule Credo.Check.Refactor.AppendSingleItemTest do
use Credo.Test.Case
@described_check Credo.Check.Refactor.AppendSingleItem
test "it should NOT report appending 2 items" do
"""
defmodule CredoSampleModule do
def some_function(parameter1, parameter2) do
[parameter1] ++ [parameter2]
... | 22.84507 | 73 | 0.646116 |
332630920a9f98d5a224b318ab29db89fd6eed1f | 683 | ex | Elixir | lib/xlsx_reader/sheet.ex | Q1-Energie-AG/xlsx_reader | 02b49b6f85b693dfd445c714c01c0454409e621e | [
"Apache-2.0"
] | 40 | 2019-12-20T16:11:47.000Z | 2022-02-08T22:59:53.000Z | lib/xlsx_reader/sheet.ex | Q1-Energie-AG/xlsx_reader | 02b49b6f85b693dfd445c714c01c0454409e621e | [
"Apache-2.0"
] | 4 | 2020-05-17T11:35:33.000Z | 2022-02-08T21:29:46.000Z | lib/xlsx_reader/sheet.ex | Q1-Energie-AG/xlsx_reader | 02b49b6f85b693dfd445c714c01c0454409e621e | [
"Apache-2.0"
] | 6 | 2020-04-24T16:31:06.000Z | 2022-03-22T07:51:51.000Z | defmodule XlsxReader.Sheet do
@moduledoc """
Worksheet structure.
This structure only contains the information useful to identify and retrieve the sheet actual data.
- `name` - name of the sheet
- `rid` - relationship ID used to retrieve the corresponding sheet in the archive
- `sheet_id` - unique identi... | 25.296296 | 101 | 0.666179 |
332632e8a6d589c5cb0df6d8a39eca6e4ac2d562 | 843 | ex | Elixir | test/helpers/event_factory.ex | ThisisGurwinder/commanded | ad7784ce3125022e188ea795771710c4e5e38e71 | [
"MIT"
] | null | null | null | test/helpers/event_factory.ex | ThisisGurwinder/commanded | ad7784ce3125022e188ea795771710c4e5e38e71 | [
"MIT"
] | null | null | null | test/helpers/event_factory.ex | ThisisGurwinder/commanded | ad7784ce3125022e188ea795771710c4e5e38e71 | [
"MIT"
] | null | null | null | defmodule Commanded.Helpers.EventFactory do
@moduledoc false
alias Commanded.EventStore.RecordedEvent
def map_to_recorded_events(events) do
stream_id = UUID.uuid4()
causation_id = UUID.uuid4()
correlation_id = UUID.uuid4()
events
|> Commanded.Event.Mapper.map_to_event_data(causation_id, corr... | 27.193548 | 82 | 0.658363 |
332651f83980c0168bd0b9de7c156dec25338b5c | 1,020 | exs | Elixir | test/mix.exs | aaronrenner/nerves_system_rpi0_zbar | 8b4db176fb9ca67ff004a0b15a43defa52d1ed95 | [
"Apache-2.0"
] | null | null | null | test/mix.exs | aaronrenner/nerves_system_rpi0_zbar | 8b4db176fb9ca67ff004a0b15a43defa52d1ed95 | [
"Apache-2.0"
] | null | null | null | test/mix.exs | aaronrenner/nerves_system_rpi0_zbar | 8b4db176fb9ca67ff004a0b15a43defa52d1ed95 | [
"Apache-2.0"
] | null | null | null | if Mix.env == :test do
hash = :os.cmd('git rev-parse HEAD')
|> to_string
|> String.trim
System.put_env("NERVES_FW_VCS_IDENTIFIER", hash)
end
defmodule Test.Mixfile do
use Mix.Project
def project do
[app: :test,
version: "0.1.0",
elixir: "~> 1.4",
archives: [nerves_bootstrap: "~> 0.7... | 23.181818 | 79 | 0.617647 |
332652d190c2efbadf8663bd70d92fe4cbcad77f | 923 | ex | Elixir | test/factories/accounts/user_factory.ex | source-academy/cadet | c447552453f78799755de73f66999e4c9d20383c | [
"Apache-2.0"
] | 27 | 2018-01-20T05:56:24.000Z | 2021-05-24T03:21:55.000Z | test/factories/accounts/user_factory.ex | source-academy/cadet | c447552453f78799755de73f66999e4c9d20383c | [
"Apache-2.0"
] | 731 | 2018-04-16T13:25:49.000Z | 2021-06-22T07:16:12.000Z | test/factories/accounts/user_factory.ex | source-academy/cadet | c447552453f78799755de73f66999e4c9d20383c | [
"Apache-2.0"
] | 43 | 2018-01-20T06:35:46.000Z | 2021-05-05T03:22:35.000Z | defmodule Cadet.Accounts.UserFactory do
@moduledoc """
Factory(ies) for Cadet.Accounts.User entity
"""
defmacro __using__(_opts) do
quote do
# alias Cadet.Accounts.{Role, User}
alias Cadet.Accounts.User
def user_factory do
%User{
provider: "test",
name: Faker.... | 23.666667 | 76 | 0.510293 |
332684662d2fb9f5c32ce08a2206903d557cf435 | 788 | exs | Elixir | test/gmail/user_test.exs | philwade/elixir-gmail | 4c44fbc63b194dc4f6f02caec7c6ee6164a3a9a3 | [
"MIT"
] | 52 | 2015-02-19T23:23:34.000Z | 2020-07-12T12:53:09.000Z | test/gmail/user_test.exs | philwade/elixir-gmail | 4c44fbc63b194dc4f6f02caec7c6ee6164a3a9a3 | [
"MIT"
] | 17 | 2016-06-01T18:49:09.000Z | 2020-11-11T21:26:21.000Z | test/gmail/user_test.exs | philwade/elixir-gmail | 4c44fbc63b194dc4f6f02caec7c6ee6164a3a9a3 | [
"MIT"
] | 26 | 2016-03-08T09:13:58.000Z | 2021-09-27T08:39:22.000Z | ExUnit.start
defmodule Gmail.UserTest do
use ExUnit.Case
import Mock
setup do
user_id = "user12@example.com"
{:ok, %{
user_id: user_id
}}
end
test "stops a user process instance that has been started", %{user_id: user_id} do
with_mock Gmail.OAuth2, [refresh_access_token: fn(_) ->... | 27.172414 | 108 | 0.680203 |
33268e28eef32cb06323e8eaf17a520ee3b53fcb | 75 | ex | Elixir | elixir_phoenix/lib/elixir_phoenix_web/views/layout_view.ex | kaibyao/rust-postgres-rest-benchmarks | 0a32719c37de3cb783b5e597bef7381ccb4e20f1 | [
"MIT"
] | null | null | null | elixir_phoenix/lib/elixir_phoenix_web/views/layout_view.ex | kaibyao/rust-postgres-rest-benchmarks | 0a32719c37de3cb783b5e597bef7381ccb4e20f1 | [
"MIT"
] | null | null | null | elixir_phoenix/lib/elixir_phoenix_web/views/layout_view.ex | kaibyao/rust-postgres-rest-benchmarks | 0a32719c37de3cb783b5e597bef7381ccb4e20f1 | [
"MIT"
] | null | null | null | defmodule ElixirPhoenixWeb.LayoutView do
use ElixirPhoenixWeb, :view
end
| 18.75 | 40 | 0.84 |
332693af33b3d79a7f1ce9ea2e284cbe9ecfc061 | 352 | ex | Elixir | lib/mix/tasks/generate.ex | wrren/baiji_generator.ex | 7c36c0089d6b88576fa6e064e86c342f03729003 | [
"MIT"
] | null | null | null | lib/mix/tasks/generate.ex | wrren/baiji_generator.ex | 7c36c0089d6b88576fa6e064e86c342f03729003 | [
"MIT"
] | null | null | null | lib/mix/tasks/generate.ex | wrren/baiji_generator.ex | 7c36c0089d6b88576fa6e064e86c342f03729003 | [
"MIT"
] | null | null | null | defmodule Mix.Tasks.Generate do
use Mix.Task
alias Baiji.Generator
@shortdoc "Generate AWS service code"
def run([input, template, output]) do
%Generator{ spec_directory: input,
write_directory: output,
template_directory: template}
|> Generator.read_specs
|>... | 25.142857 | 45 | 0.661932 |
3326a68362be007bb175b8aff466876227f91a00 | 433 | ex | Elixir | web/ex_mon/lib/ex_mon/trainer/delete.ex | herminiotorres/curso_elixir | 19519a2ac27b7c3e4973cdb2053c32dd61647cb5 | [
"MIT"
] | 1 | 2021-08-08T22:50:44.000Z | 2021-08-08T22:50:44.000Z | web/ex_mon/lib/ex_mon/trainer/delete.ex | herminiotorres/curso-elixir | 19519a2ac27b7c3e4973cdb2053c32dd61647cb5 | [
"MIT"
] | null | null | null | web/ex_mon/lib/ex_mon/trainer/delete.ex | herminiotorres/curso-elixir | 19519a2ac27b7c3e4973cdb2053c32dd61647cb5 | [
"MIT"
] | null | null | null | defmodule ExMon.Trainer.Delete do
alias Ecto.UUID
alias ExMon.{Repo, Trainer}
def call(id) do
case UUID.cast(id) do
:error -> {:error, "Invalid ID Format"}
{:ok, uuid} -> delete(uuid)
end
end
defp delete(uuid) do
case fetch_trainer(uuid) do
nil -> {:error, "Trainer Not Found"}
... | 20.619048 | 55 | 0.630485 |
3326f41afb340efd2ff044ec0f5a8c2762ccda8e | 230 | exs | Elixir | priv/repo/migrations/20191001212344_change_channel_to_organization_id.exs | maco2035/console | 2a9a65678b8c671c7d92cdb62dfcfc71b84957c5 | [
"Apache-2.0"
] | 83 | 2018-05-31T14:49:10.000Z | 2022-03-27T16:49:49.000Z | priv/repo/migrations/20191001212344_change_channel_to_organization_id.exs | maco2035/console | 2a9a65678b8c671c7d92cdb62dfcfc71b84957c5 | [
"Apache-2.0"
] | 267 | 2018-05-22T23:19:02.000Z | 2022-03-31T04:31:06.000Z | priv/repo/migrations/20191001212344_change_channel_to_organization_id.exs | maco2035/console | 2a9a65678b8c671c7d92cdb62dfcfc71b84957c5 | [
"Apache-2.0"
] | 18 | 2018-11-20T05:15:54.000Z | 2022-03-28T08:20:13.000Z | defmodule Console.Repo.Migrations.ChangeChannelToOrganizationId do
use Ecto.Migration
def change do
alter table(:channels) do
remove :team_id
add :organization_id, references(:organizations)
end
end
end
| 20.909091 | 66 | 0.743478 |
332707bd34a167d02c21fe61fd17d069bd585cb4 | 2,440 | ex | Elixir | tab_player/lib/tab_player.ex | alpdenizz/ElixirPlayground | 58b5a16c489058e0067e4811042d96fe6a5f8d59 | [
"MIT"
] | null | null | null | tab_player/lib/tab_player.ex | alpdenizz/ElixirPlayground | 58b5a16c489058e0067e4811042d96fe6a5f8d59 | [
"MIT"
] | null | null | null | tab_player/lib/tab_player.ex | alpdenizz/ElixirPlayground | 58b5a16c489058e0067e4811042d96fe6a5f8d59 | [
"MIT"
] | null | null | null | defmodule TabPlayer do
def parse(tab) do
list = String.split(tab,"\n")
list = List.delete(list,"")
listOfList = Enum.map(list, fn(x) -> String.codepoints(x) end)
listOfIndex = Enum.map(listOfList, fn(x) -> Enum.with_index(x) end)
headListOfIndex = hd listOfIndex
getSt... | 41.355932 | 137 | 0.588115 |
3327857c18b17cd14b50b01cc38ba0326be71908 | 1,685 | ex | Elixir | lib/rclex/publisher.ex | rclex/rclex | 978095d43c7bd18f20ab9e2ad2646a8201085db5 | [
"Apache-2.0"
] | 42 | 2021-05-05T09:11:33.000Z | 2022-02-12T11:57:12.000Z | lib/rclex/publisher.ex | rclex/rclex | 978095d43c7bd18f20ab9e2ad2646a8201085db5 | [
"Apache-2.0"
] | 49 | 2021-05-05T08:31:38.000Z | 2022-03-22T10:39:57.000Z | lib/rclex/publisher.ex | rclex/rclex | 978095d43c7bd18f20ab9e2ad2646a8201085db5 | [
"Apache-2.0"
] | 1 | 2021-05-31T09:28:37.000Z | 2021-05-31T09:28:37.000Z | defmodule Rclex.Publisher do
alias Rclex.Nifs
require Rclex.Macros
require Logger
use GenServer
@moduledoc """
T.B.A
"""
@doc """
publisherプロセスの生成
"""
def start_link({pub, process_name}) do
GenServer.start_link(__MODULE__, pub, name: {:global, process_name})
end
@doc """
publisher... | 21.602564 | 74 | 0.623739 |
3327de6e00388bf9848961310b6d349cc356bd92 | 3,329 | ex | Elixir | clients/content/lib/google_api/content/v2/model/datafeed_fetch_schedule.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2021-12-20T03:40:53.000Z | 2021-12-20T03:40:53.000Z | clients/content/lib/google_api/content/v2/model/datafeed_fetch_schedule.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2020-08-18T00:11:23.000Z | 2020-08-18T00:44:16.000Z | clients/content/lib/google_api/content/v2/model/datafeed_fetch_schedule.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... | 46.887324 | 289 | 0.67708 |
332802165b0d1bb8c02e98a8777c42cbea39d982 | 5,490 | ex | Elixir | clients/display_video/lib/google_api/display_video/v1/model/insertion_order.ex | MasashiYokota/elixir-google-api | 975dccbff395c16afcb62e7a8e411fbb58e9ab01 | [
"Apache-2.0"
] | null | null | null | clients/display_video/lib/google_api/display_video/v1/model/insertion_order.ex | MasashiYokota/elixir-google-api | 975dccbff395c16afcb62e7a8e411fbb58e9ab01 | [
"Apache-2.0"
] | null | null | null | clients/display_video/lib/google_api/display_video/v1/model/insertion_order.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... | 63.837209 | 558 | 0.728415 |
332859f4a409df2bfcfd5814a78783a5d4e6878c | 1,313 | exs | Elixir | test/shared/cache/transaction_test.exs | bbassett/nebulex | 4bbe24358a128a6205309c09c2ca758a89dfce40 | [
"MIT"
] | 1 | 2021-03-04T12:47:10.000Z | 2021-03-04T12:47:10.000Z | test/shared/cache/transaction_test.exs | peburrows/nebulex | df9146e3af6600e79e5f0db2a74e0be7b1055250 | [
"MIT"
] | null | null | null | test/shared/cache/transaction_test.exs | peburrows/nebulex | df9146e3af6600e79e5f0db2a74e0be7b1055250 | [
"MIT"
] | null | null | null | defmodule Nebulex.Cache.TransactionTest do
import Nebulex.SharedTestCase
deftests do
test "transaction" do
refute @cache.transaction(fn ->
1
|> @cache.set(11, return: :key)
|> @cache.get!(return: :key)
|> @cache.delete(return: :key)
... | 21.883333 | 61 | 0.467631 |
3328665bac15d04cc7fc67df80922effe5569e9f | 666 | exs | Elixir | config/test.exs | joaopealves/heat_tags | 95cbc1bc0d74a1ba7f715e77c33d0696a879a3fe | [
"MIT"
] | null | null | null | config/test.exs | joaopealves/heat_tags | 95cbc1bc0d74a1ba7f715e77c33d0696a879a3fe | [
"MIT"
] | null | null | null | config/test.exs | joaopealves/heat_tags | 95cbc1bc0d74a1ba7f715e77c33d0696a879a3fe | [
"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 :heat_tags, HeatTags.Repo,
username: "postgres",
password: "@dmin",
database: "heat_tags_test#{System.... | 28.956522 | 68 | 0.749249 |
33286bbfef28eb97617fc6e999529e585b0a617b | 984 | exs | Elixir | config/config.exs | georgelima/changex | cb91da8c3b10c05acafd1fd49dae4ed6365a197b | [
"MIT"
] | 134 | 2015-01-10T13:33:24.000Z | 2022-03-05T15:07:30.000Z | config/config.exs | georgelima/changex | cb91da8c3b10c05acafd1fd49dae4ed6365a197b | [
"MIT"
] | 6 | 2015-08-26T13:40:26.000Z | 2019-01-09T17:00:48.000Z | config/config.exs | hamiltop/structurez | 350229d5b2d845795d552db3c1608b1985144113 | [
"MIT"
] | 12 | 2015-02-11T06:16:24.000Z | 2018-01-18T09:33:47.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... | 41 | 73 | 0.751016 |
33286f7a1edac9a1420a18cd6093c634077a0a23 | 692,679 | ex | Elixir | clients/health_care/lib/google_api/health_care/v1beta1/api/projects.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2021-12-20T03:40:53.000Z | 2021-12-20T03:40:53.000Z | clients/health_care/lib/google_api/health_care/v1beta1/api/projects.ex | pojiro/elixir-google-api | 928496a017d3875a1929c6809d9221d79404b910 | [
"Apache-2.0"
] | 1 | 2020-08-18T00:11:23.000Z | 2020-08-18T00:44:16.000Z | clients/health_care/lib/google_api/health_care/v1beta1/api/projects.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... | 52.835927 | 3,984 | 0.636155 |
3328757ef6be9c28e0b2dcc5acb3680138ee8119 | 5,233 | ex | Elixir | lib/btrz_ex_api_client.ex | Betterez/btrz-ex-api-client | 92e56fb8944de4cf4926aa0192525d33d77e87b4 | [
"MIT"
] | 2 | 2019-02-18T20:18:20.000Z | 2019-02-25T22:38:04.000Z | lib/btrz_ex_api_client.ex | Betterez/btrz-ex-api-client | 92e56fb8944de4cf4926aa0192525d33d77e87b4 | [
"MIT"
] | null | null | null | lib/btrz_ex_api_client.ex | Betterez/btrz-ex-api-client | 92e56fb8944de4cf4926aa0192525d33d77e87b4 | [
"MIT"
] | null | null | null | defmodule BtrzExApiClient do
@moduledoc """
Main module to handle requests to the Betterez's APIs.
"""
alias BtrzExApiClient.Types
@http_client Application.get_env(:btrz_ex_api_client, :http_client) || BtrzExApiClient.HTTPoison
@client_version Mix.Project.config()[:version]
@allowed_methods [:get, :post... | 29.398876 | 194 | 0.635009 |
33287683b08c2daaabc370ef869596c772a773f4 | 390 | exs | Elixir | clients/app_engine/test/test_helper.exs | leandrocp/elixir-google-api | a86e46907f396d40aeff8668c3bd81662f44c71e | [
"Apache-2.0"
] | 1 | 2018-12-03T23:43:10.000Z | 2018-12-03T23:43:10.000Z | clients/app_engine/test/test_helper.exs | leandrocp/elixir-google-api | a86e46907f396d40aeff8668c3bd81662f44c71e | [
"Apache-2.0"
] | null | null | null | clients/app_engine/test/test_helper.exs | leandrocp/elixir-google-api | a86e46907f396d40aeff8668c3bd81662f44c71e | [
"Apache-2.0"
] | 1 | 2020-11-10T16:58:27.000Z | 2020-11-10T16:58:27.000Z | ExUnit.start()
defmodule GoogleApi.AppEngine.V1.TestHelper do
defmacro __using__(opts) do
quote do
use ExUnit.Case, unquote(opts)
import GoogleApi.AppEngine.V1.TestHelper
end
end
def for_scope(scopes) when is_list(scopes), do: for_scope(Enum.join(scopes, " "))
def for_scope(scope) do
... | 20.526316 | 83 | 0.7 |
332880bddc71d830fa78ae02326e463de7036371 | 108 | ex | Elixir | lib/colorify/repo.ex | ashkan18/colorify | e4da2bc54a60199c411afc696086689d825b7a13 | [
"MIT"
] | 1 | 2020-03-12T18:44:10.000Z | 2020-03-12T18:44:10.000Z | lib/colorify/repo.ex | ashkan18/colorify | e4da2bc54a60199c411afc696086689d825b7a13 | [
"MIT"
] | 1 | 2021-03-10T10:22:38.000Z | 2021-03-10T10:22:38.000Z | lib/colorify/repo.ex | ashkan18/colorify | e4da2bc54a60199c411afc696086689d825b7a13 | [
"MIT"
] | 1 | 2020-03-12T18:41:42.000Z | 2020-03-12T18:41:42.000Z | defmodule Colorify.Repo do
use Ecto.Repo,
otp_app: :colorify,
adapter: Ecto.Adapters.Postgres
end
| 18 | 35 | 0.731481 |
33288b0a332ff60bbeab94d7ff2e513113f5a1d9 | 715 | ex | Elixir | lib/hiit_live_web/gettext.ex | beji/hiit_live | ddd835d27cbe733ea177540dd625b665c8b54f86 | [
"MIT"
] | null | null | null | lib/hiit_live_web/gettext.ex | beji/hiit_live | ddd835d27cbe733ea177540dd625b665c8b54f86 | [
"MIT"
] | null | null | null | lib/hiit_live_web/gettext.ex | beji/hiit_live | ddd835d27cbe733ea177540dd625b665c8b54f86 | [
"MIT"
] | null | null | null | defmodule HiitLiveWeb.Gettext do
@moduledoc """
A module providing Internationalization with a gettext-based API.
By using [Gettext](https://hexdocs.pm/gettext),
your module gains a set of macros for translations, for example:
import HiitLiveWeb.Gettext
# Simple translation
gettext("Here is... | 28.6 | 72 | 0.67972 |
33289373f794a09154d2bcd1c74c1bad2fdc37ed | 134 | exs | Elixir | apps/cms/config/dev.exs | glv/revista | 00ecb0780c62a5525155a773b959b169e0e0500d | [
"MIT"
] | 17 | 2019-01-31T18:33:09.000Z | 2022-01-18T12:38:49.000Z | apps/cms/config/dev.exs | glv/revista | 00ecb0780c62a5525155a773b959b169e0e0500d | [
"MIT"
] | null | null | null | apps/cms/config/dev.exs | glv/revista | 00ecb0780c62a5525155a773b959b169e0e0500d | [
"MIT"
] | 4 | 2018-11-10T01:56:17.000Z | 2020-06-09T21:10:41.000Z | use Mix.Config
config :cms, CMS.Repo,
database: "cms_dev",
username: "postgres",
password: "postgres",
hostname: "localhost"
| 16.75 | 23 | 0.686567 |
332893b10eac58eebbad4d7661bc1d116691fecb | 934 | ex | Elixir | test/support/channel_case.ex | smartlogic/stein_example | 7ef369757989a9a56d04e87f6421675bf69193a2 | [
"MIT"
] | 7 | 2019-12-13T19:23:47.000Z | 2022-01-22T23:02:42.000Z | test/support/channel_case.ex | smartlogic/stein_example | 7ef369757989a9a56d04e87f6421675bf69193a2 | [
"MIT"
] | 11 | 2021-03-10T01:57:00.000Z | 2021-08-31T18:30:54.000Z | test/support/channel_case.ex | smartlogic/stein_example | 7ef369757989a9a56d04e87f6421675bf69193a2 | [
"MIT"
] | null | null | null | defmodule Web.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 data structures and query the data layer.
Finally, if the test case interacts with the... | 24.578947 | 74 | 0.714133 |
3328e9b80f4e87ce114db85744c54a5da77ebe25 | 114,564 | ex | Elixir | lib/elixir/lib/enum.ex | lanodan/elixir | 10ae66cda989f324bf76c402473fd5661a459100 | [
"Apache-2.0"
] | null | null | null | lib/elixir/lib/enum.ex | lanodan/elixir | 10ae66cda989f324bf76c402473fd5661a459100 | [
"Apache-2.0"
] | null | null | null | lib/elixir/lib/enum.ex | lanodan/elixir | 10ae66cda989f324bf76c402473fd5661a459100 | [
"Apache-2.0"
] | null | null | null | defprotocol Enumerable do
@moduledoc """
Enumerable protocol used by `Enum` and `Stream` modules.
When you invoke a function in the `Enum` module, the first argument
is usually a collection that must implement this protocol.
For example, the expression:
Enum.map([1, 2, 3], &(&1 * 2))
invokes `Enume... | 28.748808 | 115 | 0.61645 |
3328ff5feeb288b2834e66c1abe6f541a8256ed2 | 1,063 | ex | Elixir | apps/day12/lib/day12.ex | jochumb/aoc2017 | 813851fcab9270adea1bc532335f2228f5c015be | [
"MIT"
] | null | null | null | apps/day12/lib/day12.ex | jochumb/aoc2017 | 813851fcab9270adea1bc532335f2228f5c015be | [
"MIT"
] | null | null | null | apps/day12/lib/day12.ex | jochumb/aoc2017 | 813851fcab9270adea1bc532335f2228f5c015be | [
"MIT"
] | null | null | null | defmodule Day12 do
@moduledoc "Day 12: Digital Plumber"
def part1(input) do
input
|> parse_to_map
|> find_group([:"0"])
|> Enum.count
end
def part2(input) do
input
|> parse_to_map
|> find_all_groups_async
|> Enum.uniq
|> Enum.count
end
defp find_group(map, progs, acc \... | 21.26 | 65 | 0.561618 |
33290125a8edcd996eed8dbc2ff6fd5afc2d541d | 723 | ex | Elixir | lib/twinklyhaha_web/gettext.ex | TraceyOnim/TwinklyHaHa | 4dc66c6701bc351847f6ec1677da8cd752c27a86 | [
"MIT"
] | 2 | 2020-10-04T12:41:53.000Z | 2020-11-11T11:24:54.000Z | lib/twinklyhaha_web/gettext.ex | TraceyOnim/TwinklyHaHa | 4dc66c6701bc351847f6ec1677da8cd752c27a86 | [
"MIT"
] | 22 | 2021-12-02T09:16:30.000Z | 2022-03-21T06:33:29.000Z | lib/twinklyhaha_web/gettext.ex | TraceyOnim/TwinklyHaHa | 4dc66c6701bc351847f6ec1677da8cd752c27a86 | [
"MIT"
] | 2 | 2020-11-09T08:27:19.000Z | 2020-11-10T04:25:21.000Z | defmodule TwinklyhahaWeb.Gettext do
@moduledoc """
A module providing Internationalization with a gettext-based API.
By using [Gettext](https://hexdocs.pm/gettext),
your module gains a set of macros for translations, for example:
import TwinklyhahaWeb.Gettext
# Simple translation
gettext("H... | 28.92 | 72 | 0.683264 |
33291481b47a8f526fe1bf12d61c8122ddd8876b | 99 | exs | Elixir | test/honeybadger/utils_test.exs | thomasbrus/honeybadger-elixir | 659ecf2c2929f66adfbdc1cb0783a201ed1156a1 | [
"MIT"
] | null | null | null | test/honeybadger/utils_test.exs | thomasbrus/honeybadger-elixir | 659ecf2c2929f66adfbdc1cb0783a201ed1156a1 | [
"MIT"
] | null | null | null | test/honeybadger/utils_test.exs | thomasbrus/honeybadger-elixir | 659ecf2c2929f66adfbdc1cb0783a201ed1156a1 | [
"MIT"
] | null | null | null | defmodule Honeybadger.UtilsTest do
use ExUnit.Case, async: true
doctest Honeybadger.Utils
end
| 16.5 | 34 | 0.79798 |
33291dd148e975f5d582df01055e296002684fe9 | 1,499 | exs | Elixir | config/config.exs | meltingice/nanocrawler-phoenix | 2477e8cb63a04d89eeda676c474e9b89c29da0e5 | [
"MIT"
] | 1 | 2020-04-19T07:48:46.000Z | 2020-04-19T07:48:46.000Z | config/config.exs | meltingice/nanocrawler-phoenix | 2477e8cb63a04d89eeda676c474e9b89c29da0e5 | [
"MIT"
] | 2 | 2021-03-09T20:27:19.000Z | 2021-05-10T17:32:50.000Z | config/config.exs | meltingice/nanocrawler-phoenix | 2477e8cb63a04d89eeda676c474e9b89c29da0e5 | [
"MIT"
] | null | null | null | # This file is responsible for configuring your application
# and its dependencies with the aid of the Mix.Config module.
#
# This configuration file is loaded before any dependency and
# is restricted to this project.
# General application configuration
use Mix.Config
#
# Start user configurable section
#
# rpc: %{t... | 32.586957 | 86 | 0.749833 |
3329326bcf6e4fb15d5ea76ff673852c86d12924 | 143 | ex | Elixir | lib/policies.ex | paridin/policies | 4d3d83b1729be4d9624f8eead7d82014a5fd4daa | [
"Apache-2.0"
] | null | null | null | lib/policies.ex | paridin/policies | 4d3d83b1729be4d9624f8eead7d82014a5fd4daa | [
"Apache-2.0"
] | null | null | null | lib/policies.ex | paridin/policies | 4d3d83b1729be4d9624f8eead7d82014a5fd4daa | [
"Apache-2.0"
] | null | null | null | defmodule Policies do
@moduledoc """
Policies focus on the platform
The idea behind if the policies should grow as a service.
"""
end
| 17.875 | 59 | 0.72028 |
332934cdf063d1a37ef3b94e5ed94abfac74d03e | 728 | exs | Elixir | test/tradehub/tx/activate_sub_account_test.exs | anhmv/tradehub-api-elixir | 6ec87c2b07188d4140506011e2b28db4d372ac6d | [
"MIT"
] | 5 | 2021-05-04T16:54:25.000Z | 2021-12-15T06:53:24.000Z | test/tradehub/tx/activate_sub_account_test.exs | anhmv/tradehub-api-elixir | 6ec87c2b07188d4140506011e2b28db4d372ac6d | [
"MIT"
] | 5 | 2021-05-19T04:49:00.000Z | 2021-06-01T13:36:50.000Z | test/tradehub/tx/activate_sub_account_test.exs | anhmv/tradehub-elixir | 6ec87c2b07188d4140506011e2b28db4d372ac6d | [
"MIT"
] | null | null | null | defmodule TradehubTest.Tx.ActivateSubAccountTest do
use ExUnit.Case, async: true
alias Tradehub.Tx.MsgInvalid
alias Tradehub.Tx.ActivateSubAccount
import Tradehub.Tx.ActivateSubAccount
test "expects failure when missing main account" do
assert_raise MsgInvalid, fn ->
validate!(%ActivateSubAccount... | 28 | 75 | 0.747253 |
33295bdf618703eb436c5248df01e2da74ad77fb | 2,009 | ex | Elixir | clients/spanner/lib/google_api/spanner/v1/model/list_database_operations_response.ex | MasashiYokota/elixir-google-api | 975dccbff395c16afcb62e7a8e411fbb58e9ab01 | [
"Apache-2.0"
] | null | null | null | clients/spanner/lib/google_api/spanner/v1/model/list_database_operations_response.ex | MasashiYokota/elixir-google-api | 975dccbff395c16afcb62e7a8e411fbb58e9ab01 | [
"Apache-2.0"
] | 1 | 2020-12-18T09:25:12.000Z | 2020-12-18T09:25:12.000Z | clients/spanner/lib/google_api/spanner/v1/model/list_database_operations_response.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... | 40.18 | 305 | 0.75112 |
33297ec15b669e94035d34ebd81bdd2dee8e6941 | 1,305 | exs | Elixir | config/config.exs | omnifroodle/astraex | 873d5ca985c8387f236c086ffb76780092823e01 | [
"Apache-2.0"
] | 3 | 2021-02-16T20:30:52.000Z | 2021-08-16T15:02:59.000Z | config/config.exs | omnifroodle/astraex | 873d5ca985c8387f236c086ffb76780092823e01 | [
"Apache-2.0"
] | null | null | null | config/config.exs | omnifroodle/astraex | 873d5ca985c8387f236c086ffb76780092823e01 | [
"Apache-2.0"
] | null | null | null | # This file is responsible for configuring your application
# and its dependencies with the aid of the Mix.Config module.
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... | 34.342105 | 73 | 0.750192 |
3329bdeef96d717df1ef213e4867d9c3d9fa2e63 | 2,868 | ex | Elixir | lib/bifroest/openstack/network.ex | theSuess/bifroest-web | fc25d4e827546b2e1a08719962f0e161d622eded | [
"BSD-3-Clause"
] | 1 | 2017-03-29T06:48:06.000Z | 2017-03-29T06:48:06.000Z | lib/bifroest/openstack/network.ex | theSuess/bifroest-web | fc25d4e827546b2e1a08719962f0e161d622eded | [
"BSD-3-Clause"
] | null | null | null | lib/bifroest/openstack/network.ex | theSuess/bifroest-web | fc25d4e827546b2e1a08719962f0e161d622eded | [
"BSD-3-Clause"
] | null | null | null | defmodule Bifroest.Openstack.Network do
defmodule Network do
defstruct [:id, :name, :status]
end
defmodule SecurityGroup do
defstruct [:id, :name, :project_id]
end
import Bifroest.Openstack.Base
require Logger
@url Application.get_env(:bifroest,:openstack_network_url)
def basic_tcp_rule(port... | 35.407407 | 120 | 0.614017 |
3329c055feae819b33352be9f39a5246d3adeba5 | 8,481 | ex | Elixir | lib/zitadel/object.pb.ex | jshmrtn/zitadel_api | 10601b7382df92a4c8f2a3ad1e083634dcaf6243 | [
"Apache-2.0"
] | 3 | 2020-11-11T15:24:21.000Z | 2022-02-04T20:40:36.000Z | lib/zitadel/object.pb.ex | jshmrtn/zitadel_api | 10601b7382df92a4c8f2a3ad1e083634dcaf6243 | [
"Apache-2.0"
] | 2 | 2020-11-11T15:15:36.000Z | 2020-11-11T15:19:00.000Z | lib/zitadel/object.pb.ex | jshmrtn/zitadel_api | 10601b7382df92a4c8f2a3ad1e083634dcaf6243 | [
"Apache-2.0"
] | null | null | null | defmodule Zitadel.V1.TextQueryMethod do
use Protobuf, enum: true, syntax: :proto3
@type text_query_method_equals :: :TEXT_QUERY_METHOD_EQUALS
@type text_query_method_equals_ignore_case :: :TEXT_QUERY_METHOD_EQUALS_IGNORE_CASE
@type text_query_method_starts_with :: :TEXT_QUERY_METHOD_STARTS_WITH
@type text_que... | 44.636842 | 98 | 0.615376 |
3329c55e5951fa0db53197bea1753887d772f045 | 2,909 | ex | Elixir | chapter11/phone_ets.ex | dcarneiro/etudes-for-elixir | 807d21942747817d84fc2890806582b59921bd59 | [
"MIT"
] | null | null | null | chapter11/phone_ets.ex | dcarneiro/etudes-for-elixir | 807d21942747817d84fc2890806582b59921bd59 | [
"MIT"
] | null | null | null | chapter11/phone_ets.ex | dcarneiro/etudes-for-elixir | 807d21942747817d84fc2890806582b59921bd59 | [
"MIT"
] | null | null | null | defmodule Phone do
require Record
Record.defrecord :phone, [
number: "",
starting_date: "1900-01-01",
starting_time: "00:00:00",
end_date: "1900-01-01",
end_time: "00:00:00"
]
end
defmodule PhoneEts do
require Phone
@doc """
Read from a file and construct a corresponding ETS table
"... | 25.973214 | 84 | 0.64352 |
3329c76c2b6b6b676fb9b85eb437806854c32b4f | 2,657 | exs | Elixir | apps/ewallet_db/priv/repo/migrations/20180607103719_move_ledger_response_into_specific_fields.exs | vanmil/ewallet | 6c1aca95a83e0a9d93007670a40d8c45764a8122 | [
"Apache-2.0"
] | null | null | null | apps/ewallet_db/priv/repo/migrations/20180607103719_move_ledger_response_into_specific_fields.exs | vanmil/ewallet | 6c1aca95a83e0a9d93007670a40d8c45764a8122 | [
"Apache-2.0"
] | null | null | null | apps/ewallet_db/priv/repo/migrations/20180607103719_move_ledger_response_into_specific_fields.exs | vanmil/ewallet | 6c1aca95a83e0a9d93007670a40d8c45764a8122 | [
"Apache-2.0"
] | null | null | null | defmodule EWalletDB.Repo.Migrations.MoveLedgerResponseIntoSpecificFields do
use Ecto.Migration
import Ecto.Query
alias EWalletDB.Repo
alias EWalletDB.Encrypted
def up do
alter table(:transfer) do
add :entry_uuid, :string
add :error_code, :string
add :error_description, :string
add... | 26.838384 | 97 | 0.603688 |
332a132272d41920ab110d11276faf885fa532e7 | 933 | ex | Elixir | discuss/web/channels/comments_channel.ex | enelesmai/elixir-bootcamp | 0cc3ee791063eba48ed9eedb64a9b2d46a0e7cf9 | [
"MIT"
] | null | null | null | discuss/web/channels/comments_channel.ex | enelesmai/elixir-bootcamp | 0cc3ee791063eba48ed9eedb64a9b2d46a0e7cf9 | [
"MIT"
] | null | null | null | discuss/web/channels/comments_channel.ex | enelesmai/elixir-bootcamp | 0cc3ee791063eba48ed9eedb64a9b2d46a0e7cf9 | [
"MIT"
] | null | null | null | defmodule Discuss.CommentsChannel do
use Discuss.Web, :channel
alias Discuss.{Topic, Comment}
#comments:6
def join("comments:" <> topic_id, _params, socket) do
topic_id = String.to_integer(topic_id)
topic = Topic
|> Repo.get(topic_id)
|> Repo.preload(comments: [:user])
{:ok, %{comm... | 25.216216 | 70 | 0.617363 |
332a405020803118690065a28dad27339b70be0d | 2,358 | exs | Elixir | test/cldr_routes_test.exs | elixir-cldr/cldr_routes | 0082500daccbc2b0860c0bc451a1c3b33f3fc8c4 | [
"Apache-2.0"
] | null | null | null | test/cldr_routes_test.exs | elixir-cldr/cldr_routes | 0082500daccbc2b0860c0bc451a1c3b33f3fc8c4 | [
"Apache-2.0"
] | null | null | null | test/cldr_routes_test.exs | elixir-cldr/cldr_routes | 0082500daccbc2b0860c0bc451a1c3b33f3fc8c4 | [
"Apache-2.0"
] | null | null | null | defmodule Cldr.Route.Test do
use ExUnit.Case
use Plug.Test
doctest Cldr.Route
doctest MyApp.Router.LocalizedHelpers
describe "Routes" do
test "Localized route generation" do
assert Phoenix.Router.route_info(MyApp.Router, "GET", "/pages/1", "myhost") ==
%{
log: :debug,
p... | 30.230769 | 107 | 0.600509 |
332ae09b6d3e206dbdad87639a4b8ca885ee7fdf | 502 | ex | Elixir | apps/ello_serve/lib/ello_serve/set_app.ex | ello/apex | 4acb096b3ce172ff4ef9a51e5d068d533007b920 | [
"MIT"
] | 16 | 2017-06-21T21:31:20.000Z | 2021-05-09T03:23:26.000Z | apps/ello_serve/lib/ello_serve/set_app.ex | ello/apex | 4acb096b3ce172ff4ef9a51e5d068d533007b920 | [
"MIT"
] | 25 | 2017-06-07T12:18:28.000Z | 2018-06-08T13:27:43.000Z | apps/ello_serve/lib/ello_serve/set_app.ex | ello/apex | 4acb096b3ce172ff4ef9a51e5d068d533007b920 | [
"MIT"
] | 3 | 2018-06-14T15:34:07.000Z | 2022-02-28T21:06:13.000Z | defmodule Ello.Serve.SetApp do
@moduledoc """
Set the application name in assigns.
We can then use that to know what app we are serving. Called via plug/router:
plug ElloServer.SetApp, app: "webapp"
# or
plug ElloServer.SetApp, app: "curator"
"""
@behaviour Plug
import Plug.Conn
de... | 19.307692 | 79 | 0.635458 |
332b09842dcbf671be5087eee174038a2bb06629 | 694 | ex | Elixir | lib/docusign/model/user_signature_definition.ex | gaslight/docusign_elixir | d9d88d53dd85d32a39d537bade9db28d779414e6 | [
"MIT"
] | 4 | 2020-12-21T12:50:13.000Z | 2022-01-12T16:50:43.000Z | lib/docusign/model/user_signature_definition.ex | gaslight/docusign_elixir | d9d88d53dd85d32a39d537bade9db28d779414e6 | [
"MIT"
] | 12 | 2018-09-18T15:26:34.000Z | 2019-09-28T15:29:39.000Z | lib/docusign/model/user_signature_definition.ex | gaslight/docusign_elixir | d9d88d53dd85d32a39d537bade9db28d779414e6 | [
"MIT"
] | 15 | 2020-04-29T21:50:16.000Z | 2022-02-11T18:01:51.000Z | # NOTE: This class is auto generated by the swagger code generator program.
# https://github.com/swagger-api/swagger-codegen.git
# Do not edit the class manually.
defmodule DocuSign.Model.UserSignatureDefinition do
@moduledoc """
"""
@derive [Poison.Encoder]
defstruct [
:signatureFont,
:signatureId,
... | 22.387097 | 75 | 0.662824 |
332b17f98aa339fa5a08cb261f17dd4f3dc7d3d8 | 3,255 | exs | Elixir | test/mssqlex/constraints_test.exs | cogini/mssqlex | f94654f1b2b167b5edf07c985a577313d31fd84d | [
"Apache-2.0"
] | 45 | 2017-02-21T13:30:21.000Z | 2021-12-19T20:04:49.000Z | test/mssqlex/constraints_test.exs | cogini/mssqlex | f94654f1b2b167b5edf07c985a577313d31fd84d | [
"Apache-2.0"
] | 21 | 2017-03-29T11:48:40.000Z | 2020-12-11T15:18:23.000Z | test/mssqlex/constraints_test.exs | cogini/mssqlex | f94654f1b2b167b5edf07c985a577313d31fd84d | [
"Apache-2.0"
] | 23 | 2017-04-13T10:07:34.000Z | 2022-03-26T02:38:10.000Z | defmodule Mssqlex.ConstraintsTest do
use ExUnit.Case, async: true
setup_all do
{:ok, pid} = Mssqlex.start_link([])
Mssqlex.query!(pid, "DROP DATABASE IF EXISTS constraints_test;", [])
{:ok, _, _} = Mssqlex.query(pid, "CREATE DATABASE constraints_test;", [])
{:ok, [pid: pid]}
end
test "Unique ... | 24.111111 | 79 | 0.582488 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.