Skip to content

Commit

Permalink
Merge pull request #195 from GeoffreyChen777/electron-dev
Browse files Browse the repository at this point in the history
V2.1.4
  • Loading branch information
GeoffreyChen777 authored Dec 31, 2022
2 parents fd23a52 + 2c1a244 commit c5af4d5
Show file tree
Hide file tree
Showing 8 changed files with 35 additions and 14 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG_CN.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
## v2.1.4 31/12 2022

1. 修复 Bug。
2. 优化 DBLP scaper 对 ICLR 2016 的检索结果。

## v2.1.3 23/12 2022

1. 更新 Word 插件证书。
Expand Down
5 changes: 5 additions & 0 deletions CHANGELOG_EN.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
## v2.1.4 Dec 31 2022

1. Enhance the DBLP scaper for ICLR 2016.
2. Fixed some bugs.

## v2.1.3 Dec 23 2022

1. Update the MS Word add-in cert.
Expand Down
1 change: 1 addition & 0 deletions app/interactors/plugin-side-interactor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ export class PluginSideInteractor {
ipcRenderer.on("plugin-comm-port", (event) => {
const [port] = event.ports;
this.port = port;
this.pluginLinkFolder(this.preference.get("pluginLinkedFolder") as string);
});
}

Expand Down
6 changes: 4 additions & 2 deletions app/renderer/ui/whats-new-view/whats-new-view-cn.vue
Original file line number Diff line number Diff line change
Expand Up @@ -86,11 +86,13 @@ onMounted(() => {
v-else
/>
<p class="text-center text-2xl font-bold mb-8">
Paperlib 2.1.3 更新内容
Paperlib 2.1.4 更新内容
</p>

<ul class="list-disc mb-5">
<li>更新 Word 插件证书。</li>
<li>优化 DBLP scaper 对 ICLR 2016 的检索结果。</li>
<li>修复一些 Bug。</li>
<li>新年快乐!</li>
</ul>
<div
id="whats-new-close-btn"
Expand Down
7 changes: 4 additions & 3 deletions app/renderer/ui/whats-new-view/whats-new-view-en.vue
Original file line number Diff line number Diff line change
Expand Up @@ -86,12 +86,13 @@ onMounted(() => {
v-else
/>
<p class="text-center text-2xl font-bold mb-8">
What's New in Paperlib 2.1.3
What's New in Paperlib 2.1.4
</p>

<ul class="list-disc mb-5">
<li>Update the MS Word add-in cert.</li>
<li>Happy Holiday!</li>
<li>Enhance the DBLP scaper for ICLR 2016.</li>
<li>Fixed some bugs.</li>
<li>Happy New Year!</li>
</ul>
<div
id="whats-new-close-btn"
Expand Down
19 changes: 13 additions & 6 deletions app/repositories/scraper-repository/scrapers/dblp.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ function parsingProcess(
}
| { text: string }[];
};
venue: string;
year: string;
type: string;
key: string;
Expand All @@ -49,16 +50,19 @@ function parsingProcess(
str: article.title,
removeStr: "&amp",
removeSymbol: true,
removeNewline: true,
removeWhite: true,
lowercased: true,
});

const existTitle = formatString({
str: paperEntityDraft.title,
removeStr: "&amp",
removeSymbol: true,
removeNewline: true,
removeWhite: true,
lowercased: true,
});

if (plainHitTitle != existTitle) {
continue;
} else {
Expand Down Expand Up @@ -88,16 +92,21 @@ function parsingProcess(
pubType = 2;
}
const pubKey = article.key.split("/").slice(0, 2).join("/");
const venueKey = article.venue;

if (pubKey != "journals/corr") {
if ((pubKey != "journals/corr") || (pubKey == "journals/corr" && venueKey != "CoRR")) {
if (article.doi) {
paperEntityDraft.setValue("doi", article.doi);
}
paperEntityDraft.setValue("title", title);
paperEntityDraft.setValue("authors", authors);
paperEntityDraft.setValue("pubTime", `${pubTime}`);
paperEntityDraft.setValue("pubType", pubType);
paperEntityDraft.setValue("publication", "dblp://" + pubKey);
if (pubKey == "journals/corr") {
paperEntityDraft.setValue("publication", "dblp://" + venueKey);
} else {
paperEntityDraft.setValue("publication", "dblp://" + pubKey);
}

if (article.volume) {
paperEntityDraft.setValue("volume", article.volume);
Expand All @@ -112,7 +121,6 @@ function parsingProcess(
paperEntityDraft.setValue("publisher", article.publisher);
}
}

break;
}
}
Expand Down Expand Up @@ -244,7 +252,6 @@ export class DBLPVenueScraper extends Scraper {
"https://dblp.org/search/venue/api?q=" +
paperEntityDraft.publication.replace("dblp://", "") +
"&format=json";

const headers = {};
return { scrapeURL, headers, enable };
}
Expand Down Expand Up @@ -272,7 +279,7 @@ export class DBLPVenueScraper extends Scraper {
const hits = response.result.hits.hit;
for (const hit of hits) {
const venueInfo = hit["info"];
if (venueInfo["url"].includes(venueID)) {
if (venueInfo["url"].includes(venueID.toLowerCase())) {
const venue = venueInfo["venue"];
paperEntityDraft.setValue("publication", venue);
this.uploadCache(paperEntityDraft, "dblp");
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "paperlib",
"version": "2.1.3",
"version": "2.1.4",
"main": "dist/app/main/index.js",
"description": "A simple academic paper management tool.",
"author": "Geoffrey Chen <[email protected]>",
Expand Down
4 changes: 2 additions & 2 deletions release-notes.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
1. Update the MS Word add-in cert.
1. Enhance the DBLP scaper for ICLR 2016.
2. Fixed some bugs.

0 comments on commit c5af4d5

Please sign in to comment.