New -find action "set_to_mtime"
This commit is contained in:
parent
b27bd93c2f
commit
ff65d7bb19
@ -182,6 +182,7 @@ struct FindjoB {
|
|||||||
56= like 54 but tolerating existing truncated names
|
56= like 54 but tolerating existing truncated names
|
||||||
57= like 55 but tolerating existing truncated names
|
57= like 55 but tolerating existing truncated names
|
||||||
58= internal: last_data_file_block
|
58= internal: last_data_file_block
|
||||||
|
59= set_to_mtime
|
||||||
*/
|
*/
|
||||||
int action;
|
int action;
|
||||||
int prune;
|
int prune;
|
||||||
|
@ -2431,6 +2431,19 @@ ex:;
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
int Xorriso_set_to_mtime(struct XorrisO *xorriso, char *show_path,
|
||||||
|
IsoNode *node, int flag)
|
||||||
|
{
|
||||||
|
time_t t;
|
||||||
|
|
||||||
|
t= iso_node_get_mtime(node);
|
||||||
|
iso_node_set_atime(node, t);
|
||||||
|
iso_node_set_ctime(node, t);
|
||||||
|
Xorriso_set_change_pending(xorriso, 0);
|
||||||
|
return(1);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
int Xorriso_cannot_create_iter(struct XorrisO *xorriso, int iso_error,int flag)
|
int Xorriso_cannot_create_iter(struct XorrisO *xorriso, int iso_error,int flag)
|
||||||
{
|
{
|
||||||
Xorriso_process_msg_queues(xorriso,0);
|
Xorriso_process_msg_queues(xorriso,0);
|
||||||
@ -2880,6 +2893,9 @@ int Xorriso_findi_action(struct XorrisO *xorriso, struct FindjoB *job,
|
|||||||
ret= Xorriso_report_lba(xorriso, show_path, node,
|
ret= Xorriso_report_lba(xorriso, show_path, node,
|
||||||
&job->last_data_file_block, 2);
|
&job->last_data_file_block, 2);
|
||||||
|
|
||||||
|
} else if(action == 59) { /* set_to_mtime */
|
||||||
|
ret= Xorriso_set_to_mtime(xorriso, show_path, node, 0);
|
||||||
|
|
||||||
} else { /* includes : 15 in_iso */
|
} else { /* includes : 15 in_iso */
|
||||||
Xorriso_esc_filepath(xorriso, show_path, xorriso->result_line, 0);
|
Xorriso_esc_filepath(xorriso, show_path, xorriso->result_line, 0);
|
||||||
strcat(xorriso->result_line, "\n");
|
strcat(xorriso->result_line, "\n");
|
||||||
|
@ -1104,6 +1104,10 @@ not_enough_exec_arguments:;
|
|||||||
Xorriso_no_findjob(xorriso, "-find -exec alter_date_r", 0);
|
Xorriso_no_findjob(xorriso, "-find -exec alter_date_r", 0);
|
||||||
goto ex;
|
goto ex;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
} else if(strcmp(cpt, "set_to_mtime") == 0) {
|
||||||
|
Findjob_set_action_target(job, 59, NULL, 0);
|
||||||
|
|
||||||
} else if(strcmp(cpt, "lsdl")==0) {
|
} else if(strcmp(cpt, "lsdl")==0) {
|
||||||
Findjob_set_action_target(job, 8, NULL, 0);
|
Findjob_set_action_target(job, 8, NULL, 0);
|
||||||
|
|
||||||
@ -2022,9 +2026,9 @@ int Xorriso_option_help(struct XorrisO *xorriso, int flag)
|
|||||||
" -prune, -decision yes|no, -true, -false",
|
" -prune, -decision yes|no, -true, -false",
|
||||||
" Operators: -not, -or, -and, -sub, (, -subend, ),",
|
" Operators: -not, -or, -and, -sub, (, -subend, ),",
|
||||||
" -if, -then, -elseif, -else, -endif",
|
" -if, -then, -elseif, -else, -endif",
|
||||||
" Action may be one of: echo, chown, chown_r, chgrp, chgrp_r",
|
" Action may be one of: echo, chown, chown_r, chgrp, chgrp_r,",
|
||||||
" chmod, chmod_r, alter_date, alter_date_r, lsdl, compare,",
|
" chmod, chmod_r, alter_date, alter_date_r, set_to_mtime,",
|
||||||
" rm, rm_r, compare, update, report_damage,",
|
" lsdl, compare, rm, rm_r, compare, update, report_damage,",
|
||||||
" report_lba, report_sections,",
|
" report_lba, report_sections,",
|
||||||
" getfacl, setfacl, getfattr, setfattr, get_any_xattr,",
|
" getfacl, setfacl, getfattr, setfattr, get_any_xattr,",
|
||||||
" list_extattr, get_md5, check_md5, make_md5,",
|
" list_extattr, get_md5, check_md5, make_md5,",
|
||||||
|
@ -9,7 +9,7 @@
|
|||||||
.\" First parameter, NAME, should be all caps
|
.\" First parameter, NAME, should be all caps
|
||||||
.\" Second parameter, SECTION, should be 1-8, maybe w/ subsection
|
.\" Second parameter, SECTION, should be 1-8, maybe w/ subsection
|
||||||
.\" other parameters are allowed: see man(7), man(1)
|
.\" other parameters are allowed: see man(7), man(1)
|
||||||
.TH XORRISO 1 "Version 1.4.5, Aug 15, 2016"
|
.TH XORRISO 1 "Version 1.4.5, Aug 20, 2016"
|
||||||
.\" Please adjust this date whenever revising the manpage.
|
.\" Please adjust this date whenever revising the manpage.
|
||||||
.\"
|
.\"
|
||||||
.\" Some roff macros, for reference:
|
.\" Some roff macros, for reference:
|
||||||
@ -2027,6 +2027,9 @@ character and a timestring as parameters.
|
|||||||
.br
|
.br
|
||||||
E.g.: \-exec alter_date "m" "Dec 30 19:34:12 2007" \-\-
|
E.g.: \-exec alter_date "m" "Dec 30 19:34:12 2007" \-\-
|
||||||
.br
|
.br
|
||||||
|
\fBset_to_mtime\fR
|
||||||
|
sets the ctime and atime to the value found in mtime.
|
||||||
|
.br
|
||||||
\fBlsdl\fR
|
\fBlsdl\fR
|
||||||
prints file information like shell command ls \-dl.
|
prints file information like shell command ls \-dl.
|
||||||
.br
|
.br
|
||||||
|
@ -1732,16 +1732,18 @@ File: xorriso.info, Node: CmdFind, Next: Filter, Prev: Manip, Up: Commands
|
|||||||
chown and chown_r
|
chown and chown_r
|
||||||
change the ownership and get the user id as parameter. E.g.:
|
change the ownership and get the user id as parameter. E.g.:
|
||||||
-exec chown thomas --
|
-exec chown thomas --
|
||||||
chgrp and Bchgrp_r
|
chgrp and chgrp_r
|
||||||
change the group attribute and get the group id as parameter.
|
change the group attribute and get the group id as parameter.
|
||||||
E.g.: -exec chgrp_r staff --
|
E.g.: -exec chgrp_r staff --
|
||||||
chmod and chmod_r
|
chmod and chmod_r
|
||||||
change access permissions and get a mode string as parameter.
|
change access permissions and get a mode string as parameter.
|
||||||
E.g.: -exec chmod a-w,a+r --
|
E.g.: -exec chmod a-w,a+r --
|
||||||
Balter_date and Balter_date_r
|
alter_date and alter_date_r
|
||||||
change the timestamps. They get a type character and a
|
change the timestamps. They get a type character and a
|
||||||
timestring as parameters.
|
timestring as parameters.
|
||||||
E.g.: -exec alter_date "m" "Dec 30 19:34:12 2007" --
|
E.g.: -exec alter_date "m" "Dec 30 19:34:12 2007" --
|
||||||
|
set_to_mtime
|
||||||
|
sets the ctime and atime to the value found in mtime.
|
||||||
lsdl
|
lsdl
|
||||||
prints file information like shell command ls -dl.
|
prints file information like shell command ls -dl.
|
||||||
compare
|
compare
|
||||||
@ -5721,44 +5723,44 @@ Node: Insert52745
|
|||||||
Node: SetInsert63329
|
Node: SetInsert63329
|
||||||
Node: Manip72648
|
Node: Manip72648
|
||||||
Node: CmdFind82607
|
Node: CmdFind82607
|
||||||
Node: Filter100910
|
Node: Filter100989
|
||||||
Node: Writing105532
|
Node: Writing105611
|
||||||
Node: SetWrite115688
|
Node: SetWrite115767
|
||||||
Node: Bootable140273
|
Node: Bootable140352
|
||||||
Node: Jigdo165009
|
Node: Jigdo165088
|
||||||
Node: Charset169268
|
Node: Charset169347
|
||||||
Node: Exception172597
|
Node: Exception172676
|
||||||
Node: DialogCtl178726
|
Node: DialogCtl178805
|
||||||
Node: Inquiry181328
|
Node: Inquiry181407
|
||||||
Node: Navigate190116
|
Node: Navigate190195
|
||||||
Node: Verify198411
|
Node: Verify198490
|
||||||
Node: Restore208289
|
Node: Restore208368
|
||||||
Node: Emulation216902
|
Node: Emulation216981
|
||||||
Node: Scripting227361
|
Node: Scripting227440
|
||||||
Node: Frontend235144
|
Node: Frontend235223
|
||||||
Node: Examples244770
|
Node: Examples244849
|
||||||
Node: ExDevices245948
|
Node: ExDevices246027
|
||||||
Node: ExCreate246609
|
Node: ExCreate246688
|
||||||
Node: ExDialog247909
|
Node: ExDialog247988
|
||||||
Node: ExGrowing249180
|
Node: ExGrowing249259
|
||||||
Node: ExModifying249989
|
Node: ExModifying250068
|
||||||
Node: ExBootable250499
|
Node: ExBootable250578
|
||||||
Node: ExCharset251054
|
Node: ExCharset251133
|
||||||
Node: ExPseudo251950
|
Node: ExPseudo252029
|
||||||
Node: ExCdrecord252877
|
Node: ExCdrecord252956
|
||||||
Node: ExMkisofs253197
|
Node: ExMkisofs253276
|
||||||
Node: ExGrowisofs254554
|
Node: ExGrowisofs254633
|
||||||
Node: ExException255708
|
Node: ExException255787
|
||||||
Node: ExTime256166
|
Node: ExTime256245
|
||||||
Node: ExIncBackup256624
|
Node: ExIncBackup256703
|
||||||
Node: ExRestore260650
|
Node: ExRestore260729
|
||||||
Node: ExRecovery261596
|
Node: ExRecovery261675
|
||||||
Node: Files262168
|
Node: Files262247
|
||||||
Node: Environ263502
|
Node: Environ263581
|
||||||
Node: Seealso264194
|
Node: Seealso264273
|
||||||
Node: Bugreport264911
|
Node: Bugreport264990
|
||||||
Node: Legal265502
|
Node: Legal265581
|
||||||
Node: CommandIdx266514
|
Node: CommandIdx266593
|
||||||
Node: ConceptIdx283702
|
Node: ConceptIdx283781
|
||||||
|
|
||||||
End Tag Table
|
End Tag Table
|
||||||
|
@ -50,7 +50,7 @@
|
|||||||
@c man .\" First parameter, NAME, should be all caps
|
@c man .\" First parameter, NAME, should be all caps
|
||||||
@c man .\" Second parameter, SECTION, should be 1-8, maybe w/ subsection
|
@c man .\" Second parameter, SECTION, should be 1-8, maybe w/ subsection
|
||||||
@c man .\" other parameters are allowed: see man(7), man(1)
|
@c man .\" other parameters are allowed: see man(7), man(1)
|
||||||
@c man .TH XORRISO 1 "Version 1.4.5, Aug 15, 2016"
|
@c man .TH XORRISO 1 "Version 1.4.5, Aug 20, 2016"
|
||||||
@c man .\" Please adjust this date whenever revising the manpage.
|
@c man .\" Please adjust this date whenever revising the manpage.
|
||||||
@c man .\"
|
@c man .\"
|
||||||
@c man .\" Some roff macros, for reference:
|
@c man .\" Some roff macros, for reference:
|
||||||
@ -2417,7 +2417,7 @@ as parameter. E.g.: -exec chown thomas @minus{}@minus{}
|
|||||||
@*
|
@*
|
||||||
@c man \fBchgrp\fR and \fBchgrp_r\fR
|
@c man \fBchgrp\fR and \fBchgrp_r\fR
|
||||||
@c man-ignore-lines 1
|
@c man-ignore-lines 1
|
||||||
@item chgrp and Bchgrp_r
|
@item chgrp and chgrp_r
|
||||||
change the group attribute and get the group id
|
change the group attribute and get the group id
|
||||||
as parameter. E.g.: -exec chgrp_r staff @minus{}@minus{}
|
as parameter. E.g.: -exec chgrp_r staff @minus{}@minus{}
|
||||||
@*
|
@*
|
||||||
@ -2429,12 +2429,17 @@ as parameter. E.g.: -exec chmod a-w,a+r @minus{}@minus{}
|
|||||||
@*
|
@*
|
||||||
@c man \fBalter_date\fR and \fBalter_date_r\fR
|
@c man \fBalter_date\fR and \fBalter_date_r\fR
|
||||||
@c man-ignore-lines 1
|
@c man-ignore-lines 1
|
||||||
@item Balter_date and Balter_date_r
|
@item alter_date and alter_date_r
|
||||||
change the timestamps. They get a type
|
change the timestamps. They get a type
|
||||||
character and a timestring as parameters.
|
character and a timestring as parameters.
|
||||||
@*
|
@*
|
||||||
E.g.: -exec alter_date "m" "Dec 30 19:34:12 2007" @minus{}@minus{}
|
E.g.: -exec alter_date "m" "Dec 30 19:34:12 2007" @minus{}@minus{}
|
||||||
@*
|
@*
|
||||||
|
@c man \fBset_to_mtime\fR
|
||||||
|
@c man-ignore-lines 1
|
||||||
|
@item set_to_mtime
|
||||||
|
sets the ctime and atime to the value found in mtime.
|
||||||
|
@*
|
||||||
@item lsdl
|
@item lsdl
|
||||||
prints file information like shell command ls -dl.
|
prints file information like shell command ls -dl.
|
||||||
@*
|
@*
|
||||||
|
@ -1 +1 @@
|
|||||||
#define Xorriso_timestamP "2016.08.16.131907"
|
#define Xorriso_timestamP "2016.08.20.085236"
|
||||||
|
Loading…
Reference in New Issue
Block a user