release: v1.2.0 — unified images/ storage and legacy migration
ci / ci (22, ubuntu-latest) (push) Canceled after 0s
Publish Docker image / build (linux/amd64, ubuntu-latest, amd64) (push) Canceled after 0s
Publish Docker image / build (linux/arm64, ubuntu-24.04-arm, arm64) (push) Canceled after 0s
Publish Docker image / merge (push) Canceled after 0s
GitHub Release / release (push) Canceled after 0s
ci / ci (22, ubuntu-latest) (push) Canceled after 0s
Publish Docker image / build (linux/amd64, ubuntu-latest, amd64) (push) Canceled after 0s
Publish Docker image / build (linux/arm64, ubuntu-24.04-arm, arm64) (push) Canceled after 0s
Publish Docker image / merge (push) Canceled after 0s
GitHub Release / release (push) Canceled after 0s
Consolidate local images under data/images/, add docker migrate CLI, startup index sync with orphan cleanup, and remove upload folder UI/API.
This commit is contained in:
1 parent
3dee0437e6
commit
469d3be735
50 files changed
+1273
-956
No files matched your search
@@ -0,0 +1,15 @@
|
||||
import { describe, expect, it } from 'vitest'
|
||||
import { contentTypeFromKey } from './content-type'
|
||||
|
||||
describe('contentTypeFromKey', () => {
|
||||
it('infers image types from extensions', () => {
|
||||
expect(contentTypeFromKey('images/a.webp')).toBe('image/webp')
|
||||
expect(contentTypeFromKey('images/file/111.webp')).toBe('image/webp')
|
||||
expect(contentTypeFromKey('images/2026/08/28/123.webp')).toBe('image/webp')
|
||||
expect(contentTypeFromKey('images/photo.JPG')).toBe('image/jpeg')
|
||||
})
|
||||
|
||||
it('falls back to octet-stream for unknown extensions', () => {
|
||||
expect(contentTypeFromKey('images/file.dat')).toBe('application/octet-stream')
|
||||
})
|
||||
})
|
||||
Reference in new issue
Block a user