Commit Graph

13803 Commits

Author SHA1 Message Date
Yury V. Zaytsev
940fab955c maint: shorten commit hash if git describe fails
Signed-off-by: Yury V. Zaytsev <yury@shurup.com>
2016-12-25 10:06:23 +04:00
Mooffie
d376f0ca43 extfs: hp48: add tests. 2016-12-25 10:06:23 +04:00
Mooffie
4557ee3c7a extfs: hp48: make it testable. 2016-12-25 10:06:23 +04:00
Mooffie
c91476ac4a Ticket #3729: extfs: hp48: fix date format.
Use "MM-DD-YYYY hh:mm" instead of "Mon DD YYYY hh:mm".

Note: we assign to $NOW at the top-level, not inside hp48_parser(), because the
communication is slow and we don't want each recursive call to hp48_parser() to
potentially print a different time.
2016-12-25 10:06:23 +04:00
Mooffie
019ab5c012 extfs: hp48: misc fixes.
Two bugs fixed:

* "printf -rw-r--r--" made printf complain about invalid option (although
  changing it to "printf -- -rw-r--r-" is possible, we don't know how portble
  this is).

* Quotes around $INPUT defeat the purpose of the function calls (botched in
  commit 61b4642af4).
2016-12-25 10:06:23 +04:00
Mooffie
4d04aa40b0 extfs: hp48: documentation: explain the reply to the DIRECTORY command.
It was not at all easy to find a sample reply on the internet (the one found
was in a screenshot actually), so we record it here.
2016-12-25 10:06:23 +04:00
Mooffie
644682ad2c extfs: uarc: add tests. 2016-12-25 10:06:23 +04:00
Mooffie
22846550d3 extfs: uarc: make it testable. 2016-12-25 10:06:23 +04:00
Mooffie
61eb5cca37 Ticket #3729: extfs: uarc: fix date format.
Use "MM-DD-YYYY hh:mm" instead of "Mon DD YYYY hh:mm".
2016-12-25 10:06:23 +04:00
Mooffie
0e4e80cf79 extfs: uace: add tests. 2016-12-25 10:06:23 +04:00
Mooffie
057ba6d73a extfs: uace: make it testable. 2016-12-25 10:06:22 +04:00
Mooffie
5225a1d21b extfs: uace: documentation: clarify versions issue. 2016-12-25 10:06:22 +04:00
Mooffie
08a8621fc5 extfs: uace: print the correct file size.
As a comment in that file notes: 3'rd column is the compressed size, 4'th
column is the actual size.
2016-12-25 10:06:22 +04:00
Mooffie
105501ba9c Ticket #3729: extfs: uace: fix date format.
Use "MM-DD-YYYY hh:mm" instead of "Mon DD YYYY hh:mm".
2016-12-25 10:06:22 +04:00
Andrew Borodin
4a6fb3b534 Merge branch '3575_nanoseconds'
* 3575_nanoseconds:
  FISH VFS: generate timestamps with nanosecond precision for touch.
  (fish_utime): avoid buffer overflow: allocate buffer for command dynamically.
  Ticket #3575: preserve timestamps with nanosecond precisions during file copy
2016-12-25 08:47:47 +03:00
Andrey Gursky
0075944f1e FISH VFS: generate timestamps with nanosecond precision for touch.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-12-25 08:46:10 +03:00
Andrew Borodin
53a1d52ed9 (fish_utime): avoid buffer overflow: allocate buffer for command dynamically.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-12-25 08:46:10 +03:00
Andrey Gursky
4c418047b2 Ticket #3575: preserve timestamps with nanosecond precisions during file copy
MC truncates timestamps during file copy and drops sub-second precision.

Make use of utimensat(), introduced in Linux kernel 2.6.22 (and since
2.6.26 compatible with POSIX-1.2008).

Signed-off-by: Andrey Gursky <andrey.gursky@e-mail.ua>
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-12-25 08:46:10 +03:00
Yury V. Zaytsev
9f47eecc91 Merge branch '3744_u7z_tests' 2016-12-24 15:30:50 +04:00
Mooffie
d4ec872f37 Ticket #3744: extfs: u7z: add tests. 2016-12-24 09:58:53 +04:00
Mooffie
fad265c5bd Ticket #3744: extfs: u7z: make it testable. 2016-12-24 09:58:53 +04:00
Yury V. Zaytsev
12dbd957c0 Merge branch '2707_extfs_u7z' 2016-12-24 09:46:13 +04:00
Mooffie
f84c14bbce Ticket #2707: extfs: u7z: print() cleanup.
AWK's print() already writes OFS between expressions.
2016-12-24 09:45:59 +04:00
Mooffie
052bdec1ee Ticket #2707: extfs: u7z: sed portability.
'\s' is not portable.
2016-12-24 09:45:59 +04:00
Mooffie
5c3e999845 Ticket #2707: extfs: u7z: handle missing size.
The uncompressed size may be missing in 7z's output (gods know why). We use the
compressed size in this case.
2016-12-24 09:45:58 +04:00
Mooffie
02051d6090 Ticket #2707: extfs: u7z: make the code more readable. 2016-12-24 09:45:58 +04:00
Yury V. Zaytsev
66ae617b77 extfs: fix whitespace soup in u7z helper
Signed-off-by: Yury V. Zaytsev <yury.zaytsev@moneymeets.com>
2016-12-24 09:45:58 +04:00
Yury V. Zaytsev
6938f1a52d Ticket #2707: extfs u7z helper - fix listing 7z archives w/o datetime info
7z archives can have entries without datetime info (7z a -mtm- ...). Currently,
u7z helper skips these entries. Fix this by detecting them and obtaining
archive file datetime using stat command with fallback to ls -lan.

Signed-off-by: Andreas Mohr <and@gmx.li>
Signed-off-by: Yury V. Zaytsev <yury.zaytsev@moneymeets.com>
2016-12-24 09:45:58 +04:00
Andrew Borodin
f1bc44943c Merge branch '3730_extfs_tester_fix'
* 3730_extfs_tester_fix:
  extfs: urar: don't invoke 'rar' when running under the tester.
  Ticket #3730: extfs: don't run tester on "make check" if disabled.
2016-12-20 13:05:44 +03:00
Mooffie
b8f7018725 extfs: urar: don't invoke 'rar' when running under the tester.
We want to prevent messages printed to STDERR when running the tester on
systems where rar is not installed.

(Yes, we could compress this new code to just one line, but...)

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-12-20 09:37:22 +03:00
Mooffie
2c17c7d28b Ticket #3730: extfs: don't run tester on "make check" if disabled.
If the extfs VFS is disabled, there's no point in building and running the
tester.

(The "SUBDIRS =" line isn't needed, but it looks tidier this way, especially if
we later add subdirs for testing the other VFSs.)

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-12-20 09:37:03 +03:00
Andrew Borodin
455316be9f tests/src/vfs/extfs/helpers-list/mc_parse_ls_l.c: fix warning:
tests/src/vfs/extfs/helpers-list/mc_parse_ls_l.c: In function 'string_date':
tests/src/vfs/extfs/helpers-list/mc_parse_ls_l.c:193:21: warning:
declaration of 'time' shadows a global declaration [-Wshadow]

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-12-19 13:26:48 +03:00
Andrew Borodin
403b43c05f AUTHORS: mooffie: extfs helpers tester.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-12-19 13:21:01 +03:00
Andrew Borodin
3a25b7198f Merge branch '3730_extfs_tester'
* 3730_extfs_tester:
  tests/src/vfs/extfs/helpers-list/Makefile.am: create run silently.
  Move extfs tester from tests/src/extfs-helpers-listcmd into tests/src/vfs/extfs/helpers-list.
  extfs: lslR: add tests.
  extfs: lslR: make it testable.
  extfs: urar: add tests.
  extfs: urar: make it testable.
  extfs: uzip: add tests.
  extfs: uzip: make it testable.
  extfs: uzoo: add tests.
  extfs: uzoo: make it testable.
  extfs: documentation for the tester.
  extfs: introduce a tester.
  Ticket #3730: extfs: introduce a command-line tool for parsing file lists.
2016-12-19 13:18:07 +03:00
Andrew Borodin
84cbca51af tests/src/vfs/extfs/helpers-list/Makefile.am: create run silently.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-12-19 09:39:48 +03:00
Andrew Borodin
9764511b08 Move extfs tester from tests/src/extfs-helpers-listcmd into tests/src/vfs/extfs/helpers-list.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-12-19 09:39:15 +03:00
Mooffie
96313b16bc extfs: lslR: add tests.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-12-16 10:14:41 +03:00
Mooffie
f2c8479a50 extfs: lslR: make it testable.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-12-16 10:14:41 +03:00
Mooffie
eded16b0e9 extfs: urar: add tests.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-12-16 10:14:41 +03:00
Mooffie
c88517b055 extfs: urar: make it testable.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-12-16 10:14:41 +03:00
Mooffie
5f4387cafb extfs: uzip: add tests.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-12-16 10:14:41 +03:00
Mooffie
88f3aeef24 extfs: uzip: make it testable.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-12-16 10:14:41 +03:00
Mooffie
849d3e8f9d extfs: uzoo: add tests.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-12-14 13:15:58 +03:00
Mooffie
66b43a6670 extfs: uzoo: make it testable.
Note how easy it is to make the helpers testable. MC_TEST_EXTFS_LIST_CMD is
explained in README.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-12-14 13:15:58 +03:00
Mooffie
a45c997696 extfs: documentation for the tester.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-12-14 13:15:58 +03:00
Mooffie
7a3891eb90 extfs: introduce a tester.
This tester tests that helpers implement the "list" command correctly.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-12-14 13:15:58 +03:00
Mooffie
13a805bd79 Ticket #3730: extfs: introduce a command-line tool for parsing file lists.
We introduce 'mc_parse_ls_l', a tool for parsing file-listings in format
similar to that of 'ls -l'. This format is used by the various extfs helpers.

We'll use this tool, in the next commit, to build a tester.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-12-14 13:15:29 +03:00
Andrew Borodin
4b28a7e76e Merge branch '3696_uzoo_datetime_format'
* 3696_uzoo_datetime_format:
  extfs: fix documentation of allowed date formats.
  Ticket #3693: fix listing of zoo archive entries.
2016-12-13 13:18:43 +03:00
Mooffie
12812968c0 extfs: fix documentation of allowed date formats.
We also improve the documentation of vfs_parse_filedate(), which does the
actual work.

Note that in the user-facing documentation (extfs/helpers/README) there are
two things we prefer *not* to mention about vfs_parse_filedate's ability:

* Accepting the format "MM-DD-YY hh:mm[:ss]", as this two-digit year is
  more likely to confuse readers of such dates.

* Accepting '/', instead of '-', as the separator in MM-DD-YYYY. (Considering
  that some scripts do use '/', maybe we should mention it?)

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-12-13 13:14:43 +03:00
Andrey Tataranovich
752a7e4454 Ticket #3693: fix listing of zoo archive entries.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-12-13 13:14:43 +03:00