mirror of
https://github.com/wolfcw/libfaketime.git
synced 2026-05-17 08:36:28 +03:00
10
README
10
README
@@ -1,6 +1,6 @@
|
||||
=======================================================
|
||||
libfaketime, version 0.9.6 (June 2014)
|
||||
(previously also know as FakeTime Preload Library)
|
||||
(previously also known as FakeTime Preload Library)
|
||||
=======================================================
|
||||
|
||||
|
||||
@@ -236,7 +236,7 @@ This command line makes sure FTPL gets loaded and sets the faked time to
|
||||
15 days in the past.
|
||||
|
||||
Moreno Baricevic has contributed support for the FAKETIME_FMT environment
|
||||
variable, which allows to optionally set the strptime() format:
|
||||
variable, which allows you to optionally set the strptime() format:
|
||||
|
||||
Some simple examples:
|
||||
LD_PRELOAD=./libfaketime.so.1 FAKETIME_FMT=%s FAKETIME="`date +%s -d'1 year ago'`" date
|
||||
@@ -283,7 +283,7 @@ FAKETIME="+1y i2,0"
|
||||
will make the clock step two seconds per each time(), etc. call, running
|
||||
completely independently of the system clock. It helps running programs
|
||||
with some determinism. In this single case all spawned processes will use
|
||||
the same global clock without restaring it at the start of each process.
|
||||
the same global clock without restarting it at the start of each process.
|
||||
|
||||
For testing, your should run a command like
|
||||
|
||||
@@ -525,8 +525,8 @@ functionality has been added by Balint Reczey in v0.9.5.
|
||||
5. License
|
||||
----------
|
||||
|
||||
libfaketime has been released under the GNU Public License, GPL. Please see the
|
||||
included COPYING file.
|
||||
libfaketime has been released under the GNU General Public License, GPL.
|
||||
Please see the included COPYING file.
|
||||
|
||||
|
||||
6. Contact
|
||||
|
||||
@@ -16,7 +16,7 @@ completely done via Github:
|
||||
- The "master" branch is updated with tested code only; it is ensured that
|
||||
it compiles and works cleanly at least on current Linux and OS X systems.
|
||||
|
||||
Code contributions are highly welcome, preferrably via pull requests on Github.
|
||||
Code contributions are highly welcome, preferably via pull requests on Github.
|
||||
|
||||
|
||||
CODE STYLE
|
||||
|
||||
@@ -36,7 +36,7 @@ faketime '2008-12-24 08:15:42' /bin/date
|
||||
faketime -f '+2,5y x10,0' /bin/bash -c 'date; while true; do echo $SECONDS ; sleep 1 ; done'
|
||||
faketime -f '+2,5y x0,50' /bin/bash -c 'date; while true; do echo $SECONDS ; sleep 1 ; done'
|
||||
faketime -f '+2,5y i2,0' /bin/bash -c 'while true; do date ; sleep 1 ; done'
|
||||
In this single case all spawned processes will use the same global clock without restaring it at the start of each process.
|
||||
In this single case all spawned processes will use the same global clock without restarting it at the start of each process.
|
||||
|
||||
(Please note that it depends on your locale settings whether . or , has to be used for fractional offsets)
|
||||
.fi
|
||||
@@ -59,7 +59,7 @@ When using relative time offsets or start-at timestamps (see ADVANCED TIMESTAMP
|
||||
.PP
|
||||
Faking times for multiple programs or even system-wide can be simplified by using ~/.faketimerc files and /etc/faketimerc. Please refer to the README that came with faketime for warnings and details.
|
||||
.SH AUTHOR
|
||||
Please see the README and NEWS files for contributers.
|
||||
Please see the README and NEWS files for contributors.
|
||||
.SH BUGS
|
||||
Due to limitations of the LD_PRELOAD mechanism, faketime will not work with suidroot and statically linked programs.
|
||||
While timestamps and time offsets will work for child processes, speeding the clock up or slowing it down might not
|
||||
|
||||
@@ -83,7 +83,7 @@ void usage(const char *name)
|
||||
"%s -f '+2,5y x0,50' /bin/bash -c 'date; while true; do echo $SECONDS ; sleep 1 ; done'\n"
|
||||
"%s -f '+2,5y i2,0' /bin/bash -c 'date; while true; do date; sleep 1 ; done'\n"
|
||||
"In this single case all spawned processes will use the same global clock\n"
|
||||
"without restaring it at the start of each process.\n\n"
|
||||
"without restarting it at the start of each process.\n\n"
|
||||
"(Please note that it depends on your locale settings whether . or , has to be used for fractions)\n"
|
||||
"\n", name, name, name, name, name, name);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user