mirror of
https://github.com/doocs/md.git
synced 2024-11-24 19:10:34 +08:00
fix: update prettier
This commit is contained in:
parent
90d9b86fe6
commit
934163caec
2
.github/workflows/prettier.yml
vendored
2
.github/workflows/prettier.yml
vendored
@ -19,7 +19,7 @@ jobs:
|
|||||||
- name: Prettify code
|
- name: Prettify code
|
||||||
uses: creyD/prettier_action@v3.0
|
uses: creyD/prettier_action@v3.0
|
||||||
with:
|
with:
|
||||||
prettier_options: --write **/*.{html,js,md}
|
prettier_options: --write **/*.{html,js,md,vue,less,css}
|
||||||
commit_message: 'docs: prettify code'
|
commit_message: 'docs: prettify code'
|
||||||
env:
|
env:
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
@ -3,7 +3,6 @@ import OSS from "ali-oss";
|
|||||||
import COS from "cos-js-sdk-v5";
|
import COS from "cos-js-sdk-v5";
|
||||||
import Buffer from "buffer-from";
|
import Buffer from "buffer-from";
|
||||||
import { v4 as uuidv4 } from "uuid";
|
import { v4 as uuidv4 } from "uuid";
|
||||||
import { resolveConfigFile } from "prettier";
|
|
||||||
|
|
||||||
const defaultConfig = {
|
const defaultConfig = {
|
||||||
username: "filess",
|
username: "filess",
|
||||||
@ -98,7 +97,7 @@ async function ghFileUpload(content, filename) {
|
|||||||
},
|
},
|
||||||
});
|
});
|
||||||
const githubResourceUrl = "raw.githubusercontent.com/filess/images/master/";
|
const githubResourceUrl = "raw.githubusercontent.com/filess/images/master/";
|
||||||
const cdnResourceUrl = "cdn.jsdelivr.net/gh/filess/images/";
|
const cdnResourceUrl = "cdn.jsdelivr.net/gh/filess/images@master/";
|
||||||
return isDefault
|
return isDefault
|
||||||
? res.content.download_url.replace(githubResourceUrl, cdnResourceUrl)
|
? res.content.download_url.replace(githubResourceUrl, cdnResourceUrl)
|
||||||
: res.content.download_url;
|
: res.content.download_url;
|
||||||
|
Loading…
Reference in New Issue
Block a user