Adrian Sampson
b44195853c
zero-pad date values in path formats ( #282 )
2011-12-22 15:57:02 -08:00
Adrian Sampson
b493bc7004
configurable pathname substitution ( #115 )
2011-12-19 18:37:35 -08:00
Adrian Sampson
46a3bde5b5
fix empty function arguments
...
Previously, an empty argument was treated as "not an argument at all". Now,
every function call always has at least one argument -- i.e., %foo{} is a
function call whose only argument is "" -- and %foo{,bar} is valid syntax.
2011-12-16 12:08:39 -08:00
Adrian Sampson
255fbf6c41
add a small set of default path functions ( #231 )
2011-12-15 14:27:59 -08:00
Adrian Sampson
b9d6928278
consistency policy for DB mtimes ( #227 )
2011-12-03 17:18:51 -08:00
Adrian Sampson
a448879ca9
infer album artist or VA for as-is imports ( #161 )
2011-06-29 10:36:07 -07:00
Adrian Sampson
40035bfdf4
format $bitrate in path formats as "XXkbps"
2011-06-13 20:52:52 -07:00
Adrian Sampson
85ddfa4381
relocatable test rsrc directory
2011-04-12 14:26:48 -07:00
Adrian Sampson
e669868896
move a bunch of functions to util
2011-04-10 21:48:05 -07:00
Adrian Sampson
b28ef722a5
singleton path format
2011-04-09 14:50:48 -07:00
Adrian Sampson
61ef980797
$albumartist falls back to $artist ( #166 )
2011-04-09 12:36:52 -07:00
Adrian Sampson
7f7c45b252
refactoring, tests, NEWS note on wlof's directory-pruning patch
2011-03-23 16:53:24 -07:00
Adrian Sampson
43a5e913a7
move some reused testing stuff to _common module
2011-03-23 16:15:18 -07:00
Adrian Sampson
f69f69cecf
merge in some fixes from wlof's repository
2011-03-23 15:50:11 -07:00
Adrian Sampson
096816cba7
path formats can now be specified by album type
2011-03-22 20:09:27 -07:00
wlof
7be77a99d9
.. is now inserted at the beginning of sys.path so that local beets
...
files are used instead of installed ones
2011-03-19 01:45:35 +01:00
Adrian Sampson
0d869340ec
fixes for album artist inference
...
- Inference must be enabled explicitly with the "infer_aa" flag. It does not
happen transparently.
- Infer both artist and artist ID.
- Fixed a bug where only the database row was using the inferred data, not the
returned data structure.
- Added tests.
2011-02-18 12:17:22 -08:00
Adrian Sampson
ce5f9f9936
move BaseAlbum tests to test_db (with other album tests)
2011-02-18 11:36:52 -08:00
Adrian Sampson
eb1a6c8ae3
tests for multiple paths feature; legacy path_format overrides
2011-01-24 19:40:09 -08:00
Adrian Sampson
66b3e5675c
update default path formats; make $artist fall back on $albumartist
...
The default path formats now include both a "default", which is the same as
before but now uses $albumartist instead of $artist, and a "comp" path, which
uses a Compilations directory. Old paths are supported as-is by letting $artist
refer to either a track artist (when present, as it is in all old library
tracks) or album artist (when the track artist isn't present, as is the case
with most albums imported now).
2011-01-24 10:14:19 -08:00
Adrian Sampson
0c24376e6a
migration of album table's artist field to albumartist; fix ls -a
2011-01-23 22:49:52 -08:00
Adrian Sampson
75e0924832
move _sanitize_for_path to module namespace
2011-01-23 19:59:41 -08:00
Adrian Sampson
6ade5635e1
light refactoring and renaming for patch
...
Changed mb_albumtype to albumtype.
Changed album_artist to albumartist.
Reinstated subset relationship between album fields and item fields.
2011-01-23 19:49:48 -08:00
Adrian Sampson
342c360285
apply jonathan.buchanan's compilation patch from issue #48
2011-01-23 18:41:35 -08:00
Adrian Sampson
0b0d7e0b67
fixes for tests' cross-platformness by jonathan.buchanan
2011-01-20 09:29:09 -08:00
Adrian Sampson
4359845a01
prohibit trailing spaces in Windows filenames
2011-01-19 13:17:54 -08:00
Adrian Sampson
5904852e4b
use "long filename" support instead of short truncation on Windows ( #127 )
...
(Patch by jonathan.buchanan. Thanks!)
2011-01-19 13:14:54 -08:00
Adrian Sampson
ab35db7b7a
truncate path components to 30 characters on Windows (work around #120 )
2011-01-18 20:13:57 -08:00
Adrian Sampson
7cf10d13e5
fix escaping of / in paths on Windows
2010-09-27 16:56:40 -07:00
Adrian Sampson
633b97b302
decode unicode art paths from legacy databases
2010-08-06 10:44:00 -07:00
Adrian Sampson
898b4bd24e
destination now uses album values when available
...
When computing track destination paths, we now look for album-level values when
they're available. This has the effect of making albums go into a single
directory even when their tracks have heterogeneous metadata. We will need to
revisit this once we start explicitly supporting non-album tracks.
2010-08-06 10:36:17 -07:00
Adrian Sampson
181949d1a3
_sanitize_path now uses a non-unicode regex
2010-08-06 10:01:49 -07:00
Adrian Sampson
d1c6448da8
album art paths now stored in blobs in database
2010-08-06 09:55:21 -07:00
Adrian Sampson
2a91ddf40b
destinations now return bytestring paths
2010-08-05 13:36:50 -07:00
Adrian Sampson
2950ae1bf6
all paths are now bytestrings (not unicode)
...
In the end, after all of this, it turns out that we basically need to abandon
the temptation of dealing with unicode paths altogether. The POSIX filesystem
API has no notion of unicode and is very much a bytes-only interface. This
means that undecodable pathnames are a reality we must deal with. This new
approach stores all paths as buffers (blobs) in SQLite and -- as transparently
as possible -- presents them as str objects to the Python code. Legacy
databases will have their paths automatically encoded into str objects, and
will lazily have their unicodes in the database replaced with buffers.
2010-08-05 13:26:30 -07:00
Adrian Sampson
2eb10e391a
add "format" field to MediaFile for getting the file type
...
This allows using $format in your path format string, which is nice.
2010-07-21 23:01:32 -07:00
Adrian Sampson
11c9b7fad9
move album/art file tests to test_files from test_db
2010-07-21 16:11:08 -07:00
Adrian Sampson
e9e90fa538
expand set of album metadata to include everything relevant
2010-07-15 11:22:36 -07:00
Adrian Sampson
7816b411ad
simplified interface for add_album
2010-07-14 23:04:59 -07:00
Adrian Sampson
6b99e3f48d
importer now takes album art config options and switch
...
(doesn't yet actually apply art)
2010-07-14 14:58:17 -07:00
Adrian Sampson
6a3c024005
add_art convenience function takes care of copying to destination
2010-07-14 14:28:54 -07:00
Adrian Sampson
304e4d6708
albums move and remove their items, manage album art
2010-07-14 14:19:51 -07:00
Adrian Sampson
19ded256cd
albums query and modify their associated items
2010-07-14 13:24:11 -07:00
Adrian Sampson
3006f9953c
beginnings of explicit album management
2010-07-14 12:40:25 -07:00
Adrian Sampson
5096a12052
basic (non-collected) implementation of albums table
2010-07-13 19:42:45 -07:00
Adrian Sampson
bdbabe91da
basic album information access through proxy object
2010-07-13 18:01:14 -07:00
Adrian Sampson
5d4f452393
add "albums" table to library database (including migrations)
2010-07-13 10:25:42 -07:00
Adrian Sampson
30669fd7ac
replace :s with -s instead of _s in path names
2010-07-11 19:12:50 -07:00
Adrian Sampson
4378db1361
more characters escaped on Windows
2010-07-11 18:14:40 -07:00
Adrian Sampson
aec7bef504
add MusicBrainz ID fields to database schema
2010-07-10 17:53:51 -07:00