Skip to content

Commit

Permalink
ci: git hooks
Browse files Browse the repository at this point in the history
  • Loading branch information
irffanasiff committed Nov 24, 2022
1 parent 2072742 commit b320816
Show file tree
Hide file tree
Showing 18 changed files with 95 additions and 95 deletions.
22 changes: 9 additions & 13 deletions .github/CONTRIBUTORS.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,36 +2,32 @@

**First off, thanks for taking the time to contribute! :tada::+1:**


>
> You can contribute to the project in any way if you are not a developer you can suggest design and UX changes too. Create a PR or reach out to us 😊
> * All kind of Contributions are welcomed
>
> - All kind of Contributions are welcomed
__Note:__ If there's a feature you'd like, there's a bug you'd like to fix, or you'd just like to get involved please raise an issue and start a conversation. We'll help as much as we can so you can get contributing - although we may not always be able to respond right away :)
**Note:** If there's a feature you'd like, there's a bug you'd like to fix, or you'd just like to get involved please raise an issue and start a conversation. We'll help as much as we can so you can get contributing - although we may not always be able to respond right away :)

## Development Guidelines

It is a basic [Next.js](https://nextjs.org/docs) project with [ChakraUI](https://chakra-ui.com/getting-started) as component library. We are using [pnpm](https://pnpm.io/motivation) as package manager. You will have to install node.js before running this project locally.

To know more about reputation system read - [Reputation System Docs](https://superteam-onboarding.gitbook.io/the-superteam-handbook/community/the-reputation-system)

It is a basic [Next.js](https://nextjs.org/docs) project with [ChakraUI](https://chakra-ui.com/getting-started) as component library. We are using [pnpm](https://pnpm.io/motivation) as package manager. You will have to install node.js before running this project locally.

To know more about reputation system read - [Reputation System Docs](https://superteam-onboarding.gitbook.io/the-superteam-handbook/community/the-reputation-system)

#### Setup

How to setup the project locally

```bash
git clone https://github.com/irffanasiff/Superteam-Reputation.git
# go to the project and open it with your fav. IDE
cd Superteam-Reputation
# install the dependencies using pnpm
pnpm i
pnpm i
# create a new branch and start working
git checkout -b <your-branch-name>
# run the development server
pnpm run dev
pnpm run dev
```


Once you have made the changes check ```commitlint.config.js``` for how to commit your code. If the build is succesfully you will be able to push the code and make the pr. Follow the pull request.
Once you have made the changes check `commitlint.config.js` for how to commit your code. If the build is succesfully you will be able to push the code and make the pr. Follow the pull request.
3 changes: 1 addition & 2 deletions .github/ISSUE_TEMPLATE/issue_template.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
---
name: Bug report
about: Create a report to help us improve

---

<!--
<!--
Please see our guide for opening issues: //link for creating issues
Expand Down
10 changes: 7 additions & 3 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,13 @@
design: For design/UX improvement
-->

<!-- Checklist!!! If you're unsure about any of them, don't hesitate to ask. We're here to help! This is simply a reminder of what we are going to look for before merging your code.
- I have read the Contributing Guide - https://github.com/irffanasiff/Superteam-Reputation/tree/prod/.github/CONTRIBUTING.md doc
- I have added necessary documentation (if applicable)
<!-- Checklist!!! If you're unsure about any of them, don't hesitate to ask. We're here to help! This is simply a reminder of what we are going to look for before merging your code.
- I have read the Contributing Guide - https://github.com/irffanasiff/Superteam-Reputation/tree/prod/.github/CONTRIBUTING.md doc
- I have added necessary documentation (if applicable)
-->

## Proposed changes (including videos or screenshots)

<!-- CHANGELOG -->
<!--
Describe the big picture of your changes here to communicate to the maintainers why we should accept this pull request.
Expand All @@ -26,10 +27,13 @@
<!-- END CHANGELOG -->

## Issue(s)

<!-- Link the issues being closed by or related to this PR. For example, you can use #594 if this PR closes issue number 594 -->

## Steps to reproduce

<!-- Mention how you would reproduce the bug if not mentioned on the issue page already. Also mention which screens are going to have the changes if applicable -->

## Further comments

<!-- If this is a relatively large or complex change, kick off the discussion by explaining why you chose the solution you did and what alternatives you considered, etc... -->
1 change: 1 addition & 0 deletions .husky/commit-msg
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,4 @@

npx --no -- commitlint --edit "$1"
npx --no -- commitlint --edit "$1"
npx --no -- commitlint --edit "$1"
1 change: 1 addition & 0 deletions .husky/pre-commit
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,4 @@ pnpm lint
pnpm lint
pnpm exec lint
pnpm lint
pnpm lint
1 change: 1 addition & 0 deletions .husky/pre-push
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,4 @@ pnpm build
pnpm build
pnpm exec build
pnpm build
pnpm build
76 changes: 38 additions & 38 deletions commitlint.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,42 +9,42 @@
// test: Adding missing tests or correcting existing tests

module.exports = {
extends: ['@commitlint/config-conventional'],
rules: {
'body-leading-blank': [1, 'always'],
'body-max-line-length': [2, 'always', 100],
'footer-leading-blank': [1, 'always'],
'footer-max-line-length': [2, 'always', 100],
'header-max-length': [2, 'always', 100],
'scope-case': [2, 'always', 'lower-case'],
'subject-case': [
2,
'never',
['sentence-case', 'start-case', 'pascal-case', 'upper-case'],
extends: ['@commitlint/config-conventional'],
rules: {
'body-leading-blank': [1, 'always'],
'body-max-line-length': [2, 'always', 100],
'footer-leading-blank': [1, 'always'],
'footer-max-line-length': [2, 'always', 100],
'header-max-length': [2, 'always', 100],
'scope-case': [2, 'always', 'lower-case'],
'subject-case': [
2,
'never',
['sentence-case', 'start-case', 'pascal-case', 'upper-case'],
],
'subject-empty': [2, 'never'],
'subject-full-stop': [2, 'never', '.'],
'type-case': [2, 'always', 'lower-case'],
'type-empty': [2, 'never'],
'type-enum': [
2,
'always',
[
'build',
'chore',
'ci',
'docs',
'feat',
'fix',
'perf',
'refactor',
'revert',
'style',
'test',
'translation',
'security',
'changeset',
],
'subject-empty': [2, 'never'],
'subject-full-stop': [2, 'never', '.'],
'type-case': [2, 'always', 'lower-case'],
'type-empty': [2, 'never'],
'type-enum': [
2,
'always',
[
'build',
'chore',
'ci',
'docs',
'feat',
'fix',
'perf',
'refactor',
'revert',
'style',
'test',
'translation',
'security',
'changeset',
],
],
},
};
],
},
};
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -48,4 +48,4 @@
"simple-zustand-devtools": "^1.1.0"
},
"packageManager": "[email protected]"
}
}
4 changes: 2 additions & 2 deletions src/components/Dashboard/Leaderboard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import {
Th,
Thead,
Tr,
useMediaQuery
useMediaQuery,
} from '@chakra-ui/react';
import * as React from 'react';
import Pagination from '../Pagination';
Expand Down Expand Up @@ -99,7 +99,7 @@ export default function EnhancedTable({ row, searching }: propsType) {
XP Growth
</Th>
<Th
w='full'
w="full"
textTransform={'capitalize'}
fontWeight="500"
fontSize={'14px'}
Expand Down
6 changes: 3 additions & 3 deletions src/components/Dashboard/Row/GraphColumn.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -79,12 +79,12 @@ const GraphColumn = ({ row }: propsType) => {
<Tooltip
label="XP earned this month"
fontSize="xs"
colorScheme='whiteAlpha'
bg='superteamWhite'
colorScheme="whiteAlpha"
bg="superteamWhite"
rounded="md"
fontWeight="400"
>
<Text color='superteamWhite' fontSize='14px'>
<Text color="superteamWhite" fontSize="14px">
{Math.round(lastSixMonths[0].xp)}
</Text>
</Tooltip>
Expand Down
6 changes: 4 additions & 2 deletions src/components/Navigation/Header.tsx
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
import {
chakra,
Container, Flex, Icon,
Container,
Flex,
Icon,
Stack,
VisuallyHidden
VisuallyHidden,
} from '@chakra-ui/react';
import { ReactNode } from 'react';
import { FaDiscord, FaTwitter } from 'react-icons/fa';
Expand Down
14 changes: 7 additions & 7 deletions src/enums/skill.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
/* eslint-disable no-unused-vars */
export enum skillKind {
DEV= 'development',
DESIGN = 'design',
OPS = 'operations',
VIDEO = 'videography',
STRATEGY = 'strategy',
WRITING = 'writing',
}
DEV = 'development',
DESIGN = 'design',
OPS = 'operations',
VIDEO = 'videography',
STRATEGY = 'strategy',
WRITING = 'writing',
}
12 changes: 6 additions & 6 deletions src/interfaces/config.d.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
export interface ConfigInterface {
general: {
name: string;
domain: string;
twitterHandle: string;
};
}
general: {
name: string;
domain: string;
twitterHandle: string;
};
}
12 changes: 6 additions & 6 deletions src/interfaces/seo.d.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
interface SeoPropsInterface {
title: string;
description: string;
image: string;
}
export default SeoPropsInterface;
title: string;
description: string;
image: string;
}

export default SeoPropsInterface;
2 changes: 1 addition & 1 deletion src/lib/airtable.ts
Original file line number Diff line number Diff line change
Expand Up @@ -377,5 +377,5 @@ export {
getBountiesRecordsFunction,
getCabsRecordsFunction,
getBrainTrustRecordsFunction,
getStackXpRecordsFunction,
getStackXpRecordsFunction,
};
6 changes: 4 additions & 2 deletions src/util/dataCalculator.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
import { receivedXPFromAirtableType } from '../interfaces/airtableRecievedXP';
import { dashboardDataType,
totalOverallXPType, } from '../interfaces/dashboardStore';
import {
dashboardDataType,
totalOverallXPType,
} from '../interfaces/dashboardStore';
import { xpType } from '../interfaces/xp';
import {
getBountiesRecordsFunction,
Expand Down
2 changes: 1 addition & 1 deletion src/util/sourceTotalXpCalculator.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { receivedXPFromAirtableTotalType } from '../interfaces/airtableRecievedXPTotal';
import { receivedXPFromAirtableType } from '../interfaces/airtableRecievedXP';
import { receivedXPFromAirtableType } from '../interfaces/airtableRecievedXP';
import { totalOverallXPType } from '../interfaces/dashboardStore';
import { allocated_xp, xpType } from '../interfaces/xp';
import { skillKind } from '../enums/skill';
Expand Down
10 changes: 2 additions & 8 deletions tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,11 +1,7 @@
{
"compilerOptions": {
"target": "es5",
"lib": [
"dom",
"dom.iterable",
"esnext"
],
"lib": ["dom", "dom.iterable", "esnext"],
"allowJs": true,
"skipLibCheck": true,
"strict": true,
Expand All @@ -25,7 +21,5 @@
"**/*.tsx",
"src/pages/api/airtableData.js"
],
"exclude": [
"node_modules"
]
"exclude": ["node_modules"]
}

0 comments on commit b320816

Please sign in to comment.