source stringclasses 1
value | repo stringlengths 5 63 | repo_url stringlengths 24 82 | path stringlengths 5 167 | language stringclasses 1
value | license stringclasses 5
values | stars int64 10 51.4k | ref stringclasses 23
values | size_bytes int64 200 258k | text stringlengths 137 258k |
|---|---|---|---|---|---|---|---|---|---|
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/http.rb | Ruby | mit | 203 | master | 3,841 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'rainbow'
require 'uri'
require 'backtrace'
require 'zold/score'
require 'typhoeus'
require_relative 'version'
# HTTP page.
# Author:: Yegor Bugayenko (yegor256@gmail.com)
# Copyright:: Co... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/gem.rb | Ruby | mit | 203 | master | 621 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'uri'
require 'zold/score'
require_relative 'json_page'
require_relative 'http'
# Class representing the Zold gem on Rubygems
# Author:: Yegor Bugayenko (yegor256@gmail.com)
# Copyright:: ... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/dir_items.rb | Ruby | mit | 203 | master | 892 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'shellwords'
# Items in a directory.
#
# We need this class because Dir.new() from Ruby is blocking. It doesn't
# allow to write and read to any files in a directory, while listing it.
# M... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/verbose_thread.rb | Ruby | mit | 203 | master | 924 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'backtrace'
require 'get_process_mem'
require 'loog'
require_relative 'size'
# Verbose thread.
# Author:: Yegor Bugayenko (yegor256@gmail.com)
# Copyright:: Copyright (c) 2018-2026 Zerocra... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/head.rb | Ruby | mit | 203 | master | 1,133 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require_relative 'txn'
# Head of a wallet.
# Author:: Yegor Bugayenko (yegor256@gmail.com)
# Copyright:: Copyright (c) 2018-2026 Zerocracy
# License:: MIT
module Zold
# Head of the wallet.
cla... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/prefixes.rb | Ruby | mit | 203 | master | 780 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require_relative 'key'
# Payment prefixes.
#
# Author:: Yegor Bugayenko (yegor256@gmail.com)
# Copyright:: Copyright (c) 2018-2026 Zerocracy
# License:: MIT
module Zold
# Payment prefixes
clas... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/id.rb | Ruby | mit | 203 | master | 1,554 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'csv'
require 'securerandom'
# The ID of the wallet.
# Author:: Yegor Bugayenko (yegor256@gmail.com)
# Copyright:: Copyright (c) 2018-2026 Zerocracy
# License:: MIT
module Zold
# Id of t... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/hands.rb | Ruby | mit | 203 | master | 2,236 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'concurrent'
require 'total'
require_relative 'thread_pool'
require 'loog'
require_relative 'endless'
# Multiple threads that can do something useful together.
# Author:: Yegor Bugayenko (... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/endless.rb | Ruby | mit | 203 | master | 762 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'loog'
require_relative 'verbose_thread'
require_relative 'age'
# Endless loop.
# Author:: Yegor Bugayenko (yegor256@gmail.com)
# Copyright:: Copyright (c) 2018-2026 Zerocracy
# License:: ... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/tax.rb | Ruby | mit | 203 | master | 3,214 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require_relative 'key'
require_relative 'id'
require_relative 'wallet'
require_relative 'amount'
# Tax transaction.
#
# Author:: Yegor Bugayenko (yegor256@gmail.com)
# Copyright:: Copyright (c) 20... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/cached_wallets.rb | Ruby | mit | 203 | master | 959 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'zache'
require 'delegate'
require_relative 'endless'
require_relative 'thread_pool'
# Cached collection of wallets.
# Author:: Yegor Bugayenko (yegor256@gmail.com)
# Copyright:: Copyright... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/patch.rb | Ruby | mit | 203 | master | 7,561 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'openssl'
require 'loog'
require_relative 'wallet'
require_relative 'signature'
# Patch.
#
# Author:: Yegor Bugayenko (yegor256@gmail.com)
# Copyright:: Copyright (c) 2018-2026 Zerocracy
#... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/json_page.rb | Ruby | mit | 203 | master | 987 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'json'
# JSON page.
# Author:: Yegor Bugayenko (yegor256@gmail.com)
# Copyright:: Copyright (c) 2018-2026 Zerocracy
# License:: MIT
module Zold
# JSON page
class JsonPage
# When ca... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/size.rb | Ruby | mit | 203 | master | 699 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'time'
# Size in bytes.
# Author:: Yegor Bugayenko (yegor256@gmail.com)
# Copyright:: Copyright (c) 2018-2026 Zerocracy
# License:: MIT
module Zold
# Size
class Size
def initialize... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/signature.rb | Ruby | mit | 203 | master | 1,609 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require_relative 'key'
require_relative 'id'
require_relative 'amount'
require_relative 'txn'
# The signature of a transaction.
#
# Author:: Yegor Bugayenko (yegor256@gmail.com)
# Copyright:: Copy... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/version_file.rb | Ruby | mit | 203 | master | 611 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'semantic'
require 'loog'
module Zold
# Read and write .zoldata/version.
class VersionFile
def initialize(path, log: Loog::NULL)
@path = path
@log = log
end
# ... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/hungry_wallets.rb | Ruby | mit | 203 | master | 2,442 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'delegate'
require 'zache'
require 'shellwords'
require 'loog'
require_relative 'thread_pool'
require_relative 'commands/pull'
require_relative 'commands/fetch'
# Wallets that PULL what's ... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/upgrades.rb | Ruby | mit | 203 | master | 1,203 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'loog'
module Zold
# Class to manage data upgrades (when zold itself upgrades).
class Upgrades
def initialize(version, directory, opts, log: Loog::NULL)
raise 'network can\'t... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/amount.rb | Ruby | mit | 203 | master | 3,094 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'rainbow'
# The amount.
# Author:: Yegor Bugayenko (yegor256@gmail.com)
# Copyright:: Copyright (c) 2018-2026 Zerocracy
# License:: MIT
module Zold
# Amount
class Amount
# Maximum ... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/sync_wallets.rb | Ruby | mit | 203 | master | 867 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'futex'
require 'delegate'
require 'loog'
# Synchronized collection of wallets.
#
# This is a decorator for the Wallets class.
#
# Author:: Yegor Bugayenko (yegor256@gmail.com)
# Copyright... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/commands/taxes.rb | Ruby | mit | 203 | master | 6,547 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'slop'
require 'json'
require 'rainbow'
require 'zold/score'
require_relative 'thread_badge'
require_relative 'args'
require_relative 'pay'
require 'loog'
require_relative '../json_page'
re... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/commands/remote.rb | Ruby | mit | 203 | master | 13,212 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'slop'
require 'semantic'
require 'rainbow'
require 'net/http'
require 'json'
require 'time'
require 'zold/score'
require_relative 'thread_badge'
require_relative 'args'
require_relative '.... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/commands/clean.rb | Ruby | mit | 203 | master | 2,043 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'uri'
require 'json'
require 'time'
require 'futex'
require 'slop'
require 'rainbow'
require 'zold/score'
require_relative 'args'
require_relative '../age'
require_relative '../size'
requir... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/commands/create.rb | Ruby | mit | 203 | master | 2,363 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'slop'
require 'rainbow'
require_relative 'thread_badge'
require_relative 'args'
require_relative '../wallet'
require 'loog'
require_relative '../id'
# CREATE command.
# Author:: Yegor Bug... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/commands/node.rb | Ruby | mit | 203 | master | 19,171 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'open3'
require 'slop'
require 'shellwords'
require 'backtrace'
require 'fileutils'
require 'zache'
require 'concurrent'
require 'zold/score'
require_relative 'thread_badge'
require_relativ... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/commands/merge.rb | Ruby | mit | 203 | master | 6,679 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'slop'
require 'rainbow'
require 'backtrace'
require 'shellwords'
require_relative 'thread_badge'
require_relative 'args'
require_relative 'pull'
require_relative '../age'
require 'loog'
re... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/commands/calculate.rb | Ruby | mit | 203 | master | 2,531 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'slop'
require 'zold/score'
require_relative 'thread_badge'
require 'loog'
# SCORE command.
# Author:: Yegor Bugayenko (yegor256@gmail.com)
# Copyright:: Copyright (c) 2018-2026 Zerocracy
... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/commands/list.rb | Ruby | mit | 203 | master | 1,214 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require_relative 'thread_badge'
require 'loog'
require_relative '../amount'
require_relative '../wallet'
require_relative '../size'
# LIST command.
# Author:: Yegor Bugayenko (yegor256@gmail.com)
... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/commands/push.rb | Ruby | mit | 203 | master | 5,498 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'rainbow'
require 'slop'
require 'json'
require 'net/http'
require 'concurrent'
require_relative 'thread_badge'
require_relative 'args'
require_relative '../thread_pool'
require_relative '.... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/commands/invoice.rb | Ruby | mit | 203 | master | 2,181 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'slop'
require 'shellwords'
require_relative 'thread_badge'
require_relative 'args'
require 'loog'
require_relative '../prefixes'
# INVOICE command.
# Author:: Yegor Bugayenko (yegor256@gm... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/commands/pay.rb | Ruby | mit | 203 | master | 6,473 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'slop'
require 'rainbow'
require 'shellwords'
require_relative 'thread_badge'
require_relative 'args'
require_relative '../id'
require_relative '../amount'
require 'loog'
# PAY command.
# ... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/commands/next.rb | Ruby | mit | 203 | master | 1,144 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'slop'
require 'zold/score'
require_relative 'thread_badge'
require 'loog'
# NEXT command.
# Author:: Yegor Bugayenko (yegor256@gmail.com)
# Copyright:: Copyright (c) 2018-2026 Zerocracy
#... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/commands/routines.rb | Ruby | mit | 203 | master | 273 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
# Routines.
# Author:: Yegor Bugayenko (yegor256@gmail.com)
# Copyright:: Copyright (c) 2018-2026 Zerocracy
# License:: MIT
module Zold::Routines
end |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/commands/remove.rb | Ruby | mit | 203 | master | 1,401 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'slop'
require 'rainbow'
require_relative 'thread_badge'
require_relative 'args'
require 'loog'
# REMOVe command.
# Author:: Yegor Bugayenko (yegor256@gmail.com)
# Copyright:: Copyright (c... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/commands/propagate.rb | Ruby | mit | 203 | master | 2,625 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'slop'
require 'rainbow'
require_relative 'thread_badge'
require_relative 'args'
require 'loog'
require_relative '../age'
require_relative '../wallet'
require_relative '../wallets'
require_... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/commands/thread_badge.rb | Ruby | mit | 203 | master | 1,027 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
# Thread badge.
# Author:: Yegor Bugayenko (yegor256@gmail.com)
# Copyright:: Copyright (c) 2018-2026 Zerocracy
# License:: MIT
module Zold
# This module should be included in each command, in or... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/commands/args.rb | Ruby | mit | 203 | master | 710 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'slop'
require 'json'
require 'net/http'
require 'loog'
require_relative '../id'
require_relative '../http'
# Args.
# Author:: Yegor Bugayenko (yegor256@gmail.com)
# Copyright:: Copyright ... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/commands/diff.rb | Ruby | mit | 203 | master | 1,800 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'tempfile'
require 'slop'
require 'diffy'
require 'rainbow'
require_relative 'thread_badge'
require_relative 'args'
require 'loog'
require_relative '../patch'
require_relative '../wallet'
... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/commands/alias.rb | Ruby | mit | 203 | master | 1,293 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'slop'
require 'rainbow'
require_relative 'thread_badge'
require_relative 'args'
require 'loog'
module Zold
# Command to set an alias for wallet ID
class Alias
prepend ThreadBadge
... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/commands/fetch.rb | Ruby | mit | 203 | master | 7,288 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'uri'
require 'json'
require 'time'
require 'tempfile'
require 'slop'
require 'openssl'
require 'rainbow'
require 'concurrent/atomics'
require 'zold/score'
require 'concurrent'
require_rela... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/commands/show.rb | Ruby | mit | 203 | master | 2,247 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'slop'
require 'rainbow'
require_relative 'thread_badge'
require_relative 'args'
require 'loog'
require_relative '../id'
require_relative '../amount'
require_relative '../wallet'
require_re... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/commands/pull.rb | Ruby | mit | 203 | master | 921 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require_relative 'thread_badge'
require 'loog'
require_relative 'fetch'
require_relative 'merge'
require_relative 'clean'
# PULL command.
# Author:: Yegor Bugayenko (yegor256@gmail.com)
# Copyrigh... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/commands/routines/retire.rb | Ruby | mit | 203 | master | 889 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'shellwords'
require_relative '../routines'
require_relative '../remote'
require_relative '../../node/farm'
# Kill the node if it's too old.
# Author:: Yegor Bugayenko (yegor256@gmail.com)... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/commands/routines/gc.rb | Ruby | mit | 203 | master | 1,094 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require_relative '../routines'
require 'loog'
require_relative '../remove'
# Garbage collecting. It goes through the list of all wallets and removes
# those that are older than 10 days and don't h... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/commands/routines/spread.rb | Ruby | mit | 203 | master | 989 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'shellwords'
require_relative '../routines'
require 'loog'
require_relative '../../id'
require_relative '../../copies'
require_relative '../push'
# Spread random wallets to the network.
# ... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/commands/routines/reconnect.rb | Ruby | mit | 203 | master | 2,058 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'shellwords'
require_relative '../routines'
require_relative '../remote'
require_relative '../../node/farm'
# Reconnect routine.
# Author:: Yegor Bugayenko (yegor256@gmail.com)
# Copyright... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/commands/routines/reconcile.rb | Ruby | mit | 203 | master | 1,499 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'shellwords'
require_relative '../routines'
require 'loog'
require_relative '../../id'
require_relative '../../copies'
require_relative '../pull'
# R
# Author:: Yegor Bugayenko (yegor256@g... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/commands/routines/audit.rb | Ruby | mit | 203 | master | 808 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'get_process_mem'
require_relative '../routines'
require_relative '../../size'
# Audit and report as much as we can to the command line.
# Author:: Yegor Bugayenko (yegor256@gmail.com)
# C... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/node/trace.rb | Ruby | mit | 203 | master | 1,042 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
# The web front of the node.
# Author:: Yegor Bugayenko (yegor256@gmail.com)
# Copyright:: Copyright (c) 2018-2026 Zerocracy
# License:: MIT
module Zold
# Log that traces everything
class Trace... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/node/safe_entrance.rb | Ruby | mit | 203 | master | 2,213 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'concurrent'
require 'tempfile'
require_relative 'soft_error'
require_relative '../remotes'
require_relative '../copies'
require_relative '../tax'
require_relative '../commands/merge'
requi... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/node/spread_entrance.rb | Ruby | mit | 203 | master | 2,790 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'concurrent'
require 'tempfile'
require 'shellwords'
require 'loog'
require_relative '../remotes'
require_relative '../copies'
require_relative '../endless'
require_relative '../tax'
requir... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/node/async_entrance.rb | Ruby | mit | 203 | master | 3,459 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'concurrent'
require 'futex'
require 'securerandom'
require_relative '../age'
require_relative '../size'
require_relative '../id'
require_relative '../endless'
require_relative '../thread_p... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/node/nodup_entrance.rb | Ruby | mit | 203 | master | 1,214 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'tempfile'
require 'openssl'
require 'loog'
require_relative '../size'
require_relative '../wallet'
# The entrance that ignores duplicates.
# Author:: Yegor Bugayenko (yegor256@gmail.com)
... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/node/entrance.rb | Ruby | mit | 203 | master | 1,525 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'tempfile'
require 'time'
require 'loog'
# The entrance of the web front.
# Author:: Yegor Bugayenko (yegor256@gmail.com)
# Copyright:: Copyright (c) 2018-2026 Zerocracy
# License:: MIT
mo... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/node/soft_error.rb | Ruby | mit | 203 | master | 342 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
# Soft error.
# Author:: Yegor Bugayenko (yegor256@gmail.com)
# Copyright:: Copyright (c) 2018-2026 Zerocracy
# License:: MIT
module Zold
# Soft error
class SoftError < StandardError
# Noth... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/node/nospam_entrance.rb | Ruby | mit | 203 | master | 1,405 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'tempfile'
require 'openssl'
require 'zache'
require 'loog'
require_relative '../size'
require_relative '../age'
# The entrance that ignores something we've seen already.
# Author:: Yegor ... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/node/farmers.rb | Ruby | mit | 203 | master | 3,749 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'open3'
require 'backtrace'
require 'zold/score'
require 'shellwords'
require 'loog'
require_relative '../age'
# Farmers.
# Author:: Yegor Bugayenko (yegor256@gmail.com)
# Copyright:: Copy... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/node/pipeline.rb | Ruby | mit | 203 | master | 3,168 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'tempfile'
require 'shellwords'
require 'loog'
require_relative '../remotes'
require_relative '../copies'
require_relative '../tax'
require_relative '../age'
require_relative '../commands/c... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/node/farm.rb | Ruby | mit | 203 | master | 6,280 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'time'
require 'open3'
require 'backtrace'
require 'futex'
require 'concurrent'
require 'json'
require 'zold/score'
require 'loog'
require_relative '../thread_pool'
require_relative '../age... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/node/front.rb | Ruby | mit | 203 | master | 19,190 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
$stdout.sync = true
require 'get_process_mem'
require 'thin'
require 'haml'
require 'shellwords'
require 'json'
require 'digest'
require 'sinatra/base'
require 'concurrent'
require 'backtrace'
req... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/node/sync_entrance.rb | Ruby | mit | 203 | master | 1,181 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'concurrent'
require 'futex'
require 'loog'
require_relative '../id'
require_relative '../verbose_thread'
# The sync entrance of the web front.
# Author:: Yegor Bugayenko (yegor256@gmail.c... |
github | zold-io/zold | https://github.com/zold-io/zold | lib/zold/node/journaled_pipeline.rb | Ruby | mit | 203 | master | 2,323 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'tempfile'
require 'diffy'
require 'fileutils'
require_relative 'pipeline'
require 'loog'
require 'loog/tee'
require 'logger'
require_relative '../age'
# The pipeline with journals.
# Auth... |
github | zold-io/zold | https://github.com/zold-io/zold | upgrades/rename_foreign_wallets.rb | Ruby | mit | 203 | master | 852 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'rainbow'
require_relative '../lib/zold/version'
require_relative '../lib/zold/wallet'
module Zold
# Rename wallets that belong to another network
class RenameForeignWallets
def in... |
github | zold-io/zold | https://github.com/zold-io/zold | upgrades/2.rb | Ruby | mit | 203 | master | 571 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
# https://github.com/zold-io/zold/issues/358
# rename all wallets from their current names into *.z
module Zold
# Upgrade to version 2
class UpgradeTo2
def initialize(home, log)
@hom... |
github | zold-io/zold | https://github.com/zold-io/zold | upgrades/move_wallets_into_tree.rb | Ruby | mit | 203 | master | 757 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'fileutils'
require_relative '../lib/zold/version'
require_relative '../lib/zold/wallet'
module Zold
# Move wallets into tree
class MoveWalletsIntoTree
def initialize(home, log)
... |
github | zold-io/zold | https://github.com/zold-io/zold | upgrades/delete_banned_wallets.rb | Ruby | mit | 203 | master | 825 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require 'rainbow'
require_relative '../lib/zold/version'
require_relative '../lib/zold/wallet'
module Zold
# Delete wallets which are in the banned-wallets.csv file
class DeleteBannedWallets
... |
github | zold-io/zold | https://github.com/zold-io/zold | upgrades/protocol_up.rb | Ruby | mit | 203 | master | 746 | # frozen_string_literal: true
# SPDX-FileCopyrightText: Copyright (c) 2018-2026 Zerocracy
# SPDX-License-Identifier: MIT
require_relative '../lib/zold/version'
require_relative '../lib/zold/wallet'
module Zold
# Upgrade protocol in each wallet
class ProtocolUp
def initialize(home, log)
@home = home
... |
github | choonkeat/attache | https://github.com/choonkeat/attache | Rakefile | Ruby | mit | 203 | master | 350 | if ENV['RACK_ENV'] == 'production'
# Heroku
# https://gist.github.com/Geesu/d0b58488cfae51f361c6
namespace :assets do
task 'precompile' do
puts "Not applicable"
end
end
else
require "bundler/gem_tasks"
require 'rspec/core/rake_task'
require 'attache/tasks'
RSpec::Core::RakeTask.new(:spec)... |
github | choonkeat/attache | https://github.com/choonkeat/attache | config.ru | Ruby | mit | 203 | master | 258 | require 'attache'
use Attache::Delete
use Attache::UploadUrl
use Attache::Upload
use Attache::Download
use Attache::Tus::Upload
use Attache::Backup
use Rack::Static, urls: ["/"], root: Attache.publicdir, index: "index.html"
run proc {|env| [200, {}, []] } |
github | choonkeat/attache | https://github.com/choonkeat/attache | attache.gemspec | Ruby | mit | 203 | master | 1,688 | $:.push File.expand_path("../lib", __FILE__)
# Maintain your gem's version:
require "attache/version"
# Describe your gem and declare its dependencies:
Gem::Specification.new do |s|
s.name = "attache"
s.version = Attache::VERSION
s.authors = ["choonkeat"]
s.email = ["choonkeat@gmail.com"]... |
github | choonkeat/attache | https://github.com/choonkeat/attache | docker/bundler_geminstaller_install_with_timeout.rb | Ruby | mit | 203 | master | 1,379 | # Usage:
# ruby bundler_geminstaller_install_with_timeout.rb
target = `which bundle`.chomp
*old_lines, last_line = IO.read(target).split(/[\r\n]+/)
if (old_lines.grep(/install_with_timeout/)).empty?
new_line = DATA.read.strip
combined = (old_lines + [new_line, last_line]).join($/)
open(target, "w") {|f| f.writ... |
github | choonkeat/attache | https://github.com/choonkeat/attache | spec/spec_helper.rb | Ruby | mit | 203 | master | 4,459 | ENV['VHOST'] = '{"0.0.0.0":{}}'
require 'attache.rb'
require 'sucker_punch/testing/inline'
# This file was generated by the `rspec --init` command. Conventionally, all
# specs live under a `spec` directory, which RSpec adds to the `$LOAD_PATH`.
# The generated `.rspec` file contains `--require spec_helper` which will... |
github | choonkeat/attache | https://github.com/choonkeat/attache | spec/lib/attache/delete_spec.rb | Ruby | mit | 203 | master | 4,885 | require 'spec_helper'
describe Attache::Delete do
let(:app) { ->(env) { [200, env, "app"] } }
let(:middleware) { Attache::Delete.new(app) }
let(:params) { {} }
let(:filename) { "hello#{rand}.gif" }
let(:reldirname) { "path#{rand}" }
let(:file) { StringIO.new(IO.binread("spec/fixtures/transparent.gif"), 'rb... |
github | choonkeat/attache | https://github.com/choonkeat/attache | spec/lib/attache/upload_spec.rb | Ruby | mit | 203 | master | 9,095 | require 'spec_helper'
describe Attache::Upload do
let(:app) { ->(env) { [200, env, "app"] } }
let(:middleware) { Attache::Upload.new(app) }
let(:params) { {} }
let(:filename) { "Exãmple %#{rand} %20.gif" }
let(:file) { StringIO.new(IO.binread("spec/fixtures/landscape.jpg"), 'rb') }
let(:request_input) { fi... |
github | choonkeat/attache | https://github.com/choonkeat/attache | spec/lib/attache/vhost_spec.rb | Ruby | mit | 203 | master | 3,493 | require 'spec_helper'
require 'fog/storage/local/models/file'
require 'fog/aws/models/storage/file'
describe Attache::VHost do
let(:config) { { 'REMOTE_DIR' => remotedir } }
let(:config_with_backup) { YAML.load_file('config/vhost.example.yml').fetch("aws.example.com").merge('REMOTE_DIR' => remotedir) }
let(:vhos... |
github | choonkeat/attache | https://github.com/choonkeat/attache | spec/lib/attache/download_spec.rb | Ruby | mit | 203 | master | 6,256 | require 'spec_helper'
describe Attache::Download do
let(:app) { ->(env) { [200, env, "app"] } }
let(:middleware) { Attache::Download.new(app) }
let(:params) { {} }
let(:filename) { "hello#{rand}.gif" }
let(:reldirname) { "path#{rand}" }
let(:geometry) { CGI.escape('2x2#') }
let(:file) { StringIO.new(IO.b... |
github | choonkeat/attache | https://github.com/choonkeat/attache | spec/lib/attache/resize_job_spec.rb | Ruby | mit | 203 | master | 2,462 | require 'spec_helper'
describe Attache::ResizeJob do
describe '#thumbnail_for' do
let(:max) { 2048 }
let(:current) { [1, 1] }
let(:current_w) { current.shift }
let(:current_h) { current.shift }
let(:job) { Attache::ResizeJob.new }
let(:original_path) { "spec/fixtures/transparent.gif" }
b... |
github | choonkeat/attache | https://github.com/choonkeat/attache | spec/lib/attache/backup_spec.rb | Ruby | mit | 203 | master | 3,785 | require 'spec_helper'
describe Attache::Backup do
let(:app) { ->(env) { [200, env, "app"] } }
let(:middleware) { Attache::Backup.new(app) }
let(:params) { {} }
let(:filename) { "hello#{rand}.gif" }
let(:reldirname) { "path#{rand}" }
let(:file) { StringIO.new(IO.binread("spec/fixtures/transparent.gif"), 'rb... |
github | choonkeat/attache | https://github.com/choonkeat/attache | spec/lib/attache/upload_url_spec.rb | Ruby | mit | 203 | master | 5,029 | require 'spec_helper'
describe Attache::UploadUrl do
let(:app) { ->(env) { [200, env, "app"] } }
let(:uploader) { Attache::Upload.new(app) }
let(:middleware) { Attache::UploadUrl.new(uploader) }
let(:hostname) { "example.com" }
before do
allow(Attache).to receive(:localdir).and_return(Dir.tmpdir) # forc... |
github | choonkeat/attache | https://github.com/choonkeat/attache | spec/lib/attache/tus_spec.rb | Ruby | mit | 203 | master | 1,162 | require 'spec_helper'
describe Attache::Tus do
let(:env) { @env }
let(:config) { @config }
let(:tus) { Attache::Tus.new(env, config) }
it "should return Entity-Length for upload_length" do
@env = { 'HTTP_ENTITY_LENGTH' => rand }
expect(tus.upload_length).to eq(@env['HTTP_ENTITY_LENGTH'])
end
it "... |
github | choonkeat/attache | https://github.com/choonkeat/attache | spec/lib/attache/tus/upload_spec.rb | Ruby | mit | 203 | master | 6,492 | require 'spec_helper'
describe Attache::Tus::Upload do
let(:app) { ->(env) { [200, env, "app"] } }
let(:middleware) { Attache::Tus::Upload.new(app) }
let(:params) { Hash(file: filename) }
let(:filename) { "Exãmple %#{rand} %20.gif" }
let(:file) { StringIO.new(IO.binread("spec/fixtures/landscape.jpg"), 'rb') ... |
github | choonkeat/attache | https://github.com/choonkeat/attache | lib/attache.rb | Ruby | mit | 203 | master | 1,761 | require 'active_support/all'
require 'sys/filesystem'
require 'securerandom'
require 'disk_store'
require 'fileutils'
require 'paperclip'
require 'net/http'
require 'tempfile'
require 'sidekiq'
require 'tmpdir'
require 'logger'
require 'base64'
require 'rack'
require 'json'
require 'uri'
require 'cgi'
require 'fog'
if... |
github | choonkeat/attache | https://github.com/choonkeat/attache | lib/attache/upload.rb | Ruby | mit | 203 | master | 1,292 | class Attache::Upload < Attache::Base
def initialize(app)
@app = app
end
def _call(env, config)
case env['PATH_INFO']
when '/upload'
case env['REQUEST_METHOD']
when 'POST', 'PUT', 'PATCH'
request = Rack::Request.new(env)
params = request.GET # stay away from parsing bod... |
github | choonkeat/attache | https://github.com/choonkeat/attache | lib/attache/vhost.rb | Ruby | mit | 203 | master | 3,330 | class Attache::VHost
attr_accessor :remotedir,
:secret_key,
:backup,
:bucket,
:storage,
:download_headers,
:headers_with_cors,
:geometry_whitelist,
:env
def initialize(hash)
self.env ... |
github | choonkeat/attache | https://github.com/choonkeat/attache | lib/attache/job.rb | Ruby | mit | 203 | master | 935 | class Attache::Job
RETRY_DURATION = ENV.fetch('CACHE_EVICTION_INTERVAL_SECONDS') { 60 }.to_i / 3
def perform(method, env, args)
config = Attache::VHost.new(env)
config.send(method, args.symbolize_keys)
rescue Exception
Attache.logger.error $@
Attache.logger.error $!
Attache.logger.error [meth... |
github | choonkeat/attache | https://github.com/choonkeat/attache | lib/attache/tasks.rb | Ruby | mit | 203 | master | 281 | require "rake"
namespace :attache do
desc "Convert content of FILE to a JSON string; default FILE=config/vhost.yml"
task :vhost do
require 'yaml'
require 'json'
file = ENV.fetch("FILE") { "config/vhost.yml" }
puts YAML.load(IO.read(file)).to_json
end
end |
github | choonkeat/attache | https://github.com/choonkeat/attache | lib/attache/upload_url.rb | Ruby | mit | 203 | master | 2,135 | class Attache::UploadUrl < Attache::Base
def initialize(app)
@app = app
end
def _call(env, config)
case env['PATH_INFO']
when '/upload_url'
# always pretend to be `POST /upload`
env['PATH_INFO'] = '/upload'
env['REQUEST_METHOD'] = 'POST'
request = Rack::Request.new(env)
... |
github | choonkeat/attache | https://github.com/choonkeat/attache | lib/attache/base.rb | Ruby | mit | 203 | master | 2,165 | class Attache::Base
def call(env)
if vhost = vhost_for(request_hostname(env))
dup._call(env, vhost)
else
@app.call(env)
end
rescue Timeout::Error
Attache.logger.error $@
Attache.logger.error $!
Attache.logger.error "ERROR 503 #{env['PATH_INFO']} REFERER #{env['HTTP_REFERER'].insp... |
github | choonkeat/attache | https://github.com/choonkeat/attache | lib/attache/resize_job.rb | Ruby | mit | 203 | master | 4,059 | require 'digest/sha1'
require 'stringio'
class Attache::ResizeJob
def perform(target_geometry_string, basename, relpath, vhosts, env, t = Time.now)
closed_file = yield
return StringIO.new if closed_file.try(:size).to_i == 0
extension = basename.split(/\W+/).last
Attache.logger.info "[POOL] start"
... |
github | choonkeat/attache | https://github.com/choonkeat/attache | lib/attache/delete.rb | Ruby | mit | 203 | master | 1,190 | class Attache::Delete < Attache::Base
def initialize(app)
@app = app
end
def _call(env, config)
case env['PATH_INFO']
when '/delete'
request = Rack::Request.new(env)
params = request.params
return config.unauthorized unless config.authorized?(params)
threads = []
par... |
github | choonkeat/attache | https://github.com/choonkeat/attache | lib/attache/backup.rb | Ruby | mit | 203 | master | 792 | class Attache::Backup < Attache::Base
def initialize(app)
@app = app
end
def _call(env, config)
case env['PATH_INFO']
when '/backup'
request = Rack::Request.new(env)
params = request.params
return config.unauthorized unless config.authorized?(params)
if config.storage && c... |
github | choonkeat/attache | https://github.com/choonkeat/attache | lib/attache/file_response_body.rb | Ruby | mit | 203 | master | 487 | class Attache::FileResponseBody
def initialize(file, range_start = nil, range_end = nil)
@file = file
@range_start = range_start || 0
@range_end = range_end || File.size(@file.path)
end
# adapted from rack/file.rb
def each
@file.seek(@range_start)
remaining_len = @range_end
whi... |
github | choonkeat/attache | https://github.com/choonkeat/attache | lib/attache/download.rb | Ruby | mit | 203 | master | 4,693 | require 'connection_pool'
class Attache::Download < Attache::Base
RESIZE_JOB_POOL = ConnectionPool.new(JSON.parse(ENV.fetch('RESIZE_POOL') { '{ "size": 2, "timeout": 60 }' }).symbolize_keys) { Attache::ResizeJob.new }
def initialize(app)
@app = app
@mutexes = {}
end
def _call(env, config)
case en... |
github | choonkeat/attache | https://github.com/choonkeat/attache | lib/attache/tus.rb | Ruby | mit | 203 | master | 1,324 | class Attache::Tus
LENGTH_KEYS = %w[Upload-Length Entity-Length]
OFFSET_KEYS = %w[Upload-Offset Offset]
METADATA_KEYS = %w[Upload-Metadata Metadata]
attr_accessor :env, :config
def initialize(env, config)
@env = env
@config = config
end
def header_value(keys)
value = nil
keys.fi... |
github | choonkeat/attache | https://github.com/choonkeat/attache | lib/attache/tus/upload.rb | Ruby | mit | 203 | master | 3,279 | class Attache::Tus::Upload < Attache::Base
def initialize(app)
@app = app
end
def _call(env, config)
case env['PATH_INFO']
when '/tus/files'
tus = ::Attache::Tus.new(env, config)
params = params_of(env) # avoid unnecessary `invalid byte sequence in UTF-8` on `request.params`
return ... |
github | choonkeat/attache | https://github.com/choonkeat/attache | config/puma.rb | Ruby | mit | 203 | master | 241 | workers Integer(ENV['PUMA_WORKERS'] || 1)
threads Integer(ENV['MIN_THREADS'] || 1), Integer(ENV['MAX_THREADS'] || 16)
preload_app!
rackup DefaultRackup
port ENV['PORT'] || 3000
environment ENV['RACK_ENV'] || 'development' |
github | chef/knife-vsphere | https://github.com/chef/knife-vsphere | Rakefile | Ruby | apache-2.0 | 202 | main | 788 | require "bundler/gem_tasks"
begin
require "rspec/core/rake_task"
RSpec::Core::RakeTask.new do |t|
t.pattern = "spec/**/*_spec.rb"
end
rescue LoadError
desc "rspec is not installed, this task is disabled"
task :spec do
abort "rspec is not installed. bundle install first to make sure all dependencies ... |
github | chef/knife-vsphere | https://github.com/chef/knife-vsphere | knife-vsphere.gemspec | Ruby | apache-2.0 | 202 | main | 716 | $:.unshift(File.dirname(__FILE__) + "/lib")
require "knife-vsphere/version"
Gem::Specification.new do |s|
s.name = "knife-vsphere"
s.version = KnifeVsphere::VERSION
s.summary = "VMware vSphere support for Chef Infra's Knife command"
s.authors = "Ezra Pagel"
s.description = "VMware vSphere support for Chef In... |
github | chef/knife-vsphere | https://github.com/chef/knife-vsphere | Gemfile | Ruby | apache-2.0 | 202 | main | 202 | source "https://rubygems.org"
gemspec
group :debug do
gem "pry"
gem "pry-byebug"
gem "pry-stack_explorer"
end
group :test do
gem "chefstyle", "2.1.0"
gem "rake"
gem "rspec", "~> 3.0"
end |
github | chef/knife-vsphere | https://github.com/chef/knife-vsphere | lib/chef/knife/vsphere_vm_list.rb | Ruby | apache-2.0 | 202 | main | 2,167 | #
# Author:: Ezra Pagel (<ezra@cpan.org>)
# License:: Apache License, Version 2.0
#
require "chef/knife"
require_relative "helpers/base_vsphere_command"
# Lists all known virtual machines in the configured datacenter
class Chef::Knife::VsphereVmList < Chef::Knife::BaseVsphereCommand
banner "knife vsphere vm list"
... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.