terminalwire 0.3.0 → 0.3.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- metadata +4 -5
- data/Rakefile +0 -70
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b2a90cc36935da50202bb5d965608626ecbebda93a907b080102c0d0b52a3069
|
4
|
+
data.tar.gz: e2da1b1521c20ffe673e767d0ec3f8914249421a88d5eb4d4de86d1633100138
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f046e1f203467d44f3ebca5967091c83cfc4edc0bf68d164bf726b02b4e8cc1f1f6175b8665c994d687dd0a97c63f3cc1474472fcf744e740aa45c00c38268ba
|
7
|
+
data.tar.gz: d8d48c19fc1b46f3b3b0ca3d542ade58548f86b52a7dffa220be4fb6281a4a69018e29ebd5a01b5e818788ed4e86b84fc41204171a5db9253db64db7e6adb382
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: terminalwire
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Brad Gessler
|
8
8
|
bindir: exe
|
9
9
|
cert_chain: []
|
10
|
-
date: 2025-02-
|
10
|
+
date: 2025-02-24 00:00:00.000000000 Z
|
11
11
|
dependencies:
|
12
12
|
- !ruby/object:Gem::Dependency
|
13
13
|
name: terminalwire-client
|
@@ -15,14 +15,14 @@ dependencies:
|
|
15
15
|
requirements:
|
16
16
|
- - '='
|
17
17
|
- !ruby/object:Gem::Version
|
18
|
-
version: 0.3.
|
18
|
+
version: 0.3.1
|
19
19
|
type: :runtime
|
20
20
|
prerelease: false
|
21
21
|
version_requirements: !ruby/object:Gem::Requirement
|
22
22
|
requirements:
|
23
23
|
- - '='
|
24
24
|
- !ruby/object:Gem::Version
|
25
|
-
version: 0.3.
|
25
|
+
version: 0.3.1
|
26
26
|
description: Stream command-line apps from your server without a web API
|
27
27
|
email:
|
28
28
|
- brad@terminalwire.com
|
@@ -32,7 +32,6 @@ executables:
|
|
32
32
|
extensions: []
|
33
33
|
extra_rdoc_files: []
|
34
34
|
files:
|
35
|
-
- Rakefile
|
36
35
|
- exe/terminalwire
|
37
36
|
- exe/terminalwire-exec
|
38
37
|
homepage: https://terminalwire.com/ruby
|
data/Rakefile
DELETED
@@ -1,70 +0,0 @@
|
|
1
|
-
require 'pathname'
|
2
|
-
|
3
|
-
task :default do
|
4
|
-
ruby_version = "3.3.6"
|
5
|
-
os = "osx"
|
6
|
-
platform = "arm64"
|
7
|
-
url = "https://github.com/YOU54F/traveling-ruby/releases/download/rel-20241122/traveling-ruby-20241122-#{ruby_version}-#{os}-#{platform}-full.tar.gz"
|
8
|
-
path = Pathname.new("package/#{os}-#{platform}")
|
9
|
-
gem = Gem::Specification.load("terminalwire.gemspec")
|
10
|
-
|
11
|
-
sh "mkdir -p #{path}"
|
12
|
-
|
13
|
-
# Don't bother downloading if we already have the file
|
14
|
-
unless File.exist? path.join("lib/ruby/info/RUBY_COMPAT_VERSION")
|
15
|
-
sh "mkdir -p #{path.join("lib/ruby")}"
|
16
|
-
sh "curl -L #{url} | tar -xzf - -C #{path.join("lib/ruby")}"
|
17
|
-
end
|
18
|
-
|
19
|
-
# Install the base gem and all of its dependencies in the vendor directory.
|
20
|
-
sh "gem install #{gem.name} --version '#{gem.version}' --install-dir #{path.join("lib/vendor")} --no-document --verbose"
|
21
|
-
|
22
|
-
# Remove caches to make package smaller
|
23
|
-
sh "rm -rf #{path.join("lib/vendor/cache")}"
|
24
|
-
sh "rm -rf #{path.join("lib/vendor/bin")}"
|
25
|
-
sh "rm -rf #{path.join("lib/vendor/doc")}"
|
26
|
-
sh "rm -rf #{path.join("lib/vendor/plugins")}"
|
27
|
-
|
28
|
-
File.write path.join("lib/boot.rb"), <<~RUBY
|
29
|
-
# Resolve the base directory
|
30
|
-
base_dir = File.expand_path("../..", __FILE__)
|
31
|
-
|
32
|
-
# Add all gem paths under lib/vendor to the load path
|
33
|
-
Dir.glob(File.join(base_dir, "lib/vendor/gems/*/lib")).each do |gem_path|
|
34
|
-
$LOAD_PATH.unshift gem_path
|
35
|
-
end
|
36
|
-
RUBY
|
37
|
-
|
38
|
-
gems = path.glob("lib/vendor/specifications/*.gemspec").each_with_object({}) do |spec_path, hash|
|
39
|
-
spec = Gem::Specification.load(spec_path.to_s)
|
40
|
-
hash[spec.name] = spec
|
41
|
-
end
|
42
|
-
|
43
|
-
terminalwire_gem = gems.fetch("terminalwire")
|
44
|
-
|
45
|
-
gem_path = Pathname.new(terminalwire_gem.full_gem_path).relative_path_from path.expand_path
|
46
|
-
exe_path = gem_path.join(terminalwire_gem.bindir, "terminalwire-exec")
|
47
|
-
|
48
|
-
# Let's write the executable path into the thing...'
|
49
|
-
File.write path.join("terminalwire-exec"), <<~RUBY
|
50
|
-
#!/bin/bash
|
51
|
-
# Resolve the directory of the current script
|
52
|
-
SELFDIR="$(cd "$(dirname "$0")" && pwd)"
|
53
|
-
|
54
|
-
# Path to the embedded Ruby executable
|
55
|
-
RUBY_EXEC="$SELFDIR/lib/ruby/bin/ruby"
|
56
|
-
BOOT_SCRIPT="$SELFDIR/lib/boot.rb"
|
57
|
-
PROGRAM="$SELFDIR/#{exe_path}"
|
58
|
-
|
59
|
-
# Pass the boot script and the main Ruby script to Ruby
|
60
|
-
exec "$RUBY_EXEC" -r"$BOOT_SCRIPT" "$PROGRAM" "$@"
|
61
|
-
RUBY
|
62
|
-
|
63
|
-
File.chmod 0755, path.join("terminalwire-exec")
|
64
|
-
|
65
|
-
# TODO: download and install each gem extension for its platform.
|
66
|
-
native_gems = gems.values.select{ _1.extensions.any? }
|
67
|
-
native_gems.each do |native_gem|
|
68
|
-
p native_gem
|
69
|
-
end
|
70
|
-
end
|