Categorygithub.com/InternPulse/famtrust-backend-auth
module
0.0.0-20240802020004-f73226ee720e
Repository: https://github.com/internpulse/famtrust-backend-auth.git
Documentation: pkg.go.dev

# README

FamTrust Backend Auth API

Project Overview

Live link is at https://auth.famtrust.biz/api/v1

Doc link at https://auth.famtrust.biz/api/docs/index.html

Installation Instructions

Prerequisites

Before setting up the project locally, ensure you have the following prerequisites installed:

  • Go (>=1.22.3)
  • A Database System (e.g., PostgreSQL, MySQL, SQLite)

How to run API Locally

  1. Clone the repository:
git clone https://github.com/InternPulse/famtrust-backend-auth.git
  1. Change into the parent directory:
cd famtrust-backend-auth
  1. Set appropriate values for the following Compulsory Environment Variables:
# Postgres connection string
POSTGRES_DSN=""
# Secret key for signing JWTs
JWTKEY=""
  1. Start the App:
go run ./cmd/api

The API should now be running locally at http://localhost:8001/.

Commit Standards

Branches

  • dev -> pr this branch for everything backend related
  • main -> dont touch this branch, this is what is running in production!

Contributions

famtrust-backend-auth is open to contributions, but I recommend creating an issue or replying in a comment to let us know what you are working on first that way we don't overwrite each other.

Contribution Guidelines

  1. Clone the repo git clone https://github.com/InternPulse/famtrust-backend-auth.git.
  2. Open your terminal & set the origin branch: git remote add origin https://github.com/InternPulse/famtrust-backend-auth.git
  3. Pull origin git pull origin dev
  4. Create a new branch for the task you were assigned to, eg TicketNumber/(Feat/Bug/Fix/Chore)/Ticket-title : git checkout -b BA-001/Feat/Sign-Up-from
  5. After making changes, do git add .
  6. Commit your changes with a descriptive commit message : git commit -m "your commit message".
  7. To make sure there are no conflicts, run git pull origin dev.
  8. Push changes to your new branch, run git push -u origin feat-csv-parser.
  9. Create a pull request to the dev branch not main.
  10. Ensure to describe your pull request.
  11. If you've added code that should be tested, add some test examples.

Merging

Under any circumstances should you merge a pull request on a specific branch to the dev or main branch

Commit CheatSheet

TypeDescription
featFeaturesA new feature
fixBug FixesA bug fix
docsDocumentationDocumentation only changes
styleStylesChanges that do not affect the meaning of the code (white-space, formatting, missing semi-colons, etc.)
refactorCode RefactoringA code change that neither fixes a bug nor adds a feature
perfPerformance ImprovementsA code change that improves performance
testTestsAdding missing tests or correcting existing tests
buildBuildsChanges that affect the build system or external dependencies (example scopes: gulp, broccoli, npm)
ciContinuous IntegrationsChanges to our CI configuration files and scripts (example scopes: Travis, Circle, BrowserStack, SauceLabs)
choreChoresOther changes that don't modify, backend or test files
revertRevertsReverts a previous commit

Sample Commit Messages

  • chore: Updated README file:= chore is used because the commit didn't make any changes to the backend or test folders in any way.
  • feat: Added plugin info endpoints:= feat is used here because the feature was non-existent before the commit.

# Packages

No description provided by the author
Package docs Code generated by swaggo/swag.