Line numbers are places in import and export; fix stale scripts
Import: each row's place is its line number, so blank lines leave a
place empty; a fully numbered text file ("38. Title") or a Rank column
gives places directly, and repeated numbers take the next free place.
Entries are added at those places (existing ones there move down), the
review shows each row's #, and the room check covers the highest place.
Export writes a blank line for every empty place, so line N is #N and a
file round-trips.
Static files now carry an ETag and unversioned ones are revalidated on
every load. Scripts import each other without a ?v= tag, so browsers kept
an hour-old import.js (with the "null" bug) after an update.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
88373176f2
commit
62fcf6b45d
7 files changed
+151
-72
No files matched your search
@@ -144,16 +144,16 @@ Edits show instantly and save in the background.
|
||||
|
||||
## Importing a list
|
||||
|
||||
**Import** in the list editor adds entries from a file, after the ones already there and in the file's order:
|
||||
**Import** in the list editor adds entries from a file. **Line numbers are places**: line 1 becomes #1, line 38 becomes #38, and a blank line leaves its place empty (entries already at those places move down to make room).
|
||||
|
||||
- **Text** (`.txt`, or paste): one title per line. Numbering like `1.` is dropped when every line has it, and a trailing `(1999)` is read as the year. For songs and albums, `Artist - Title` works either way round.
|
||||
- **CSV / TSV**: a header row picks the columns: `Title` (or Name), `Year`, `Artist`/`Director`/`Developer`, `Note` (or Why), and `Rank` to set the order. Without a header the first column is the title. Canon's own export imports as-is.
|
||||
- **Text** (`.txt`, or paste): one title per line. If every line is numbered (`38. Super Mario World`), the numbers are the places instead. A trailing `(1999)` is read as the year. For songs and albums, `Artist - Title` works either way round.
|
||||
- **CSV / TSV**: a header row picks the columns: `Title` (or Name), `Year`, `Artist`/`Director`/`Developer`, `Note` (or Why), and `Rank` to give places directly. Without a header the first column is the title. The first row after the header is #1.
|
||||
|
||||
Each entry is searched for and matched. Canon only adds a match on its own when it's certain: the title matches exactly and nothing else fits as well (a year or artist in the file helps). Everything else is left for you to check, with a recommended pick, the other results, **Add as written** to make a new entry from your text, **Skip**, and a box to search again. Custom lists search all of Wikipedia, so there a match is only certain when a year or subtitle confirms it.
|
||||
|
||||
## Exporting a list
|
||||
|
||||
Every list can be downloaded as its titles only, in rank order, one per line. There are no ranks, header row or other fields.
|
||||
Every list can be downloaded as its titles only, one per line, where line N is place #N: an empty place is a blank line. There are no ranks, header row or other fields, and importing the file puts everything back where it was.
|
||||
|
||||
- **Export → Titles as CSV** (`/l/<list>/export?format=csv`): a single column. It starts with a UTF-8 BOM so Excel shows accented titles correctly.
|
||||
- **Export → Titles as text** (`/l/<list>/export?format=txt`): plain lines.
|
||||
|
||||
Reference in new issue
Block a user