mirror of
https://github.com/beetbox/beets.git
synced 2025-12-29 03:52:51 +01:00
Move the relative date docs downward
It's important to introduce the .. syntax before we get here.
This commit is contained in:
parent
eaae3fbd30
commit
690ed731d8
1 changed files with 22 additions and 22 deletions
|
|
@ -164,28 +164,6 @@ Dates are written separated by hyphens, like ``year-month-day``, but the month
|
|||
and day are optional. If you leave out the day, for example, you will get
|
||||
matches for the whole month.
|
||||
|
||||
You can also use relative dates to the current time.
|
||||
It looks like ``-3w``, ``2m`` or ``-4d`` which means the date 3 weeks ago,
|
||||
the date 2 months from now and the date 4 days ago.
|
||||
A relative date consists of three parts:
|
||||
- ``+`` or ``-`` sign is optional and defaults to ``+``. The ``+`` sign will
|
||||
add a time quantity to the current date while the ``-`` sign will do the
|
||||
opposite
|
||||
- a number follows and indicates the amount to add or substract
|
||||
- a final letter ends and represents the amount in either days, weeks, months or
|
||||
years (``d``, ``w``, ``m`` or ``y``)
|
||||
|
||||
Please note that this relative calculation makes the assumption of 30 days per
|
||||
month and 365 days per year.
|
||||
|
||||
Here is an example that finds all the albums added between now and last week::
|
||||
|
||||
$ beet ls -a 'added:-1w..'
|
||||
|
||||
Find all items added in a 2 weeks period 4 weeks ago::
|
||||
|
||||
$ beet ls -a 'added:-6w..-4w'
|
||||
|
||||
Date *intervals*, like the numeric intervals described above, are separated by
|
||||
two dots (``..``). You can specify a start, an end, or both.
|
||||
|
||||
|
|
@ -239,6 +217,28 @@ queries do the same thing::
|
|||
$ beet ls 'added:2008-12-01t22:45:20'
|
||||
$ beet ls 'added:2008-12-01 22:45:20'
|
||||
|
||||
You can also use relative dates to the current time.
|
||||
It looks like ``-3w``, ``2m`` or ``-4d`` which means the date 3 weeks ago,
|
||||
the date 2 months from now and the date 4 days ago.
|
||||
A relative date consists of three parts:
|
||||
- ``+`` or ``-`` sign is optional and defaults to ``+``. The ``+`` sign will
|
||||
add a time quantity to the current date while the ``-`` sign will do the
|
||||
opposite
|
||||
- a number follows and indicates the amount to add or substract
|
||||
- a final letter ends and represents the amount in either days, weeks, months or
|
||||
years (``d``, ``w``, ``m`` or ``y``)
|
||||
|
||||
Please note that this relative calculation makes the assumption of 30 days per
|
||||
month and 365 days per year.
|
||||
|
||||
Here is an example that finds all the albums added between now and last week::
|
||||
|
||||
$ beet ls -a 'added:-1w..'
|
||||
|
||||
Find all items added in a 2 weeks period 4 weeks ago::
|
||||
|
||||
$ beet ls -a 'added:-6w..-4w'
|
||||
|
||||
.. _not_query:
|
||||
|
||||
Query Term Negation
|
||||
|
|
|
|||
Loading…
Reference in a new issue