This project demonstrates basic CRUD operations using the Go programming language.
- Clone this project:
git clone https://github.com/afurgapil/go-url-shortener.git
- Navigate to the project directory:
cd go-url-shortener
- Create the urls table on your MySQL server by running the
db-schema.sql
file. - Install dependencies:
go mod tidy
- Check
.env
file
- Run the server:
go run cmd/go-url-shortener/main.go
- Access the API using an HTTP client.
Test files are located in the test folder.
To run all tests go test ./test/... -v
If you encounter any issues or have suggestions for improvements, please feel free to contribute. Your feedback is highly appreciated and contributes to the learning experience.
I especially need help in automating test processes. I have an automation experiment in .github/workflows/go.yaml, but I couldn't get the docker, mysql and test process to work properly. your help on this would make me very happy!
This project is licensed under the MIT License. For more information, please refer to the LICENSE file.