raykit 0.0.361 → 0.0.364
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/raykit/filesystem.rb +10 -0
- data/lib/raykit/git/repository.rb +29 -0
- data/lib/raykit/nunit.rb +1 -1
- data/lib/raykit/wt.rb +28 -0
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 338ae0dcb4e2a414d4f0800219c4de972a37609c75d9d53c4c270d2a29f447f8
|
4
|
+
data.tar.gz: 06b09c32911dcc38f85f032a24d3b24a26a854f788ec3d608b8d68afa4d3d723
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c920a13a84749662c76225f827d195c0731ab581698ccc99496a4723464d62af2783112b7121d6b5666211e44544793e0cd74499097ecf7fb4da3040e8871194
|
7
|
+
data.tar.gz: 66fb36eabb92998c133a99269a70b9c76dd8a40b51c9cb2111bacd546cd283975983259c7caa71bafdd1e9198b246cfc3ca56c9d6c2996496534cf976fa9a84f
|
data/lib/raykit/filesystem.rb
CHANGED
@@ -10,5 +10,15 @@ module Raykit
|
|
10
10
|
}
|
11
11
|
end
|
12
12
|
end
|
13
|
+
|
14
|
+
def self.copy_file_to_dir(file, dir)
|
15
|
+
dest = "#{dir}/#{File.basename(file)}"
|
16
|
+
if (File.exists?(dest))
|
17
|
+
return "#{dest} already exists"
|
18
|
+
else
|
19
|
+
FileUtils.cp(file, dest)
|
20
|
+
return "#{dest} now exists"
|
21
|
+
end
|
22
|
+
end
|
13
23
|
end
|
14
24
|
end
|
@@ -101,6 +101,35 @@ module Raykit
|
|
101
101
|
end
|
102
102
|
false
|
103
103
|
end
|
104
|
+
|
105
|
+
def self.work_pull(url)
|
106
|
+
repo = Raykit::Git::Repository.new(url)
|
107
|
+
work_dir = repo.get_dev_dir("work")
|
108
|
+
repo.clone(work_dir) if !Dir.exist?(work_dir)
|
109
|
+
Dir.chdir(work_dir) do
|
110
|
+
run("git pull")
|
111
|
+
end
|
112
|
+
end
|
113
|
+
|
114
|
+
def self.work_integrate(url)
|
115
|
+
repo = Raykit::Git::Repository.new(url)
|
116
|
+
work_dir = repo.get_dev_dir("work")
|
117
|
+
repo.clone(work_dir) if !Dir.exist?(work_dir)
|
118
|
+
Dir.chdir(work_dir) do
|
119
|
+
run("git pull")
|
120
|
+
run("rake integrate")
|
121
|
+
end
|
122
|
+
end
|
123
|
+
|
124
|
+
def self.work(url, cmd)
|
125
|
+
repo = Raykit::Git::Repository.new(url)
|
126
|
+
work_dir = repo.get_dev_dir("work")
|
127
|
+
repo.clone(work_dir) if !Dir.exist?(work_dir)
|
128
|
+
Dir.chdir(work_dir) do
|
129
|
+
run("git pull")
|
130
|
+
run(cmd)
|
131
|
+
end
|
132
|
+
end
|
104
133
|
end
|
105
134
|
end
|
106
135
|
end
|
data/lib/raykit/nunit.rb
CHANGED
@@ -3,7 +3,7 @@ module Raykit
|
|
3
3
|
def self.nunit3console_path(version)
|
4
4
|
# C:\Users\lparslow\.nuget\packages\nunit.consolerunner\3.15.0\tools
|
5
5
|
path = "#{Environment.home_dir}/.nuget/packages/nunit.consolerunner/#{version}/tools"
|
6
|
-
if Dir.
|
6
|
+
if Dir.exist?(path)
|
7
7
|
path
|
8
8
|
else
|
9
9
|
""
|
data/lib/raykit/wt.rb
ADDED
@@ -0,0 +1,28 @@
|
|
1
|
+
module Raykit
|
2
|
+
class Wt
|
3
|
+
def self.open(names)
|
4
|
+
if names.is_a? String
|
5
|
+
cmd = Raykit::Command.new("wt --maximized #{get_tab_arg(names)}").run
|
6
|
+
end
|
7
|
+
if names.is_a?(Array)
|
8
|
+
cmd = "wt --maximized "
|
9
|
+
index = 0
|
10
|
+
names.each { |url|
|
11
|
+
if index <= 0
|
12
|
+
cmd += get_tab_arg(url)
|
13
|
+
else
|
14
|
+
cmd += ";new-tab " + get_tab_arg(url)
|
15
|
+
end
|
16
|
+
index = index + 1
|
17
|
+
}
|
18
|
+
Raykit::Command.new(cmd).run
|
19
|
+
end
|
20
|
+
end
|
21
|
+
|
22
|
+
def self.get_tab_arg(url)
|
23
|
+
dir = Raykit::Git::Repository.new(url).get_dev_dir("work")
|
24
|
+
name = File.basename(dir)
|
25
|
+
"-d #{dir} --title #{name}"
|
26
|
+
end
|
27
|
+
end
|
28
|
+
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: raykit
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.364
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Lou Parslow
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-
|
11
|
+
date: 2022-05-16 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -121,6 +121,7 @@ files:
|
|
121
121
|
- lib/raykit/timer.rb
|
122
122
|
- lib/raykit/version.rb
|
123
123
|
- lib/raykit/vstest.rb
|
124
|
+
- lib/raykit/wt.rb
|
124
125
|
- lib/raykit/zip.rb
|
125
126
|
homepage: http://rubygems.org/gems/raykit
|
126
127
|
licenses:
|