Skip to content
This repository has been archived by the owner on Jun 16, 2021. It is now read-only.

Commit

Permalink
mv: 🚚 fetchGitmoji for clearer distinction of responsibility
Browse files Browse the repository at this point in the history
And let's see what `mv` does :D
  • Loading branch information
JeromeFitz committed Feb 28, 2021
1 parent 68b68cc commit f8ba905
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
"build:readme": "mmarkdown",
"build": "yarn build:cli && yarn build:cz",
"clean": "rimraf dist binaries",
"get:gitmojis": "node ./scripts/getGitmojis.js",
"fetch:gitmojis": "node ./scripts/fetchGitmoji.js",
"lint:eslint": "eslint . --ext js,jsx,ts,tsx --max-warnings=0",
"lint:fix": "yarn lint:prettier --write && yarn lint:eslint --fix",
"lint:prettier": "prettier \"./*.{js,jsx,ts,tsx,json,md,mdx,css,html,yml,yaml,scss}\"",
Expand Down
6 changes: 2 additions & 4 deletions scripts/getGitmojis.js β†’ scripts/fetchGitmoji.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ const gitmojiUrl =
const dataDirectory = path.join(__dirname, '..', 'data');
const dataFilename = path.resolve(dataDirectory, 'gitmojis.json');

const getGitmojis = async () => {
const fetchGitmoji = async () => {
const response = await fetch(gitmojiUrl);
const json = await response.json();
const data = await JSON.stringify(json, null, 4);
Expand All @@ -24,6 +24,4 @@ const getGitmojis = async () => {
});
};

getGitmojis();

module.exports = getGitmojis;
module.exports = fetchGitmoji;

0 comments on commit f8ba905

Please sign in to comment.