bundler-exec-shell-export 0.0.1.pre.iteration.1 → 0.0.1.pre.iteration.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: ed0b22f61f496f5fcf0a32d3abf1f05454fa82b1de985601d3558d4ad694c14d
4
- data.tar.gz: 3deafe0120eb500a9fc12d17fdddfbf6bd0ffa8c26c141b38819947902bb5f07
3
+ metadata.gz: a0f07e5177e30d7f58707cf0a6aa80ff1d635b0ebc371fbe486375885d72493a
4
+ data.tar.gz: 683a3226f6fd153375dbc44d6d05825d943e0f009ef60b4e1db48793fa0181ca
5
5
  SHA512:
6
- metadata.gz: 4d51f872317fa1a0c9b7390f83056ee50af1aac3a2f508facd62beec599cfee1b1e32da31a2b7e3d636350c5e69eeb75cedff79f4971bfd4c78e5c740a9640d0
7
- data.tar.gz: 91df7f61a0eccb32c7427e143c3fede0bb68b60a17d2c68a5b3d983f011d1e8ae2391086b9e6f4453a64842b8fa384fb72c74698df53482ddb1c708fe8d7b7fc
6
+ metadata.gz: 52fb9ee41f9cf05f7a984d12af49b1517d07a4fe00a9a8a41680b1c43ffc877a7b04d4cd44053dbaf7590209e0dcdd2e49597867a336625dc8ecebe803378c7c
7
+ data.tar.gz: 63e3bf3de711dcb07212dde7fe81d16a70d7d8e912d5e892d65a7b4f99ae927c1b747d018c7005e57d8958d8abe10888d1bab7ae08e9d89f3edf926fad8b06c1
data/CHANGELOG.md ADDED
@@ -0,0 +1,15 @@
1
+ ## [Unreleased]
2
+
3
+ ## [0.0.1-iteration.3] - 2024-10-08
4
+
5
+ - Fix non-plugin invocation from executable.
6
+
7
+ ## [0.0.1-iteration.2] - 2024-10-08
8
+
9
+ - Add executable script for use when not installed as a plugin.
10
+ - Fix bug where the bundle was not actually loaded before export.
11
+ - Fix friendly error status code.
12
+
13
+ ## [0.0.1-iteration.1] - 2024-10-07
14
+
15
+ Initial release.
data/LICENSE.txt ADDED
@@ -0,0 +1,21 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2024 Amir Yalon
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in
13
+ all copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
+ THE SOFTWARE.
data/README.md ADDED
@@ -0,0 +1,35 @@
1
+ # A Bundler plugin for exporting the bundle execution environment to a POSIX shell
2
+
3
+ Adds a `bundle exec-shell-export` command that outputs the script to source from a POSIX shell.
4
+
5
+ ## Installation
6
+
7
+ Add this line to your application’s Gemfile:
8
+
9
+ ```ruby
10
+ plugin 'bundler-exec-shell-export'
11
+ ```
12
+
13
+ And then execute:
14
+
15
+ ```console
16
+ $ bundle install
17
+ ```
18
+
19
+ ## Usage
20
+
21
+ ```console
22
+ $ eval "$(bundle exec-shell-export)"
23
+ ```
24
+
25
+ ## Development
26
+
27
+ TODO: TBD
28
+
29
+ ## Contributing
30
+
31
+ Bug reports and pull requests may or may not be welcome at https://github.com/amiryal/bundler-exec-shell-export.
32
+
33
+ ## License
34
+
35
+ The plugin is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).
@@ -0,0 +1,6 @@
1
+ require "bundler/errors"
2
+ require "bundler/friendly_errors"
3
+ Bundler.with_friendly_errors do
4
+ require "bundler_exec_shell_export"
5
+ BundlerExecShellExport.new.exec("exec-shell-export", ARGV)
6
+ end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  class BundlerExecShellExport
4
- VERSION = "0.0.1-iteration.1" unless defined?(VERSION)
4
+ VERSION = "0.0.1-iteration.3" unless defined?(VERSION)
5
5
  end
@@ -1,14 +1,29 @@
1
1
  # frozen_string_literal: true
2
2
 
3
+ require "bundler/plugin"
4
+
3
5
  require_relative "bundler_exec_shell_export/version"
4
6
 
5
7
  class BundlerExecShellExport
6
- class Error < Bundler::BundlerError; end
7
8
  Bundler::Plugin::API.command("exec-shell-export", self)
9
+
10
+ class Error < Bundler::BundlerError
11
+ def to_int
12
+ 1
13
+ end
14
+
15
+ def ==(*)
16
+ false
17
+ end
18
+
19
+ status_code(new)
20
+ end
21
+
8
22
  def exec(command_name, args)
9
23
  raise Error, "#{command_name}: called with redundant arguments" if args.any?
10
24
 
11
25
  require "shellwords"
26
+ require "bundler/setup"
12
27
  Bundler::EnvironmentPreserver::BUNDLER_KEYS.each do |key|
13
28
  [key, "#{Bundler::EnvironmentPreserver::BUNDLER_PREFIX}#{key}"].each do |name|
14
29
  next unless (value = ENV[name])
metadata CHANGED
@@ -1,12 +1,12 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bundler-exec-shell-export
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1.pre.iteration.1
4
+ version: 0.0.1.pre.iteration.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Amir Yalon
8
8
  autorequire:
9
- bindir: bin
9
+ bindir: exe
10
10
  cert_chain: []
11
11
  date: 1970-01-01 00:00:00.000000000 Z
12
12
  dependencies: []
@@ -14,10 +14,15 @@ description: Adds a `bundle exec-shell-export` command that outputs the script t
14
14
  source from a POSIX shell.
15
15
  email:
16
16
  - git@please.nospammail.net
17
- executables: []
17
+ executables:
18
+ - bundler-exec-shell-export
18
19
  extensions: []
19
20
  extra_rdoc_files: []
20
21
  files:
22
+ - CHANGELOG.md
23
+ - LICENSE.txt
24
+ - README.md
25
+ - exe/bundler-exec-shell-export
21
26
  - lib/bundler_exec_shell_export.rb
22
27
  - lib/bundler_exec_shell_export/version.rb
23
28
  - plugins.rb