Skip to content

Commit 2a63e2f

Browse files
committed
Hyphen-cased dataset JSONs
1 parent f854847 commit 2a63e2f

38 files changed

Lines changed: 30 additions & 30 deletions

File tree

computer-languages/docs/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515

1616
> ### _File extensions for computer languages._
1717
18-
It's just a [JSON file](https://cdn.jsdelivr.net/gh/adamlui/python-utils@computer-languages-1.0.0/computer-languages/src/computer_languages/computer_languages.json), so you can use it in any environment. Sourced from GitHub's [Linguist](https://github.com/github-linguist/linguist) project (defines all 700+ languages known to GitHub). Data is updated via script and released via new package version.
18+
It's just a [JSON file](https://cdn.jsdelivr.net/gh/adamlui/python-utils@computer-languages-1.0.0/computer-languages/src/computer_languages/computer-languages.json), so you can use it in any environment. Sourced from GitHub's [Linguist](https://github.com/github-linguist/linguist) project (defines all 700+ languages known to GitHub). Data is updated via script and released via new package version.
1919

2020
## Installation
2121

computer-languages/pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -124,5 +124,5 @@ where = [
124124

125125
[tool.setuptools.package-data]
126126
computer_languages = [
127-
"computer_languages.json",
127+
"computer-languages.json",
128128
]
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import json, os, sys
22

3-
with open(os.path.join(os.path.dirname(__file__), 'computer_languages.json'), encoding='utf-8') as file:
3+
with open(os.path.join(os.path.dirname(__file__), 'computer-languages.json'), encoding='utf-8') as file:
44
computer_languages = json.load(file)
55

66
sys.modules[__name__] = computer_languages

computer-languages/src/computer_languages/computer_languages.json renamed to computer-languages/src/computer_languages/computer-languages.json

File renamed without changes.

computer-languages/utils/update_langs.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
}
2222
lang_data = dict(sorted(lang_data.items(), key = lambda item: item[0].lower()))
2323

24-
output_path = Path(__file__).parent.parent / 'src/computer_languages/computer_languages.json'
24+
output_path = Path(__file__).parent.parent / 'src/computer_languages/computer-languages.json'
2525
log.info(f'Saving {len(lang_data)} languages to {output_path}...')
2626
data.json.write(output_path, lang_data, style='compact')
2727

data-languages/docs/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515

1616
> ### _File extensions for data languages._
1717
18-
It's just a [JSON file](https://cdn.jsdelivr.net/gh/adamlui/python-utils@data-languages-1.0.0/data-languages/src/data_languages/data_languages.json), so you can use it in any environment. Sourced from GitHub's [Linguist](https://github.com/github-linguist/linguist) project (defines all 145 data languages known to GitHub). Data is updated via script and released via new package version.
18+
It's just a [JSON file](https://cdn.jsdelivr.net/gh/adamlui/python-utils@data-languages-1.0.0/data-languages/src/data_languages/data-languages.json), so you can use it in any environment. Sourced from GitHub's [Linguist](https://github.com/github-linguist/linguist) project (defines all 145 data languages known to GitHub). Data is updated via script and released via new package version.
1919

2020
## Installation
2121

data-languages/pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,5 +96,5 @@ where = [
9696

9797
[tool.setuptools.package-data]
9898
data_languages = [
99-
"data_languages.json",
99+
"data-languages.json",
100100
]
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import json, os, sys
22

3-
with open(os.path.join(os.path.dirname(__file__), 'data_languages.json'), encoding='utf-8') as file:
3+
with open(os.path.join(os.path.dirname(__file__), 'data-languages.json'), encoding='utf-8') as file:
44
data_languages = json.load(file)
55

66
sys.modules[__name__] = data_languages
File renamed without changes.

data-languages/utils/update_langs.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
lang_data[lang_name] = { 'extensions': sorted(lang_info['extensions'], key=str.lower) }
1919
lang_data = dict(sorted(lang_data.items(), key = lambda item: item[0].lower()))
2020

21-
output_path = Path(__file__).parent.parent / 'src/data_languages/data_languages.json'
21+
output_path = Path(__file__).parent.parent / 'src/data_languages/data-languages.json'
2222
log.info(f'Saving {len(lang_data)} data languages to {output_path}...')
2323
data.json.write(output_path, lang_data, style='compact')
2424

0 commit comments

Comments
 (0)