Skip to content

Commit

Permalink
fix🐛: update ci time
Browse files Browse the repository at this point in the history
  • Loading branch information
isboyjc committed Aug 3, 2024
1 parent 8e20c5b commit 4885a95
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 16 deletions.
13 changes: 8 additions & 5 deletions .github/workflows/run.yml
Original file line number Diff line number Diff line change
@@ -1,12 +1,15 @@
name: Fetch GitHub Trending

on:
# push:
# branches:
# - main
push:
branches:
- main
schedule:
- cron: '* 1 * * *' # UTC 凌晨一点
- cron: '* 17 * * *' # UTC+8 凌晨一点
- cron: '0 3 * * *' # UTC 凌晨 3 点
- cron: '0 9 * * *' # UTC 早 9 点
- cron: '0 13 * * *' # UTC 中午 1 点
- cron: '0 18 * * *' # UTC 下午 6 点
- cron: '0 23 * * *' # UTC 下午 11 点

jobs:
build:
Expand Down
22 changes: 11 additions & 11 deletions script/index.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* @LastEditTime: 2024-08-02 18:04:36
* @LastEditTime: 2024-08-03 19:51:30
* @Description: ...
* @Date: 2024-08-01 22:16:50
* @Author: isboyjc
Expand Down Expand Up @@ -61,14 +61,14 @@ function delay(ms) {

console.log("Number of languages: ", languages.length)

// for(const langObj of languages){
// try {
// await delay(5 * 60)
// await run('daily', convertToSlug(langObj.name))
// await run('weekly', convertToSlug(langObj.name))
// await run('monthly', convertToSlug(langObj.name))
// } catch (error) {
// console.error(`Error language ${convertToSlug(langObj.name)}:`, error);
// }
// }
for(const langObj of languages){
try {
await delay(5 * 60)
await run('daily', convertToSlug(langObj.name))
await run('weekly', convertToSlug(langObj.name))
await run('monthly', convertToSlug(langObj.name))
} catch (error) {
console.error(`Error language ${convertToSlug(langObj.name)}:`, error);
}
}
})();

0 comments on commit 4885a95

Please sign in to comment.