usd 0.2.2 → 0.2.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/bin/rusdc +6 -1
- data/change_log.md +60 -0
- data/usd.gemspec +2 -2
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 321fb82b164595bcb7c2ff73cb7e9f1ed9fe6306b9517c1c236ae30aaa713aaa
|
4
|
+
data.tar.gz: ea63b6a5116370391d19c4b2c6d9d82768fb0fd9af709dd9a971829fd9a3db74
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 28255500c9fcee00e8d62361f8ec06a12e4617f653f8c4aa255655d7fd37a76b429440922511d4af9288fd67670c7a5346eceb358514ddaf087bcb73e07a157e
|
7
|
+
data.tar.gz: a726a7585b18c684ce71153b2c964100cd3b52ce62f1d9b0b78581e9b591947951b04a5b6990afbe12daa4ef7c088f6dd17ef99fd0a199b32ce4792d8a15ac6b
|
data/bin/rusdc
CHANGED
@@ -199,6 +199,11 @@ class Rusdc < Thor
|
|
199
199
|
end
|
200
200
|
end
|
201
201
|
|
202
|
+
desc "in_add_2_chg <changeorder> <incident>", "add incident to changeorder"
|
203
|
+
def in_add_2_chg(chg, incident)
|
204
|
+
invoke('update_ref_attr',['in', incident, 'change', chg])
|
205
|
+
end
|
206
|
+
|
202
207
|
desc "in_list_child_ins <in>", "list all child-incidents of one incident"
|
203
208
|
def in_list_child_ins(incident)
|
204
209
|
invoke('find',['cr', "parent.ref_num = '#{incident}'", "ref_num"], {:format => "mlr"})
|
@@ -375,7 +380,7 @@ class Rusdc < Thor
|
|
375
380
|
puts loadcon.update({:type => "json", :data => json})
|
376
381
|
end
|
377
382
|
|
378
|
-
desc "update_ref_attr_by_id <obj> <id> <key> <
|
383
|
+
desc "update_ref_attr_by_id <obj> <id> <key> <value_id>", "updates a referenced attribute of one object_id by value-id"
|
379
384
|
def update_ref_attr_by_id(obj, id, k, v)
|
380
385
|
template = ERB.new <<-EOF
|
381
386
|
{
|
data/change_log.md
CHANGED
@@ -1,5 +1,65 @@
|
|
1
1
|
# changelog
|
2
2
|
|
3
|
+
## 0.2.3
|
4
|
+
|
5
|
+
- new function `in_add_2_chg` - add incident to changeorder
|
6
|
+
|
7
|
+
Usage:
|
8
|
+
|
9
|
+
```
|
10
|
+
|
11
|
+
rusdc in_add_2_chg <changeorder> <incident>
|
12
|
+
```
|
13
|
+
|
14
|
+
Example:
|
15
|
+
|
16
|
+
```
|
17
|
+
$ rusdc find in "change.chg_ref_num = 'CO000001'" --format mlr
|
18
|
+
@COMMON_NAME
|
19
|
+
I000001
|
20
|
+
I000002
|
21
|
+
$ rusdc in_add_2_chg CO000001 I000003
|
22
|
+
$ rusdc find in "change.chg_ref_num = 'CO000001'" --format mlr
|
23
|
+
@COMMON_NAME
|
24
|
+
I000001
|
25
|
+
I000002
|
26
|
+
I000003
|
27
|
+
```
|
28
|
+
|
29
|
+
## 0.2.2
|
30
|
+
|
31
|
+
- extented function `update_attr`, now you may use a where-clause instead of a `common_name` to filter the object(s) to update
|
32
|
+
|
33
|
+
Example 1:
|
34
|
+
|
35
|
+
update many CIs with one statement...b
|
36
|
+
|
37
|
+
```bash
|
38
|
+
$ rusdc find nr "name like 'server[12]'" name,description --format mlr
|
39
|
+
name description
|
40
|
+
server1 vorher
|
41
|
+
server2 vorher
|
42
|
+
$ rusdc update_attr nr "name like 'server[12]'" description "new description"
|
43
|
+
$ rusdc find nr "name like 'server[12]'" name,description --format mlr
|
44
|
+
name description
|
45
|
+
server1 new description
|
46
|
+
server2 new description
|
47
|
+
```
|
48
|
+
|
49
|
+
Example 2:
|
50
|
+
|
51
|
+
update a CI which has a special attribute value:
|
52
|
+
|
53
|
+
```bash
|
54
|
+
$ rusdc find nr "serial_number = 'ABC123ABC987'" name,serial_number,warranty_end --format mlr
|
55
|
+
name serial_number warranty_end
|
56
|
+
server1 ABC123ABC987 2020-11-30 00:00:00 +0100
|
57
|
+
$ rusdc update_attr nr "serial_number = 'ABC123ABC987'" warranty_end "01.02.2022"
|
58
|
+
$ rusdc find nr "serial_number = 'ABC123ABC987'" name,serial_number,warranty_end --format mlr
|
59
|
+
name serial_number warranty_end
|
60
|
+
server1 ABC123ABC987 2022-02-01 00:00:00 +0100
|
61
|
+
```
|
62
|
+
|
3
63
|
## 0.2.1
|
4
64
|
|
5
65
|
- function `update_attr` has a new option for putting plain text with linebreaks in it.
|
data/usd.gemspec
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
Gem::Specification.new do |spec|
|
2
2
|
spec.name = 'usd'
|
3
|
-
spec.version = '0.2.
|
4
|
-
spec.date = '2019-
|
3
|
+
spec.version = '0.2.3'
|
4
|
+
spec.date = '2019-12-06'
|
5
5
|
spec.summary = "SDM REST-API-Calls"
|
6
6
|
spec.description = "a Ruby class and a commandlinetool for SDM REST-API-Calls"
|
7
7
|
spec.authors = ["Oliver Gaida"]
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: usd
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Oliver Gaida
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-
|
11
|
+
date: 2019-12-06 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: thor
|