Skip to content

Commit

Permalink
fix(data): add JabRef journal abbr data
Browse files Browse the repository at this point in the history
resolve: #5 (comment)
  • Loading branch information
northword committed Nov 3, 2023
1 parent 242e29e commit 7151d27
Show file tree
Hide file tree
Showing 4 changed files with 95,422 additions and 93,953 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

### Fix

- 重新添加 JabRef 期刊缩写数据,数据会首选 library.ubc.ca ,次选 JabRef。[#5](https://github.com/northword/zotero-format-metadata/issues/5#issuecomment-1790844575)

## [1.6.7] - 2023-10-27

### Added
Expand Down
2 changes: 1 addition & 1 deletion src/data/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ export interface dict {
* Value: ISO 4 with dot 缩写
*/
// export const journalAbbrlocalData: dict = journalAbbrISO4JabRef;
export const journalAbbrlocalData: dict = journalAbbrISO4Ubc;
export const journalAbbrlocalData: dict = {...journalAbbrISO4JabRef, ...journalAbbrISO4Ubc};

/**
* 高校所在地数据
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,8 @@
if ";" in line and line[0] != "#" and line[0][0].isalpha():
count += 1
parts = line.partition(";")
key = parts[0].strip().lower().replace("the ", "")
# key = parts[0].strip().lower().replace("the ", "")
key = parts[0].strip()
current_abbr = parts[2].partition(";")[0].strip()
# 排除过长的和过短的期刊
if (len(key) <= 80 or len(key) >= 3):
Expand Down
Loading

0 comments on commit 7151d27

Please sign in to comment.