repo
stringlengths
5
92
file_url
stringlengths
80
287
file_path
stringlengths
5
197
content
stringlengths
0
32.8k
language
stringclasses
1 value
license
stringclasses
7 values
commit_sha
stringlengths
40
40
retrieved_at
stringdate
2026-01-04 15:37:27
2026-01-04 17:58:21
truncated
bool
2 classes
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/enterprise_management_console_client.rb
lib/octokit/enterprise_management_console_client.rb
# frozen_string_literal: true require 'octokit/configurable' require 'octokit/connection' require 'octokit/warnable' require 'octokit/enterprise_management_console_client/management_console' module Octokit # EnterpriseManagementConsoleClient is only meant to be used by GitHub Enterprise Admins # and provides acce...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/enterprise_admin_client.rb
lib/octokit/enterprise_admin_client.rb
# frozen_string_literal: true require 'octokit/connection' require 'octokit/configurable' require 'octokit/warnable' require 'octokit/enterprise_admin_client/admin_stats' require 'octokit/enterprise_admin_client/license' require 'octokit/enterprise_admin_client/orgs' require 'octokit/enterprise_admin_client/search_ind...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/manage_ghes_client.rb
lib/octokit/manage_ghes_client.rb
# frozen_string_literal: true require 'octokit/configurable' require 'octokit/connection' require 'octokit/warnable' require 'octokit/manage_ghes_client/manage_ghes' module Octokit # ManageGHESClient is only meant to be used by GitHub Enterprise Server (GHES) operators # and provides access to the Manage GHES API...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/configurable.rb
lib/octokit/configurable.rb
# frozen_string_literal: true module Octokit # Configuration options for {Client}, defaulting to values # in {Default} module Configurable # @!attribute [w] access_token # @see https://developer.github.com/v3/oauth/ # @return [String] OAuth2 access token for authentication # @!attribute api_e...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/error.rb
lib/octokit/error.rb
# frozen_string_literal: true module Octokit # Custom error class for rescuing from all GitHub errors class Error < StandardError attr_reader :context # Returns the appropriate Octokit::Error subclass based # on status and response message # # @param [Hash] response HTTP response # @return...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/repo_arguments.rb
lib/octokit/repo_arguments.rb
# frozen_string_literal: true module Octokit # Class to extract options from Ruby arguments for # Repository-related methods class RepoArguments < Arguments # !@attribute [r] repo # @return [Repository] attr_reader :repo def initialize(args) arguments = super @repo = arguments.shif...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/user.rb
lib/octokit/user.rb
# frozen_string_literal: true module Octokit # GitHub user class to generate API path urls class User # Get the api path for a user # # @param user [String, Integer] GitHub user login or id # @return [String] User Api path def self.path(user) case user when String "users/#{u...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/middleware/follow_redirects.rb
lib/octokit/middleware/follow_redirects.rb
# frozen_string_literal: true require 'faraday' require 'set' # Adapted from lostisland/faraday_middleware. Trimmed down to just the logic # that we need for octokit.rb. # # https://github.com/lostisland/faraday_middleware/blob/138766e/lib/faraday_middleware/response/follow_redirects.rb module Octokit module Middl...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/manage_ghes_client/manage_ghes.rb
lib/octokit/manage_ghes_client/manage_ghes.rb
# frozen_string_literal: true module Octokit # Client for the Manage GitHub Enterprise Server API class ManageGHESClient # Methods for the Manage GitHub Enterprise Server API # # @see https://developer.github.com/v3/enterprise-admin/manage-ghes module ManageAPI # Get information about the mai...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/enterprise_admin_client/users.rb
lib/octokit/enterprise_admin_client/users.rb
# frozen_string_literal: true module Octokit class EnterpriseAdminClient # Methods for the Enterprise User Administration API # # @see https://developer.github.com/enterprise/v3/enterprise-admin/users/ module Users # Create a new user. # # @param login [String] The user's username. ...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/enterprise_admin_client/license.rb
lib/octokit/enterprise_admin_client/license.rb
# frozen_string_literal: true module Octokit class EnterpriseAdminClient # Methods for the Enterprise License API # # @see https://developer.github.com/v3/enterprise-admin/license/ module License # Get information about the Enterprise license # # @return [Sawyer::Resource] The licen...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/enterprise_admin_client/admin_stats.rb
lib/octokit/enterprise_admin_client/admin_stats.rb
# frozen_string_literal: true module Octokit class EnterpriseAdminClient # Methods for the Enterprise Admin Stats API # # @see https://developer.github.com/v3/enterprise-admin/admin_stats/ module AdminStats # Get all available stats # # @return [Sawyer::Resource] All available stats...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/enterprise_admin_client/search_indexing.rb
lib/octokit/enterprise_admin_client/search_indexing.rb
# frozen_string_literal: true module Octokit class EnterpriseAdminClient # Methods for the Enterprise Search Indexing API # # @see https://developer.github.com/v3/enterprise-admin/search_indexing/ module SearchIndexing # Queue a User or Organization to be indexed # # @param user [St...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/enterprise_admin_client/orgs.rb
lib/octokit/enterprise_admin_client/orgs.rb
# frozen_string_literal: true module Octokit class EnterpriseAdminClient # Methods for the Enterprise Orgs API # # @see https://developer.github.com/v3/enterprise-admin/orgs/ module Orgs # Create a new organization on the instance. # # @param login [String] The organization's userna...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/issues.rb
lib/octokit/client/issues.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Issues API # # @see https://developer.github.com/v3/issues/ module Issues # List issues for the authenticated user or repository # # @param repository [Integer, String, Repository, Hash] A GitHub repository....
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/releases.rb
lib/octokit/client/releases.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Releases API # # @see https://developer.github.com/v3/repos/releases/ module Releases # List releases for a repository # # @param repo [Integer, String, Repository, Hash] A GitHub repository # @return ...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/events.rb
lib/octokit/client/events.rb
# frozen_string_literal: true module Octokit class Client # Method for the Events API # # @see https://developer.github.com/v3/activity/events/ # @see https://developer.github.com/v3/issues/events/ module Events # List all public events for GitHub # # @return [Array<Sawyer::Reso...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/users.rb
lib/octokit/client/users.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Users API # # @see https://developer.github.com/v3/users/ module Users # List all GitHub users # # This provides a list of every user, in the order that they signed up # for GitHub. # # @pa...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/repository_invitations.rb
lib/octokit/client/repository_invitations.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Repository Invitations API # # @see https://developer.github.com/v3/repos/invitations/ module RepositoryInvitations # Invite a user to a repository # # Requires authenticated client # # @param re...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/refs.rb
lib/octokit/client/refs.rb
# frozen_string_literal: true module Octokit class Client # Methods for References for Git Data API # # @see https://developer.github.com/v3/git/refs/ module Refs # List all refs for a given user and repo # # @param repo [Integer, String, Repository, Hash] A GitHub repository ...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/meta.rb
lib/octokit/client/meta.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Meta API # # @see https://developer.github.com/v3/meta/ module Meta # Get meta information about GitHub.com, the service. # @see https://developer.github.com/v3/meta/#meta # @return [Sawyer::Resource] Hash w...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/tokens.rb
lib/octokit/client/tokens.rb
# frozen_string_literal: true module Octokit class Client # Method to check scopes # # @see https://developer.github.com/v3/oauth_authorizations/#oauth-authorizations-api module Tokens # Check scopes for a token # # @param token [String] GitHub OAuth token # @param options [Ha...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/milestones.rb
lib/octokit/client/milestones.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Issues Milestones API # # @see https://developer.github.com/v3/issues/milestones/ module Milestones # List milestones for a repository # # @param repository [Integer, String, Repository, Hash] A GitHub repos...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/hooks.rb
lib/octokit/client/hooks.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Hooks API module Hooks # List repo hooks # # Requires authenticated client. # # @param repo [Integer, String, Hash, Repository] A GitHub repository. # @return [Array<Sawyer::Resource>] Array of has...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/legacy_search.rb
lib/octokit/client/legacy_search.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Legacy Search API # # @see https://developer.github.com/v3/search/ module LegacySearch # Legacy repository search # # @see https://developer.github.com/v3/search/#search-repositories # @param q [String...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/actions_workflows.rb
lib/octokit/client/actions_workflows.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Actions Workflows API # # @see https://developer.github.com/v3/actions/workflows module ActionsWorkflows # Get the workflows in a repository # # @param repo [Integer, String, Repository, Hash] A GitHub repos...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/contents.rb
lib/octokit/client/contents.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Repo Contents API # # @see https://developer.github.com/v3/repos/contents/ module Contents # Receive the default Readme for a repository # # @param repo [Integer, String, Repository, Hash] A GitHub repositor...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/objects.rb
lib/octokit/client/objects.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Git Data API # # @see https://developer.github.com/v3/git/ module Objects # Get a single tree, fetching information about its root-level objects # # Pass <tt>:recursive => true</tt> in <tt>options</tt> to fe...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/commit_pulls.rb
lib/octokit/client/commit_pulls.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Commit Pulls API # # @see https://developer.github.com/v3/repos/comments/ module CommitPulls # List pulls for a single commit # # @param repo [Integer, String, Hash, Repository] A GitHub repository # @...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/organizations.rb
lib/octokit/client/organizations.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Organizations API # # @see https://developer.github.com/v3/orgs/ module Organizations # Get an organization # # @param org [String, Integer] Organization GitHub login or id. # @return [Sawyer::Resource...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
true
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/codespaces_secrets.rb
lib/octokit/client/codespaces_secrets.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Codespaces Secrets API # # @see https://docs.github.com/en/rest/codespaces/ module CodespacesSecrets # Get public key for secrets encryption # # @param repo [Integer, String, Hash, Repository] A GitHub repos...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/statuses.rb
lib/octokit/client/statuses.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Commit Statuses API # # @see https://developer.github.com/v3/repos/statuses/ module Statuses # List all statuses for a given commit # # @param repo [Integer, String, Repository, Hash] A GitHub repository ...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/reactions.rb
lib/octokit/client/reactions.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Reacions API # # @see https://developer.github.com/v3/reactions/ module Reactions # List reactions for a commit comment # # @param repo [Integer, String, Hash, Repository] A GitHub repository # @param ...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/traffic.rb
lib/octokit/client/traffic.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Traffic API # # @see https://developer.github.com/v3/repos/traffic/ module Traffic # Get the top 10 referrers over the last 14 days # # @param repo [Integer, String, Repository, Hash] A GitHub repository ...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/stats.rb
lib/octokit/client/stats.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Repository Statistics API # # @see https://developer.github.com/v3/repos/statistics/ module Stats # Get contributors list with additions, deletions, and commit counts # # @param repo [Integer, String, Hash, ...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/emojis.rb
lib/octokit/client/emojis.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Emojis API module Emojis # List all emojis used on GitHub # # @return [Sawyer::Resource] A list of all emojis on GitHub # @see https://developer.github.com/v3/emojis/#emojis # @example List all emojis ...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/rate_limit.rb
lib/octokit/client/rate_limit.rb
# frozen_string_literal: true module Octokit class Client # Methods for API rate limiting info # # @see https://developer.github.com/v3/#rate-limiting module RateLimit # Get rate limit info from last response if available # or make a new request to fetch rate limit # # @see ht...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/search.rb
lib/octokit/client/search.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Search API # # @see https://developer.github.com/v3/search/ module Search # Search code # # @param query [String] Search term and qualifiers # @param options [Hash] Sort and pagination options # ...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/projects.rb
lib/octokit/client/projects.rb
# frozen_string_literal: true module Octokit class Client # Methods for Projects API # # @see https://docs.github.com/en/rest/projects module Projects # List projects for a repository # # Requires authenticated client # # @param repo [Integer, String, Repository, Hash] A...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/downloads.rb
lib/octokit/client/downloads.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Repo Downloads API # # @see https://developer.github.com/v3/repos/downloads/ module Downloads # List available downloads for a repository # # @param repo [Integer, String, Repository, Hash] A Github Reposito...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/deployments.rb
lib/octokit/client/deployments.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Deployments API # # @see https://developer.github.com/v3/repos/commits/deployments/ module Deployments # Fetch a single deployment for a repository # # @param repo [Integer, String, Repository, Hash] A GitHu...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/feeds.rb
lib/octokit/client/feeds.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Feeds API # # @see https://developer.github.com/v3/activity/feeds/ module Feeds # List Feeds # # The feeds returned depend on authentication, see the GitHub API docs # for more information. # ...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/source_import.rb
lib/octokit/client/source_import.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Source Import API # # @see https://developer.github.com/v3/migration/source_imports module SourceImport # Start a source import to a GitHub repository using GitHub Importer. # # @overload start_source_import...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/pull_requests.rb
lib/octokit/client/pull_requests.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Pull Requests API # # @see https://developer.github.com/v3/pulls/ module PullRequests # List pull requests for a repository # # @overload pull_requests(repo, options) # @param repo [Integer, String, ...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/licenses.rb
lib/octokit/client/licenses.rb
# frozen_string_literal: true module Octokit class Client # Methods for licenses API # module Licenses # List all licenses # # @see https://developer.github.com/v3/licenses/#list-all-licenses # @return [Array<Sawyer::Resource>] A list of licenses # @example # Octokit...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/repositories.rb
lib/octokit/client/repositories.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Repositories API # # @see https://developer.github.com/v3/repos/ module Repositories # Check if a repository exists # # @see https://developer.github.com/v3/repos/#get # @param repo [Integer, String, H...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
true
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/dependabot_secrets.rb
lib/octokit/client/dependabot_secrets.rb
# frozen_string_literal: true module Octokit class Client # Methods for the dependabot Secrets API # # @see https://docs.github.com/en/rest/dependabot/ module DependabotSecrets # Get public key for secrets encryption # # @param repo [Integer, String, Hash, Repository] A GitHub repos...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/actions_artifacts.rb
lib/octokit/client/actions_artifacts.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Actions Artifacts API # # @see https://developer.github.com/v3/actions/artifacts module ActionsArtifacts # List all artifacts for a repository # # @param repo [Integer, String, Repository, Hash] A GitHub rep...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/actions_secrets.rb
lib/octokit/client/actions_secrets.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Actions Secrets API # # @see https://developer.github.com/v3/actions/secrets/ module ActionsSecrets # Get public key for secrets encryption # # @param repo [Integer, String, Hash, Repository] A GitHub reposi...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/commit_branches.rb
lib/octokit/client/commit_branches.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Branches for HEAD API # # @see https://developer.github.com/v3/repos/commits/ module CommitBranches # List branches for a single HEAD commit # # @param repo [Integer, String, Hash, Repository] A GitHub repos...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/markdown.rb
lib/octokit/client/markdown.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Markdown API # # @see https://developer.github.com/v3/markdown/ module Markdown # Render an arbitrary Markdown document # # @param text [String] Markdown source # @option options [String] (optional) :m...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/code_scanning.rb
lib/octokit/client/code_scanning.rb
# frozen_string_literal: true require 'tempfile' require 'zlib' module Octokit class Client # Methods for the code scanning alerts API # # @see https://docs.github.com/rest/code-scanning module CodeScanning # Updates a code scanning default setup configuration # # @param repo [Inte...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/service_status.rb
lib/octokit/client/service_status.rb
# frozen_string_literal: true module Octokit class Client # Methods for the GitHub Status API # # @see https://status.github.com/api module ServiceStatus # Root for status API # @private SUMMARY_ROOT = 'https://www.githubstatus.com/api/v2/summary.json' STATUS_ROOT = 'ht...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/say.rb
lib/octokit/client/say.rb
# frozen_string_literal: true module Octokit class Client # Methods for the unpublished Octocat API module Say # Return a nifty ASCII Octocat with GitHub wisdom # or your own # # @return [String] def say(text = nil, options = {}) options[:s] = text if text get 'o...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/commit_comments.rb
lib/octokit/client/commit_comments.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Commit Comments API # # @see https://developer.github.com/v3/repos/comments/ module CommitComments # List all commit comments # # @param repo [Integer, String, Hash, Repository] A GitHub repository # @...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/gitignore.rb
lib/octokit/client/gitignore.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Gitignore API # # @see https://developer.github.com/v3/gitignore/ module Gitignore # Listing available gitignore templates. # # These templates can be passed option when creating a repository. # ...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/reviews.rb
lib/octokit/client/reviews.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Reviews API # # @see https://developer.github.com/v3/pulls/reviews/ module Reviews # List reviews on a pull request # # @param repo [Integer, String, Hash, Repository] A GitHub repository # @param numb...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/notifications.rb
lib/octokit/client/notifications.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Notifications API # # @see https://developer.github.com/v3/activity/notifications/ module Notifications # List your notifications # # @param options [Hash] Optional parameters # @option options [Boolea...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/gists.rb
lib/octokit/client/gists.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Gists API # # @see https://developer.github.com/v3/gists/ module Gists # List gists for a user or all public gists # # @param user [String] An optional user to filter listing # @return [Array<Sawyer::R...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/pages.rb
lib/octokit/client/pages.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Pages API # # @see https://developer.github.com/v3/repos/pages/ module Pages # List Pages information for a repository # # @param repo [Integer, String, Repository, Hash] A GitHub repository # @return ...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/environments.rb
lib/octokit/client/environments.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Environments API # # @see https://docs.github.com/en/rest/deployments/environments module Environments # Fetch a single environment for a repository # # @param repo [Integer, String, Repository, Hash] A GitH...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/apps.rb
lib/octokit/client/apps.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Apps API module Apps # Get the authenticated App # # @param options [Hash] A customizable set of options # # @see https://docs.github.com/en/rest/apps/apps#get-the-authenticated-app # # @retu...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/commits.rb
lib/octokit/client/commits.rb
# frozen_string_literal: true require 'date' module Octokit class Client # Methods for the Commits API # # @see https://developer.github.com/v3/repos/commits/ module Commits # List commits # # @overload commits(repo, sha_or_branch, options = {}) # @deprecated # @par...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/actions_workflow_runs.rb
lib/octokit/client/actions_workflow_runs.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Actions Workflows runs API # # @see https://docs.github.com/rest/actions/workflow-runs module ActionsWorkflowRuns # List all runs for a repository workflow # # @param repo [Integer, String, Repository, Hash]...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/actions_workflow_jobs.rb
lib/octokit/client/actions_workflow_jobs.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Actions Workflows jobs API # # @see https://docs.github.com/rest/actions/workflow-jobs module ActionsWorkflowJobs # Get a job for a workflow run # # @param repo [Integer, String, Repository, Hash] A GitHub r...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/community_profile.rb
lib/octokit/client/community_profile.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Community Profile API # # @see https://developer.github.com/v3/repos/community/ module CommunityProfile # Get community profile metrics for a repository # # @param repo [Integer, String, Hash, Repository] A ...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/labels.rb
lib/octokit/client/labels.rb
# frozen_string_literal: true require 'erb' module Octokit class Client # Methods for the Issue Labels API # # @see https://developer.github.com/v3/issues/labels/ module Labels # List available labels for a repository # # @param repo [Integer, String, Repository, Hash] A GitHub rep...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/oauth_applications.rb
lib/octokit/client/oauth_applications.rb
# frozen_string_literal: true module Octokit class Client # Methods for the OauthApplications API # # @see https://developer.github.com/v3/apps/oauth_applications module OauthApplications # Check if a token is valid. # # Applications can check if a token is valid without rate limits...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/checks.rb
lib/octokit/client/checks.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Checks API # # @see https://developer.github.com/v3/checks/ module Checks # Methods for Check Runs # # @see https://developer.github.com/v3/checks/runs/ # Create a check run # # @param rep...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/client/marketplace.rb
lib/octokit/client/marketplace.rb
# frozen_string_literal: true module Octokit class Client # Methods for the Marketplace Listing API # # @see https://developer.github.com/v3/apps/marketplace/ module Marketplace # List all plans for an app's marketplace listing # # @param options [Hash] A customizable set of options...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/enterprise_management_console_client/management_console.rb
lib/octokit/enterprise_management_console_client/management_console.rb
# frozen_string_literal: true module Octokit class EnterpriseManagementConsoleClient # Methods for the Enterprise Management Console API # # @see https://developer.github.com/v3/enterprise-admin/management_console/ module ManagementConsole # Uploads a license for the first time # # ...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/response/raise_error.rb
lib/octokit/response/raise_error.rb
# frozen_string_literal: true require 'octokit/response/base_middleware' require 'octokit/error' module Octokit # Faraday response middleware module Response # This class raises an Octokit-flavored exception based # HTTP status codes returned by the API class RaiseError < BaseMiddleware def on_c...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/response/base_middleware.rb
lib/octokit/response/base_middleware.rb
# frozen_string_literal: true require 'faraday' module Octokit module Response # In Faraday 2.x, Faraday::Response::Middleware was removed BaseMiddleware = defined?(Faraday::Response::Middleware) ? Faraday::Response::Middleware : Faraday::Middleware end end
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/octokit/response/feed_parser.rb
lib/octokit/response/feed_parser.rb
# frozen_string_literal: true require 'octokit/response/base_middleware' module Octokit module Response # Parses RSS and Atom feed responses. class FeedParser < BaseMiddleware def on_complete(env) if env[:response_headers]['content-type'] =~ /(\batom|\brss)/ require 'rss' e...
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
octokit/octokit.rb
https://github.com/octokit/octokit.rb/blob/ea3413c3174571e87c83d358fc893cc7613091fa/lib/ext/sawyer/relation.rb
lib/ext/sawyer/relation.rb
# frozen_string_literal: true require 'sawyer' patch = Module.new do def href(options = nil) # Temporary workaround for: https://github.com/octokit/octokit.rb/issues/727 name.to_s == 'ssh' ? @href : super end end Sawyer::Relation.send(:prepend, patch)
ruby
MIT
ea3413c3174571e87c83d358fc893cc7613091fa
2026-01-04T15:47:59.787784Z
false
openblockchains/awesome-blockchains
https://github.com/openblockchains/awesome-blockchains/blob/ffc699a7542a8536c44d34f923368d0f09ad1ff4/merkletree.rb/merkletree.rb
merkletree.rb/merkletree.rb
############################################################### # calc(ulate) your own merkle tree hash from scratch in ruby # # inspired by building a merkle tree (in c++) in the book # Mastering Bitcoin - Programming the Open Blockchain by Andreas M. Antonopoulos # see https://github.com/bitcoinbook/bitcoinbo...
ruby
CC0-1.0
ffc699a7542a8536c44d34f923368d0f09ad1ff4
2026-01-04T15:48:47.458795Z
false
openblockchains/awesome-blockchains
https://github.com/openblockchains/awesome-blockchains/blob/ffc699a7542a8536c44d34f923368d0f09ad1ff4/blockchain.rb/blockchain_with_proof_of_work.rb
blockchain.rb/blockchain_with_proof_of_work.rb
########################### # build your own blockchain from scratch in ruby! # # to run use: # $ ruby ./blockchain_with_proof_of_work.rb require "digest" # for hash checksum digest function SHA256 require "pp" # for pp => pretty printer class Block attr_reader :index attr_reader :timestamp at...
ruby
CC0-1.0
ffc699a7542a8536c44d34f923368d0f09ad1ff4
2026-01-04T15:48:47.458795Z
false
openblockchains/awesome-blockchains
https://github.com/openblockchains/awesome-blockchains/blob/ffc699a7542a8536c44d34f923368d0f09ad1ff4/blockchain.rb/blockchain_with_transactions.rb
blockchain.rb/blockchain_with_transactions.rb
########################### # build your own blockchain from scratch in 20 lines of ruby! # # to run use: # $ ruby ./blockchain_with_transactions.rb # # transactions (hyper) ledger / book: # # from: Dutchgrown to: Vincent what: Tulip Bloemendaal Sunset qty: 10 # from: Keukenhof to: Anne ...
ruby
CC0-1.0
ffc699a7542a8536c44d34f923368d0f09ad1ff4
2026-01-04T15:48:47.458795Z
false
openblockchains/awesome-blockchains
https://github.com/openblockchains/awesome-blockchains/blob/ffc699a7542a8536c44d34f923368d0f09ad1ff4/blockchain.rb/blockchain.rb
blockchain.rb/blockchain.rb
########################### # build your own blockchain from scratch in 20 lines of ruby! # # inspired by # Let's Build the Tiniest Blockchain In Less Than 50 Lines of Python by Gerald Nash # see https://medium.com/crypto-currently/lets-build-the-tiniest-blockchain-e70965a248b # # # to run use: # $ ruby ...
ruby
CC0-1.0
ffc699a7542a8536c44d34f923368d0f09ad1ff4
2026-01-04T15:48:47.458795Z
false
solnic/virtus
https://github.com/solnic/virtus/blob/fce56bd6676d767f287e4051176d3d323e48902f/spec/spec_helper.rb
spec/spec_helper.rb
if RUBY_ENGINE == 'ruby' && RUBY_VERSION >= '3.0' require 'simplecov' SimpleCov.start end require 'rspec' require 'bogus/rspec' require 'virtus' module Virtus def self.warn(*) # shut up in tests end end ENV['TZ'] = 'UTC' # require spec support files and shared behavior Dir[File.expand_path('../shared/**...
ruby
MIT
fce56bd6676d767f287e4051176d3d323e48902f
2026-01-04T15:48:55.548896Z
false
solnic/virtus
https://github.com/solnic/virtus/blob/fce56bd6676d767f287e4051176d3d323e48902f/spec/integration/mass_assignment_with_accessors_spec.rb
spec/integration/mass_assignment_with_accessors_spec.rb
require 'spec_helper' describe "mass assignment with accessors" do before do module Examples class Product include Virtus attribute :id, Integer attribute :category, String attribute :subcategory, String def categories=(categories) self.categ...
ruby
MIT
fce56bd6676d767f287e4051176d3d323e48902f
2026-01-04T15:48:55.548896Z
false
solnic/virtus
https://github.com/solnic/virtus/blob/fce56bd6676d767f287e4051176d3d323e48902f/spec/integration/collection_member_coercion_spec.rb
spec/integration/collection_member_coercion_spec.rb
require 'spec_helper' # TODO: refactor to make it inline with the new style of integration specs class Address include Virtus attribute :address, String attribute :locality, String attribute :region, String attribute :postal_code, String end class PhoneNumber include Virtus attribute :num...
ruby
MIT
fce56bd6676d767f287e4051176d3d323e48902f
2026-01-04T15:48:55.548896Z
false
solnic/virtus
https://github.com/solnic/virtus/blob/fce56bd6676d767f287e4051176d3d323e48902f/spec/integration/extending_objects_spec.rb
spec/integration/extending_objects_spec.rb
require 'spec_helper' describe 'I can extend objects' do before do module Examples class User; end class Admin; end end end specify 'defining attributes on an object' do attributes = { :name => 'John', :age => 29 } admin = Examples::Admin.new admin.extend(Virtus) admin.att...
ruby
MIT
fce56bd6676d767f287e4051176d3d323e48902f
2026-01-04T15:48:55.548896Z
false
solnic/virtus
https://github.com/solnic/virtus/blob/fce56bd6676d767f287e4051176d3d323e48902f/spec/integration/required_attributes_spec.rb
spec/integration/required_attributes_spec.rb
require 'spec_helper' describe 'Using required attributes' do before do module Examples class User include Virtus.model(:strict => true) attribute :name, String attribute :age, Integer, :required => false end end end it 'raises coercion error when required attribute...
ruby
MIT
fce56bd6676d767f287e4051176d3d323e48902f
2026-01-04T15:48:55.548896Z
false
solnic/virtus
https://github.com/solnic/virtus/blob/fce56bd6676d767f287e4051176d3d323e48902f/spec/integration/embedded_value_spec.rb
spec/integration/embedded_value_spec.rb
require 'spec_helper' describe 'embedded values' do before do module Examples class City include Virtus.model attribute :name, String end class Address include Virtus.model attribute :street, String attribute :zipcode, String attribute :city, ...
ruby
MIT
fce56bd6676d767f287e4051176d3d323e48902f
2026-01-04T15:48:55.548896Z
false
solnic/virtus
https://github.com/solnic/virtus/blob/fce56bd6676d767f287e4051176d3d323e48902f/spec/integration/injectible_coercers_spec.rb
spec/integration/injectible_coercers_spec.rb
require 'virtus' describe 'Injectible coercer' do before do module Examples class EmailAddress include Virtus.value_object values do attribute :address, String, :coercer => lambda { |add| add.downcase } end def self.coerce(input) if input.is_a?(String) ...
ruby
MIT
fce56bd6676d767f287e4051176d3d323e48902f
2026-01-04T15:48:55.548896Z
false
solnic/virtus
https://github.com/solnic/virtus/blob/fce56bd6676d767f287e4051176d3d323e48902f/spec/integration/overriding_virtus_spec.rb
spec/integration/overriding_virtus_spec.rb
require 'spec_helper' describe 'overriding virtus behavior' do before do module Examples class Article include Virtus attribute :title, String def title super || '<unknown>' end def title=(name) super unless self.title == "can't be changed" ...
ruby
MIT
fce56bd6676d767f287e4051176d3d323e48902f
2026-01-04T15:48:55.548896Z
false
solnic/virtus
https://github.com/solnic/virtus/blob/fce56bd6676d767f287e4051176d3d323e48902f/spec/integration/inheritance_spec.rb
spec/integration/inheritance_spec.rb
require 'spec_helper' describe 'Inheritance' do before do module Examples class Base include Virtus.model end class First < Base attribute :id, Fixnum attribute :name, String, default: ->(first, _) { "Named: #{first.id}" } attribute :description, String en...
ruby
MIT
fce56bd6676d767f287e4051176d3d323e48902f
2026-01-04T15:48:55.548896Z
false
solnic/virtus
https://github.com/solnic/virtus/blob/fce56bd6676d767f287e4051176d3d323e48902f/spec/integration/hash_attributes_coercion_spec.rb
spec/integration/hash_attributes_coercion_spec.rb
require 'spec_helper' class Package include Virtus attribute :dimensions, Hash[Symbol => Float] attribute :meta_info , Hash[String => String] end describe Package do let(:instance) do described_class.new( :dimensions => { 'width' => "2.2", :height => 2, "length" => 4.5 }, :meta_info => { '...
ruby
MIT
fce56bd6676d767f287e4051176d3d323e48902f
2026-01-04T15:48:55.548896Z
false
solnic/virtus
https://github.com/solnic/virtus/blob/fce56bd6676d767f287e4051176d3d323e48902f/spec/integration/value_object_with_custom_constructor_spec.rb
spec/integration/value_object_with_custom_constructor_spec.rb
require 'spec_helper' describe "Defining a ValueObject with a custom constructor" do before do module Examples class Point include Virtus::ValueObject attribute :x, Integer attribute :y, Integer def initialize(attributes) if attributes.kind_of?(Array) ...
ruby
MIT
fce56bd6676d767f287e4051176d3d323e48902f
2026-01-04T15:48:55.548896Z
false
solnic/virtus
https://github.com/solnic/virtus/blob/fce56bd6676d767f287e4051176d3d323e48902f/spec/integration/building_module_spec.rb
spec/integration/building_module_spec.rb
require 'spec_helper' describe 'I can create a Virtus module' do before do module Examples NoncoercingModule = Virtus.model { |config| config.coerce = false } CoercingModule = Virtus.model { |config| config.coerce = true config.coercer do |coercer| coercer.st...
ruby
MIT
fce56bd6676d767f287e4051176d3d323e48902f
2026-01-04T15:48:55.548896Z
false
solnic/virtus
https://github.com/solnic/virtus/blob/fce56bd6676d767f287e4051176d3d323e48902f/spec/integration/attributes_attribute_spec.rb
spec/integration/attributes_attribute_spec.rb
require 'spec_helper' describe "Adding attribute called 'attributes'" do context "when mass assignment is disabled" do before do module Examples class User include Virtus.model(mass_assignment: false) attribute :attributes end end end it "allows model to...
ruby
MIT
fce56bd6676d767f287e4051176d3d323e48902f
2026-01-04T15:48:55.548896Z
false
solnic/virtus
https://github.com/solnic/virtus/blob/fce56bd6676d767f287e4051176d3d323e48902f/spec/integration/default_values_spec.rb
spec/integration/default_values_spec.rb
require 'spec_helper' describe "default values" do before do module Examples class Reference include Virtus::ValueObject attribute :ref, String end class Page include Virtus attribute :title, String attribute :slug, String, :default =...
ruby
MIT
fce56bd6676d767f287e4051176d3d323e48902f
2026-01-04T15:48:55.548896Z
false
solnic/virtus
https://github.com/solnic/virtus/blob/fce56bd6676d767f287e4051176d3d323e48902f/spec/integration/defining_attributes_spec.rb
spec/integration/defining_attributes_spec.rb
require 'spec_helper' describe "virtus attribute definitions" do before do module Examples class Person include Virtus attribute :name, String attribute :age, Integer attribute :doctor, Boolean attribute :salary, Decimal end class Manager < Person ...
ruby
MIT
fce56bd6676d767f287e4051176d3d323e48902f
2026-01-04T15:48:55.548896Z
false
solnic/virtus
https://github.com/solnic/virtus/blob/fce56bd6676d767f287e4051176d3d323e48902f/spec/integration/custom_attributes_spec.rb
spec/integration/custom_attributes_spec.rb
require 'spec_helper' describe 'custom attributes' do before do module Examples class NoisyString < Virtus::Attribute lazy true def coerce(input) input.to_s.upcase end end class RegularExpression < Virtus::Attribute primitive Regexp end ...
ruby
MIT
fce56bd6676d767f287e4051176d3d323e48902f
2026-01-04T15:48:55.548896Z
false
solnic/virtus
https://github.com/solnic/virtus/blob/fce56bd6676d767f287e4051176d3d323e48902f/spec/integration/struct_as_embedded_value_spec.rb
spec/integration/struct_as_embedded_value_spec.rb
require 'spec_helper' describe 'Using Struct as an embedded value attribute' do before do module Examples Point = Struct.new(:x, :y) class Rectangle include Virtus attribute :top_left, Point attribute :bottom_right, Point end end end subject do Example...
ruby
MIT
fce56bd6676d767f287e4051176d3d323e48902f
2026-01-04T15:48:55.548896Z
false
solnic/virtus
https://github.com/solnic/virtus/blob/fce56bd6676d767f287e4051176d3d323e48902f/spec/integration/using_modules_spec.rb
spec/integration/using_modules_spec.rb
require 'spec_helper' describe 'I can define attributes within a module' do before do module Examples module Common include Virtus end module Name include Common attribute :name, String attribute :gamer, Boolean end module Age include Commo...
ruby
MIT
fce56bd6676d767f287e4051176d3d323e48902f
2026-01-04T15:48:55.548896Z
false
solnic/virtus
https://github.com/solnic/virtus/blob/fce56bd6676d767f287e4051176d3d323e48902f/spec/integration/custom_collection_attributes_spec.rb
spec/integration/custom_collection_attributes_spec.rb
require 'spec_helper' describe 'custom collection attributes' do let(:library) { Examples::Library.new } let(:books) { library.books } before do module Examples end Examples.const_set 'BookCollection', book_collection_class module Examples class Book include Virtus attribut...
ruby
MIT
fce56bd6676d767f287e4051176d3d323e48902f
2026-01-04T15:48:55.548896Z
false
solnic/virtus
https://github.com/solnic/virtus/blob/fce56bd6676d767f287e4051176d3d323e48902f/spec/integration/virtus/value_object_spec.rb
spec/integration/virtus/value_object_spec.rb
require 'spec_helper' describe Virtus::ValueObject do let(:class_under_test) do Class.new do def self.name 'GeoLocation' end include Virtus::ValueObject attribute :latitude, Float attribute :longitude, Float end end let(:attribute_values) { { :latitude => 10.0, :...
ruby
MIT
fce56bd6676d767f287e4051176d3d323e48902f
2026-01-04T15:48:55.548896Z
false
solnic/virtus
https://github.com/solnic/virtus/blob/fce56bd6676d767f287e4051176d3d323e48902f/spec/integration/virtus/instance_level_attributes_spec.rb
spec/integration/virtus/instance_level_attributes_spec.rb
require 'spec_helper' describe Virtus, 'instance level attributes' do subject do subject = Object.new subject.singleton_class.send(:include, Virtus) subject end let(:attribute) { subject.singleton_class.attribute(:name, String) } before do pending if RUBY_VERSION < '1.9' end context 'add...
ruby
MIT
fce56bd6676d767f287e4051176d3d323e48902f
2026-01-04T15:48:55.548896Z
false