mirror of
https://github.com/SickGear/SickGear.git
synced 2024-11-15 17:35:04 +00:00
9009cc7a7b
Add a Select2 drop-down to `add-shows` and `edit-show`. The Select2 enables displaying inline language flag images, this feature deprecated by the native `select` drop-down element on some browsers. Change run existing TVInfo source language lists through validation (removes ~4 bad items), de-dupe list, get the native names, English names, and three letter abbr. Change remove marisa-trie requirement from language_data/names.py because nothing in SG calls a function that requires it. Change update some flags.
15 lines
347 B
Python
15 lines
347 B
Python
"""
|
|
Used for locating a file in the data directory.
|
|
"""
|
|
|
|
from pkg_resources import resource_filename
|
|
DATA_ROOT = resource_filename('language_data', 'data')
|
|
import os
|
|
|
|
|
|
def data_filename(filename):
|
|
"""
|
|
Given a relative filename, get the full path to that file in the data
|
|
directory.
|
|
"""
|
|
return os.path.join(DATA_ROOT, filename)
|