time-sheet 0.11.2 → 0.12.0

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 34d0ef63890eeae177443276610e4537d5dc2cfd138497132e6eb351ef5aa869
4
- data.tar.gz: e40b4fc84073bfc67a358e54c72107bd5a2a988969a75a3a5b04261b2574255c
3
+ metadata.gz: 5ca95455a7df9dfb1262804ff2c325b25cea1336b75320b86881ebb9f96a9f8d
4
+ data.tar.gz: a85d3aa69e2d335b37e54bf210fe28a6f83ae1f78aa178ebe08aa4822542ce8d
5
5
  SHA512:
6
- metadata.gz: 1bc92043a7bd4085427ade8981d7e7e014bc6704cec744174b53ec3ce9f6bd5e274d58d740371f08356fc1968207bc8b2c487d01b82fef1c2bbdd294b603cc75
7
- data.tar.gz: 4ebf6508e2c23bb2ca6ba88f00c9ab945777f39ec76236a66362908787004c1d339bd6df7405f29f5fcde48f235853b611606e0c7b9d67d61dca8a7398265456
6
+ metadata.gz: e7eb8b409573f45e1098b262b207bf09b6557fb8372ee31a75514ee77320526fb1f46ef9e8e55927f218bcf7142697e768d3f15e345466eded9163beaa92fb67
7
+ data.tar.gz: 7b78b9d314aa531c452d677fd725b07ea7471c62a3b1999af5cfd577f8a5644416d5173000f380dd7620fd9660d9bb2e300ca6c12f8e034d49def97c2e2c69c6
@@ -117,7 +117,7 @@ class TimeSheet::Time::Cmd
117
117
  o.string '-t', '--to', 'ignore entries more recent than the date given'
118
118
  o.string '-p', '--project', 'take only entries of this project into account'
119
119
  o.string '-a', '--activity', 'take only entries of this activity into account'
120
- o.string '--tags', 'take only entries with these tags into account (comma separated, not case sensitive)'
120
+ o.string '--tags', 'filter by tag (comma separated, not case sensitive, prefix tag with ! to exclude)'
121
121
  o.string '-d', '--description', 'consider only entries matching this description'
122
122
  o.string '-e', '--employee', 'consider only entries for this employee'
123
123
  o.float '-r', '--rate', 'use an alternative hourly rate (default: 80.0)', default: 80.00
@@ -105,7 +105,12 @@ class TimeSheet::Time::Entry
105
105
  return true if tags.empty?
106
106
 
107
107
  tags.all? do |tag|
108
- self.tags.include?(tag)
108
+ if tag.match?(/^\!/)
109
+ t = tag.gsub(/\!/, '')
110
+ !self.tags.include?(t)
111
+ else
112
+ self.tags.include?(tag)
113
+ end
109
114
  end
110
115
  end
111
116
 
@@ -1,3 +1,3 @@
1
1
  module TimeSheet
2
- VERSION = "0.11.2"
2
+ VERSION = "0.12.0"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: time-sheet
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.11.2
4
+ version: 0.12.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Moritz Schepp
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2021-06-25 00:00:00.000000000 Z
11
+ date: 2021-09-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: spreadsheet