How To Improve Code Quality In Last 5 Minutes Before Submitting PR
Tags: github, developmentexperience, programming, tutorial
Published: 2023-03-17 07:00:00



![Git](https://miro.medium.com/v2/resize:fit:700/0*Q43itGAg6o2y0j9l)



So, you’re just about to submit your Pull Request, and you’re thinking, “Wait a minute, is my code up to par?” Don’t panic, my friend, I got you covered with some last-minute tips to improve your code quality before you hit that submit button.

## One Step Back

![One Step Back with a cup of coffee](https://miro.medium.com/v2/resize:fit:500/0*O1HDO67BYYpeksT4)



First things first, take a chill pill and step back from your code. Take a deep breath, grab a cup of coffee, or do whatever it takes to clear your mind. Then, take a good look at your code and ask yourself, “**Is this clean, readable, and easy to maintain**?” If not, you know what to do next.

## Use Tools

![](https://miro.medium.com/v2/resize:fit:700/1*XDO1-bil7MCLVMSXwQZhQw.png)

Use some fancy Integration Code review tools if you can. These tools can save your bacon by spotting any potential bugs, errors, or bad practices in your code. They’ll give you instant feedback, so you can fix any issues and feel confident that your code is top-notch.

**Test Coverage:**

-   [CodeCov](https://about.codecov.io/)
-   [CoverAlls](https://coveralls.io/)

**For Auto Code Review:**

-   [Codacy](https://www.codacy.com/) for code review, it says it could save 60% of code review time
-   [CodeFactor](https://www.codefactor.io/)

**Local Tools:**

-   [Git Hook](https://git-scm.com/docs/githooks) and [Husky](https://typicode.github.io/husky/) trigger scripts before commit, or push etc
-   [Prettier](https://prettier.io/), to make codes look prettier
-   [GH Gtihub CLI](https://cli.github.com/) create and review PR in one line of command and more

![](https://miro.medium.com/v2/resize:fit:564/1*-cDZ-VZaq-0fULnNxQK-Kw.png)

Github CLI — gh commands

Want to Know More about the Github CLI `gh` , you can read it here

[GitHub CLI: Your Secret Weapon for Slaying Code Reviews! | by Tech Tim (@TechTim42) | Mar, 2023 | Medium](https://medium.com/@TechTim42/github-cli-your-secret-weapon-for-slaying-code-reviews-47b454a4e33d)

## Prepare Yourself For Comments and Feedback

![Relax Yourself](https://miro.medium.com/v2/resize:fit:700/0*-BpH_ERb79XFu9km)



Now, here’s a pro tip: **be humble and open to suggestions**. Nobody’s perfect, and we all make mistakes. So, don’t be afraid to ask for feedback from your peers and reviewers. Listen to their suggestions, learn from their expertise, and make your code even better.

## Lastly, Remember Quality is More Important

![Code Qualiity is King](https://miro.medium.com/v2/resize:fit:700/0*JkptMhnzNw_Iflw8)
Code Qualiity is King


Lastly, remember that **quality is king**. Don’t rush to submit your PR just to meet a deadline. Take your time, prioritize quality over speed, and submit your code with confidence. Trust me, it’s better to delay submission and ensure code quality than to submit subpar code that can cause issues down the road.

Improving code quality doesn’t have to be stressful. Take a break, use some tools, ask for feedback, and prioritize quality. With these last-minute tips, you can submit your PR with ease and feel proud of your code. Happy coding!