Commit graph

3618 commits

Author SHA1 Message Date
Stig Inge Lea Bjørnsen
94aad7e309 Record mtimes instead of pre-import paths.
This adds support for move imports.

Item and file mtime preservation is now configurable and disabled by
default.
2014-05-14 00:05:44 +02:00
Stig Inge Lea Bjørnsen
0bf4222947 Add importmtimes plugin for preserving file mtimes during copy imports.
File modification times are stored as item.mtime, item.added and
album.added.
2014-05-14 00:05:44 +02:00
Adrian Sampson
a19e3f30b6 Back out a changelog entry
I usually don't add changelog bullets for project metadata---maybe this is
misguided, but it's nice to have everything be relevant to how beets itself
works so the changelog doesn't get too boring. I also don't list documentation
improvements, for example.
2014-05-13 10:17:44 -07:00
Stanislav Ochotnicky
395540f0cd [setup.py] Update optional plugin dependencies
echonest and mpdstats plugins need pyechonest and python-mpd respectively so
let's list them properly
2014-05-13 19:11:53 +02:00
Adrian Sampson
a8d3fd25b6 Changelog for #743: web display fixes
Closes #345. Fixes #741.
2014-05-12 22:45:21 -07:00
Adrian Sampson
5a1fa9e3f1 Merge pull request #743 from udiboy1209/master
Fix web plugin scroll and lyrics newline bug
2014-05-12 22:43:11 -07:00
udiboy1209
ac7646f0f4 Fix alignment of play button with logo 2014-05-11 19:21:50 +05:30
Adrian Sampson
1a25561907 Version bump: 1.3.7 2014-05-10 18:18:24 -07:00
Adrian Sampson
55e55a2065 Finalize changelog for 1.3.6 release 2014-05-10 18:12:25 -07:00
Adrian Sampson
40e1475a87 Release script: publish command 2014-05-10 17:57:23 -07:00
Adrian Sampson
06ab0ec2e2 Tiny wording tweaks for #754 2014-05-10 17:19:04 -07:00
Adrian Sampson
7310f6e945 Documentation tweaks for bucket (#747) 2014-05-10 17:14:35 -07:00
Adrian Sampson
74048d17e7 Merge branch 'master' of github.com:sampsyo/beets
Conflicts:
	docs/changelog.rst
2014-05-10 16:44:18 -07:00
Adrian Sampson
f0e03983e1 Update changelog for #753 2014-05-10 16:42:25 -07:00
Fabrice L.
6ba33c4a85 Update changelog.rst 2014-05-10 23:35:34 +02:00
Fabrice L.
0442e6648c Update bucket.rst 2014-05-10 23:34:52 +02:00
Fabrice L.
befc9746d9 Update pathformat.rst
mention bucket function
2014-05-10 23:28:59 +02:00
Fabrice L.
6515fb3095 Update changelog.rst 2014-05-10 23:23:25 +02:00
Fabrice L.
50ca2c683a Merge pull request #754 from KraYmer/doc_plugins_templ_funcs
doc: add section listing template functions/fields provided by plugins
2014-05-10 23:11:17 +02:00
Fabrice L.
c0f7e1fec4 Merge pull request #747 from KraYmer/issue740_buckets
Issue740: introduce bucket plugin to organize files in bucket directories
2014-05-10 23:04:28 +02:00
Adrian Sampson
95b1b2b043 Merge branch 'PierreRust-optimize-model-init' 2014-05-10 14:04:00 -07:00
Adrian Sampson
d48c604b2f Simplify model initialization shortcut
This avoids multiple paths to setting values. It also moves the buffer check
into PathType.normalize, where it belongs. This is slightly faster than the
previous iteration: about 8 vs. 9 seconds to list about 13k songs on my
machine.
2014-05-10 14:02:45 -07:00
Fabrice Laporte
02f7e78fd3 fix flake8 warnings 2014-05-10 10:57:44 +02:00
Fabrice Laporte
21feab7ab1 add tests to check bad buckets definitions
message is now printed to the user when buckets declared in the config
file cannot be parsed
2014-05-10 10:55:38 +02:00
Fabrice Laporte
1303f0a4df Merge branch 'doc_plugins_templ_funcs' of github.com:KraYmer/beets into doc_plugins_templ_funcs
Conflicts:
	docs/reference/pathformat.rst
2014-05-09 09:01:07 +02:00
Fabrice Laporte
c002e4599c Add text to new _templ_plugins section
Replace links to ‘writing-plugin’ by internal links to ‘templ_plugins’.
Add small paragraph at the end of _templ_plugins to mention ‘inline’
plugin and the ‘Writing Plugins’ page.
2014-05-09 08:59:22 +02:00
Pierre Rust
505add7e5c Avoid duplicating _bulk_update into subclasses 2014-05-09 08:51:10 +02:00
Fabrice L.
c5babea31f fix typo from copy/paste 2014-05-08 22:27:21 +02:00
Fabrice Laporte
d8008e145f Add section listing template functions/fields provided by plugins for path
formatting
2014-05-08 22:05:26 +02:00
Fabrice Laporte
0d5050bdce fix handling of digits chars in alpha buckets
Characters were search in string.ascii_lowercase that does not contain
digits chars.
2014-05-08 16:13:17 +02:00
Pierre Rust
0799ad16c4 Merge remote-tracking branch 'origin/master' into optimize-model-init 2014-05-08 10:46:37 +02:00
Pierre Rust
6d5c5824b5 Move Model initialization in a separate method
The idea is that we can apply special treatment in subclasses when
needed, especially for path normalization.
2014-05-08 10:44:44 +02:00
Adrian Sampson
3ab8107adf Release script: larger prep command 2014-05-07 20:04:20 -07:00
Adrian Sampson
dd11795cbd Release script: datestamp and version commands 2014-05-07 19:46:04 -07:00
Fabrice Laporte
4add189608 Add option to extrapolate year buckets names
- spans are now tracked via a list of dicts instead of 2 lists
previously (simpler code)
- extend_year_spans() pregenerates all possible ranges at plugin setup
stage
- a BucketError is now raised if declared bucket format not accepted
2014-05-08 01:28:17 +02:00
Adrian Sampson
6ecf4ef6ed Release script: upload command 2014-05-06 22:16:19 -07:00
Adrian Sampson
611be7b4b5 Release script: convert changelog to Markdown 2014-05-06 22:06:28 -07:00
Adrian Sampson
d641927ad8 Fix formatted.get calls 2014-05-06 15:57:04 -07:00
Pierre Rust
60160c38a0 Shortcut some tests in Model initialization
When Model objects (Albums and Items) are loaded from the database a lot of time is wasted checking if the object is dirty and if fields are fixed or flexattr.

This change alow bypassing these checks when we know that the data is correct ; it should only be used when loading Model from the database.

With this, listing all tracks in my test database (8200 items) takes 4 seconds while it took 31 seconds previously.
2014-05-07 00:30:39 +02:00
Adrian Sampson
6b3bea99a0 Changelog for faster queries (lazy formatting) 2014-05-06 12:01:13 -07:00
Adrian Sampson
c08e07d31b Property for easy FormattedMapping access 2014-05-06 11:54:56 -07:00
Adrian Sampson
e800b46a5d Make FormattedMapping behave more like a dict
The collections.Mapping abstract base class provides all the nice dict-like
functionality we need.
2014-05-06 11:32:20 -07:00
Adrian Sampson
d30e2f597f Merge pull request #751 from sampsyo/lazy-formatted-mapping
Make _formatted_mapping lazy and an object
2014-05-06 11:16:58 -07:00
Thomas Scholtes
335247481f Make _formatted_mapping lazy and an instance
The motivation for this is to increase the performance of template evalutation.

Previously, the `model._formatted_mapping()` method returned a dictionary that
served as the environment (mapping of variable names to values) when evaluating
a template. To populate the dictionary, we iterated over all keys in the model,
formatted the values, and assigned it to the dictionary. This meant we
formatted every field, even if the template did not require it.

With this commit `_formatted_mapping()` does not return a populated dictionary
but a proxy (or view) instance. The object only knows about the model and the
keys it provides the formatted view for. If a variable is requested by the
template it computes the formatted value on the fly.

The class-based approach has one additional advantage: In the future, we can
separate the formatting logic from the database logic.
2014-05-06 11:24:51 +02:00
Fabrice Laporte
509af59d4e cleanup docstrings and add tests 2014-05-04 08:51:11 +02:00
Fabrice L.
1e7e456f21 Update index.rst
indent line
2014-05-04 08:33:04 +02:00
Fabrice Laporte
a138c4989e include bucket.rst in toc tree 2014-05-04 07:41:02 +02:00
Fabrice L.
8a7f82f354 Update bucket.rst 2014-05-04 07:09:36 +02:00
Fabrice L.
67b3d78b72 Update bucket.rst 2014-05-04 00:04:18 +02:00
Fabrice Laporte
b1d10ed5f9 add bucket plugin doc 2014-05-03 23:48:23 +02:00