Skip to content

Commit

Permalink
feat: adds hash comparing calculated from metadata collected from the…
Browse files Browse the repository at this point in the history
… file.

- Now we compare works when using csv cache only when two works hashes calculated from its' metadata are different; otherwise,  we get a compare result from csv;
- All CLI arguments that have the 'Path' type now resolve to absolute paths;
- Now, when we compare local works, we get modification dates from the system;
- Bumped the util version.

Refs: #196.
  • Loading branch information
Artanias authored Aug 9, 2024
1 parent 303a0f2 commit a2a0800
Show file tree
Hide file tree
Showing 22 changed files with 306 additions and 243 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
UTIL_VERSION := 0.4.11
UTIL_VERSION := 0.5.0
UTIL_NAME := codeplag
PWD := $(shell pwd)

Expand Down
83 changes: 41 additions & 42 deletions locales/codeplag.pot
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: codeplag 0.4.11\n"
"Project-Id-Version: codeplag 0.5.0\n"
"Report-Msgid-Bugs-To: EMAIL@ADDRESS\n"
"POT-Creation-Date: 2024-07-13 23:45+0300\n"
"POT-Creation-Date: 2024-08-04 12:33+0300\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: Artyom Semidolin\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
Expand All @@ -17,175 +17,175 @@ msgstr ""
"Content-Transfer-Encoding: 8bit\n"
"Generated-By: Babel 2.15.0\n"

#: src/codeplag/codeplagcli.py:45
#: src/codeplag/codeplagcli.py:46
msgid "You cannot specify the same value multiple times. You provided '{values}'."
msgstr ""

#: src/codeplag/codeplagcli.py:62
#: src/codeplag/codeplagcli.py:63
msgid "Directory '{path}' not found or not a directory."
msgstr ""

#: src/codeplag/codeplagcli.py:77
#: src/codeplag/codeplagcli.py:78
msgid "File '{path}' not found or not a file."
msgstr ""

#: src/codeplag/codeplagcli.py:89
#: src/codeplag/codeplagcli.py:90
msgid "Modifies and shows static settings of the '{util_name}' util."
msgstr ""

#: src/codeplag/codeplagcli.py:95
#: src/codeplag/codeplagcli.py:96
msgid "Settings commands of the '{util_name}' util."
msgstr ""

#: src/codeplag/codeplagcli.py:106
#: src/codeplag/codeplagcli.py:107
msgid "Manage the '{util_name}' util settings."
msgstr ""

#: src/codeplag/codeplagcli.py:113
#: src/codeplag/codeplagcli.py:114
msgid "Path to the environment file with GitHub access token."
msgstr ""

#: src/codeplag/codeplagcli.py:119
#: src/codeplag/codeplagcli.py:120
msgid "If defined, then saves reports about suspect works into provided path."
msgstr ""

#: src/codeplag/codeplagcli.py:128
#: src/codeplag/codeplagcli.py:129
msgid "Extension of saved report files."
msgstr ""

#: src/codeplag/codeplagcli.py:135
#: src/codeplag/codeplagcli.py:136
msgid "Show progress of searching plagiarism."
msgstr ""

#: src/codeplag/codeplagcli.py:142
#: src/codeplag/codeplagcli.py:143
msgid ""
"Threshold of analyzer which classifies two work as same. If this number "
"is too large, such as 99, then completely matching jobs will be found. "
"Otherwise, if this number is small, such as 50, then all work with "
"minimal similarity will be found."
msgstr ""

#: src/codeplag/codeplagcli.py:156
#: src/codeplag/codeplagcli.py:157
msgid "The language of help messages, generated reports, errors."
msgstr ""

#: src/codeplag/codeplagcli.py:162
#: src/codeplag/codeplagcli.py:163
msgid ""
"Sets the threshold for the '{util_name}' util loggers'. Logging messages "
"that are less severe than the level will be ignored."
msgstr ""

#: src/codeplag/codeplagcli.py:172
#: src/codeplag/codeplagcli.py:173
msgid "The maximum number of processes that can be used to compare works."
msgstr ""

#: src/codeplag/codeplagcli.py:182
#: src/codeplag/codeplagcli.py:183
msgid "Show the '{util_name}' util settings."
msgstr ""

#: src/codeplag/codeplagcli.py:186
#: src/codeplag/codeplagcli.py:187
msgid "Start searching similar works."
msgstr ""

#: src/codeplag/codeplagcli.py:192
#: src/codeplag/codeplagcli.py:193
msgid "Absolute or relative path to a local directories with project files."
msgstr ""

#: src/codeplag/codeplagcli.py:204
#: src/codeplag/codeplagcli.py:205
msgid "Absolute or relative path to files on a computer."
msgstr ""

#: src/codeplag/codeplagcli.py:211
#: src/codeplag/codeplagcli.py:212
msgid ""
"Choose one of the following modes of searching plagiarism. The "
"'many_to_many' mode may require more free memory."
msgstr ""

#: src/codeplag/codeplagcli.py:222
#: src/codeplag/codeplagcli.py:223
msgid ""
"A regular expression for filtering checked works by name. Used with "
"options 'directories', 'github-user' and 'github-project-folders'."
msgstr ""

#: src/codeplag/codeplagcli.py:231
#: src/codeplag/codeplagcli.py:232
msgid "Ignore the threshold when checking of works."
msgstr ""

#: src/codeplag/codeplagcli.py:238
#: src/codeplag/codeplagcli.py:239
msgid "Extension responsible for the analyzed programming language."
msgstr ""

#: src/codeplag/codeplagcli.py:248
#: src/codeplag/codeplagcli.py:249
msgid "Searching in all branches."
msgstr ""

#: src/codeplag/codeplagcli.py:255
#: src/codeplag/codeplagcli.py:256
msgid "A regular expression to filter searching repositories on GitHub."
msgstr ""

#: src/codeplag/codeplagcli.py:262
#: src/codeplag/codeplagcli.py:263
msgid "URL to file in a GitHub repository."
msgstr ""

#: src/codeplag/codeplagcli.py:268
#: src/codeplag/codeplagcli.py:269
msgid "GitHub organization/user name."
msgstr ""

#: src/codeplag/codeplagcli.py:275
#: src/codeplag/codeplagcli.py:276
msgid "URL to a GitHub project folder."
msgstr ""

#: src/codeplag/codeplagcli.py:285
#: src/codeplag/codeplagcli.py:286
msgid ""
"Handling generated by the {util_name} reports as creating html report "
"file or show it on console."
msgstr ""

#: src/codeplag/codeplagcli.py:293
#: src/codeplag/codeplagcli.py:294
msgid "Report commands of the '{util_name}' util."
msgstr ""

#: src/codeplag/codeplagcli.py:304
#: src/codeplag/codeplagcli.py:305
msgid "Generate general report from created some time ago report files."
msgstr ""

#: src/codeplag/codeplagcli.py:309
#: src/codeplag/codeplagcli.py:310
msgid ""
"Path to save generated report. If it's a directory, then create a file in"
" it."
msgstr ""

#: src/codeplag/codeplagcli.py:319
#: src/codeplag/codeplagcli.py:320
msgid "Type of the created report file."
msgstr ""

#: src/codeplag/codeplagcli.py:329
#: src/codeplag/codeplagcli.py:330
msgid ""
"Program help to find similar parts of source codes for the different "
"languages."
msgstr ""

#: src/codeplag/codeplagcli.py:337
#: src/codeplag/codeplagcli.py:338
msgid "Print current version number and exit."
msgstr ""

#: src/codeplag/codeplagcli.py:343
#: src/codeplag/codeplagcli.py:344
msgid "Commands help."
msgstr ""

#: src/codeplag/codeplagcli.py:359
#: src/codeplag/codeplagcli.py:360
msgid "No command is provided; please choose one from the available (--help)."
msgstr ""

#: src/codeplag/codeplagcli.py:374
#: src/codeplag/codeplagcli.py:375
msgid "There is nothing to modify; please provide at least one argument."
msgstr ""

#: src/codeplag/codeplagcli.py:379
#: src/codeplag/codeplagcli.py:380
msgid "The'repo-regexp' option requires the provided 'github-user' option."
msgstr ""

#: src/codeplag/codeplagcli.py:389
#: src/codeplag/codeplagcli.py:390
msgid ""
"The'path-regexp' option requires the provided 'directories', 'github-"
"user', or 'github-project-folder' options."
Expand Down Expand Up @@ -299,4 +299,3 @@ msgstr ""
#: src/templates/sources.templ:68
msgid "Part of a similar file"
msgstr ""

Loading

0 comments on commit a2a0800

Please sign in to comment.