Skip to content

Commit 5bbf0d3

Browse files
author
Stefan Fleck
committed
prep for release
1 parent 18bd82e commit 5bbf0d3

17 files changed

+100
-96
lines changed

DESCRIPTION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
Type: Package
22
Package: rotor
33
Title: Log Rotation and Conditional Backups
4-
Version: 0.2.2.9000
4+
Version: 0.2.3
55
Authors@R:
66
person(given = "Stefan",
77
family = "Fleck",

NEWS.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# rotor 0.2.2.9000
1+
# rotor 0.2.3
22

33
* Changed default behaviour of `rotate_date()`, `rotate_time()`, etc...: If
44
no backups exist of target file, use the "created" timestamp

README.Rmd

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,7 @@ backup_info(tf)
141141
```
142142
If we examine the "timestamp" column in the example above, we see that missing
143143
date information is always interpreted as the start of the period; i.e. so
144-
`"2019-01"` is equivalent to `"2019-01-01--00--00--00"` for all intentds and
144+
`"2019-01"` is equivalent to `"2019-01-01--00--00--00"` for all intents and
145145
purposes.
146146

147147
```{r}

README.md

Lines changed: 30 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -83,8 +83,8 @@ backup(tf, compression = TRUE)
8383

8484
# display backups of a file
8585
list_backups(tf)
86-
#> [1] "/tmp/RtmpT5fN3W/rotor/mylogfile.1.log.zip"
87-
#> [2] "/tmp/RtmpT5fN3W/rotor/mylogfile.2.log"
86+
#> [1] "/tmp/Rtmpg6uXBK/rotor/mylogfile.1.log.zip"
87+
#> [2] "/tmp/Rtmpg6uXBK/rotor/mylogfile.2.log"
8888
```
8989

9090
`rotate()` also backs up a file, but replaces the original file with an
@@ -93,9 +93,9 @@ empty one.
9393
``` r
9494
rotate(tf)
9595
list_backups(tf)
96-
#> [1] "/tmp/RtmpT5fN3W/rotor/mylogfile.1.log"
97-
#> [2] "/tmp/RtmpT5fN3W/rotor/mylogfile.2.log.zip"
98-
#> [3] "/tmp/RtmpT5fN3W/rotor/mylogfile.3.log"
96+
#> [1] "/tmp/Rtmpg6uXBK/rotor/mylogfile.1.log"
97+
#> [2] "/tmp/Rtmpg6uXBK/rotor/mylogfile.2.log.zip"
98+
#> [3] "/tmp/Rtmpg6uXBK/rotor/mylogfile.3.log"
9999

100100
# the original file is now empty
101101
readLines(tf)
@@ -118,10 +118,10 @@ backup(tf, max_backups = 4)
118118
backup(tf, max_backups = 4)
119119

120120
list_backups(tf)
121-
#> [1] "/tmp/RtmpT5fN3W/rotor/mylogfile.1.log"
122-
#> [2] "/tmp/RtmpT5fN3W/rotor/mylogfile.2.log"
123-
#> [3] "/tmp/RtmpT5fN3W/rotor/mylogfile.3.log"
124-
#> [4] "/tmp/RtmpT5fN3W/rotor/mylogfile.4.log.zip"
121+
#> [1] "/tmp/Rtmpg6uXBK/rotor/mylogfile.1.log"
122+
#> [2] "/tmp/Rtmpg6uXBK/rotor/mylogfile.2.log"
123+
#> [3] "/tmp/Rtmpg6uXBK/rotor/mylogfile.3.log"
124+
#> [4] "/tmp/Rtmpg6uXBK/rotor/mylogfile.4.log.zip"
125125
```
126126

127127
We can also use `prune_backups()` to delete old backups. Other than
@@ -155,35 +155,35 @@ backup_time(tf, format = "%Y%m%dT%H%M%S") # ISO 8601 compatible
155155

156156
backup_info(tf)
157157
#> path name
158-
#> 1 /tmp/RtmpT5fN3W/rotor/mylogfile.2019-05-31_06-48-27.log mylogfile
159-
#> 2 /tmp/RtmpT5fN3W/rotor/mylogfile.2019-05-31--06-48-27.log mylogfile
160-
#> 5 /tmp/RtmpT5fN3W/rotor/mylogfile.20190531T064827.log mylogfile
161-
#> 3 /tmp/RtmpT5fN3W/rotor/mylogfile.2019-05-31.log mylogfile
162-
#> 4 /tmp/RtmpT5fN3W/rotor/mylogfile.2019-05.log mylogfile
158+
#> 1 /tmp/Rtmpg6uXBK/rotor/mylogfile.2019-06-13_13-45-14.log mylogfile
159+
#> 2 /tmp/Rtmpg6uXBK/rotor/mylogfile.2019-06-13--13-45-14.log mylogfile
160+
#> 5 /tmp/Rtmpg6uXBK/rotor/mylogfile.20190613T134514.log mylogfile
161+
#> 3 /tmp/Rtmpg6uXBK/rotor/mylogfile.2019-06-13.log mylogfile
162+
#> 4 /tmp/Rtmpg6uXBK/rotor/mylogfile.2019-06.log mylogfile
163163
#> sfx ext size isdir mode mtime
164-
#> 1 2019-05-31_06-48-27 log 26 FALSE 664 2019-05-31 06:48:27
165-
#> 2 2019-05-31--06-48-27 log 26 FALSE 664 2019-05-31 06:48:27
166-
#> 5 20190531T064827 log 26 FALSE 664 2019-05-31 06:48:27
167-
#> 3 2019-05-31 log 26 FALSE 664 2019-05-31 06:48:26
168-
#> 4 2019-05 log 26 FALSE 664 2019-05-31 06:48:26
164+
#> 1 2019-06-13_13-45-14 log 26 FALSE 664 2019-06-13 13:45:14
165+
#> 2 2019-06-13--13-45-14 log 26 FALSE 664 2019-06-13 13:45:14
166+
#> 5 20190613T134514 log 26 FALSE 664 2019-06-13 13:45:14
167+
#> 3 2019-06-13 log 26 FALSE 664 2019-06-13 13:45:14
168+
#> 4 2019-06 log 26 FALSE 664 2019-06-13 13:45:14
169169
#> ctime atime uid gid uname grname
170-
#> 1 2019-05-31 06:48:27 2019-05-31 06:48:27 1000 1000 hoelk hoelk
171-
#> 2 2019-05-31 06:48:27 2019-05-31 06:48:27 1000 1000 hoelk hoelk
172-
#> 5 2019-05-31 06:48:27 2019-05-31 06:48:27 1000 1000 hoelk hoelk
173-
#> 3 2019-05-31 06:48:26 2019-05-31 06:48:26 1000 1000 hoelk hoelk
174-
#> 4 2019-05-31 06:48:26 2019-05-31 06:48:26 1000 1000 hoelk hoelk
170+
#> 1 2019-06-13 13:45:14 2019-06-13 13:45:14 1032 1032 fleck fleck
171+
#> 2 2019-06-13 13:45:14 2019-06-13 13:45:14 1032 1032 fleck fleck
172+
#> 5 2019-06-13 13:45:14 2019-06-13 13:45:14 1032 1032 fleck fleck
173+
#> 3 2019-06-13 13:45:14 2019-06-13 13:45:14 1032 1032 fleck fleck
174+
#> 4 2019-06-13 13:45:14 2019-06-13 13:45:14 1032 1032 fleck fleck
175175
#> timestamp
176-
#> 1 2019-05-31 06:48:27
177-
#> 2 2019-05-31 06:48:27
178-
#> 5 2019-05-31 06:48:27
179-
#> 3 2019-05-31 00:00:00
180-
#> 4 2019-05-01 00:00:00
176+
#> 1 2019-06-13 13:45:14
177+
#> 2 2019-06-13 13:45:14
178+
#> 5 2019-06-13 13:45:14
179+
#> 3 2019-06-13 00:00:00
180+
#> 4 2019-06-01 00:00:00
181181
```
182182

183183
If we examine the “timestamp” column in the example above, we see that
184184
missing date information is always interpreted as the start of the
185185
period; i.e. so `"2019-01"` is equivalent to `"2019-01-01--00--00--00"`
186-
for all intentds and purposes.
186+
for all intents and purposes.
187187

188188
``` r
189189
prune_backups(tf, max_backups = 0) # cleanup

cran-comments.md

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,7 @@
77

88
## R CMD check results
99

10-
0 errors | 0 warnings | 1 note
10+
0 errors | 0 warnings | 0 notes
1111

12-
* fleshed out R6 API
13-
* fixed edge-case bug on macOS related to timezones
14-
* new features and bugfixes
12+
maintenance release with saner default behaviour for rotate() and backup() if
13+
no backups exist yet

docs/404.html

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/LICENSE-text.html

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/LICENSE.html

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/authors.html

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/index.html

Lines changed: 31 additions & 31 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)