Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upstream merge #5

Open
wants to merge 85 commits into
base: upstream_merge
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
85 commits
Select commit Hold shift + click to select a range
ff26f38
Add Gist link to a simple BASH function for the API
hashworks Nov 6, 2020
35c4b23
Add domain search
TheYahya Nov 11, 2020
cce84b7
Merge pull request #398 from hashworks/patch-1
poeti8 Nov 29, 2020
403d946
Merge pull request #404 from TheYahya/add-search-in-domains
poeti8 Nov 30, 2020
5e42185
fix: remove www when checking and adding domains
poeti8 Dec 12, 2020
2cbf79a
2.7.2
poeti8 Dec 12, 2020
a8b20f8
Add link to a simple BASH client with GUI
Jan 16, 2021
7084c07
chore(deps): bump elliptic from 6.5.3 to 6.5.4
dependabot[bot] Mar 8, 2021
bce0725
Merge pull request #442 from thedevs-network/dependabot/npm_and_yarn/…
poeti8 Mar 23, 2021
12c577c
Merge pull request #428 from Poldi1977/readme-changes
poeti8 Mar 23, 2021
71aadf6
docker build via github actions
xescure Mar 23, 2021
d064290
fix trigger
xescure Mar 23, 2021
2972292
not latest tag
xescure Mar 23, 2021
0cfc0be
watch for github releases
xescure Mar 23, 2021
a95aec9
removed unnecessary repo update
xescure Mar 23, 2021
40904e9
fix tags
xescure Mar 23, 2021
816fe85
Update docker-build-latest.yaml
xescure Mar 25, 2021
75dceae
Update docker-build-release.yaml
xescure Mar 25, 2021
9a9856f
chore(deps): bump y18n from 4.0.0 to 4.0.1
dependabot[bot] Mar 29, 2021
c7332e8
Merge pull request #454 from thedevs-network/dependabot/npm_and_yarn/…
poeti8 Apr 3, 2021
06fbebb
chore(deps): bump axios from 0.19.1 to 0.21.1
dependabot[bot] Apr 3, 2021
93e8a9f
Merge pull request #458 from thedevs-network/dependabot/npm_and_yarn/…
poeti8 Apr 3, 2021
d0c4fba
Merge pull request #450 from xescure/develop
poeti8 Apr 3, 2021
97ea40c
Add Front End Testing:
dependabot[bot] Mar 8, 2021
079ad42
Merge pull request #455 from ynonp/feature/frontend-testing
poeti8 Apr 11, 2021
86bb68f
Add direct links to docker files in README
hf-kklein Apr 14, 2021
f933e94
Merge pull request #464 from hf-kklein/patch-1
poeti8 Apr 14, 2021
16a6526
chore(deps): bump ssri from 6.0.1 to 6.0.2
dependabot[bot] Apr 19, 2021
bfe2c03
chore(deps): bump redis from 2.8.0 to 3.1.1
dependabot[bot] Apr 27, 2021
3c78456
Merge pull request #470 from thedevs-network/dependabot/npm_and_yarn/…
poeti8 May 2, 2021
d4526f5
Merge pull request #465 from thedevs-network/dependabot/npm_and_yarn/…
poeti8 May 2, 2021
a6595da
Added Kutt.NET wrapper
AlphaNecron Jun 29, 2021
4030673
added cross-env for env setup
Rupeshiya Jul 2, 2021
148a25a
added logging mechanism
Rupeshiya Jul 3, 2021
bfcb51c
Merge pull request #485 from AlphaNecron/patch-1
poeti8 Jul 3, 2021
de31326
Merge pull request #488 from Rupeshiya/dev_env
poeti8 Jul 3, 2021
46e6f36
Merge pull request #489 from Rupeshiya/loggin
poeti8 Jul 11, 2021
804ea0c
fix: disallow duplicated links when editing links
poeti8 Sep 3, 2021
0bc0e66
2.7.3
poeti8 Sep 3, 2021
9cbbade
feat: change link password
zzwt Dec 3, 2021
8fe09fd
Delete .template.env
hashlash Jan 20, 2022
7498e4d
Improve docker setup docs
hashlash Jan 21, 2022
10c9145
Sanitize neo4j password
8sd Jan 25, 2022
a7fe4d3
Merge pull request #558 from 8sd/sanitize
poeti8 Jan 30, 2022
291d52a
fix: disallow anonymous links when enabled for v1 api
poeti8 Jan 30, 2022
e9ea809
2.7.4
poeti8 Jan 30, 2022
6d42598
spelling: example
jsoref May 31, 2022
da496bf
spelling: extension
jsoref May 31, 2022
daf989e
spelling: increment
jsoref May 31, 2022
271c8cc
spelling: pqueue
jsoref May 31, 2022
a4540b5
spelling: redirect
jsoref May 31, 2022
d05128c
spelling: requested
jsoref May 31, 2022
a5af57a
spelling: shortened
jsoref May 31, 2022
3539fa7
spelling: strategy
jsoref May 31, 2022
a68e933
Changed 301 Redirect to 302
JabobKrauskopf Jun 8, 2022
91e7ced
Update README.md
Poldi1977 Jul 10, 2022
430b874
Merge pull request #613 from Poldi1977/Poldi1977-README-URL
poeti8 Sep 4, 2022
55fa84c
disableAmbjguOusCharacters
fashberg Oct 15, 2022
6055213
feat: add support for redis db number
poeti8 Nov 10, 2022
05cc146
Merge pull request #648 from thedevs-network/task/redis-db-number
poeti8 Nov 10, 2022
52186d2
Merge pull request #554 from hashlash/patch-1
poeti8 Nov 10, 2022
bd082d5
Merge pull request #555 from hashlash/patch-2
poeti8 Nov 10, 2022
987bafd
Merge pull request #537 from zzwt/feature/change-link-password
poeti8 Nov 10, 2022
8bfd412
fix: remove check user validation
poeti8 Nov 10, 2022
50a01f3
style: use password dot unicode character for password placeholder
poeti8 Nov 10, 2022
0366c64
Merge pull request #654 from thedevs-network/fix/change-link-password
poeti8 Nov 10, 2022
5b3a5ba
Create FUNDING.yml
poeti8 Nov 13, 2022
caeb533
Delete FUNDING.yml
poeti8 Nov 13, 2022
96dc5d1
Merge pull request #603 from jsoref/spelling
poeti8 Nov 25, 2022
046ef79
Merge pull request #604 from JabobKrauskopf/develop
poeti8 Nov 25, 2022
bfb1001
add enhancement for logging
jay-choe Nov 26, 2022
05197b8
Merge pull request #629 from jay-choe/develop
poeti8 Nov 26, 2022
d5debac
Merge pull request #640 from fashberg/disableAmbjguOusCharacters
poeti8 Nov 29, 2022
5594e56
chore: remove sentry
poeti8 Nov 10, 2022
e255d50
chore: remove babel and tests
poeti8 Nov 10, 2022
9f6897b
chore: remove remaining sentry env
poeti8 Nov 10, 2022
ea9ac99
chore: remove v1 endpoints and neo4j migration guide
poeti8 Nov 29, 2022
f5a8e0f
chore:(deps): update knex type imports
poeti8 Nov 10, 2022
7e7cba7
chore(deps): initialize dotenv before using envalid
poeti8 Nov 10, 2022
f7c6df2
chore(deps): update axios error type
poeti8 Nov 10, 2022
4e672a8
chore(deps)update deps, remove google analytics
poeti8 Nov 25, 2022
3fe86eb
chore: remve unused api enum
poeti8 Nov 29, 2022
e434e9e
chore: ignore unused variable for error handler
poeti8 Nov 29, 2022
ea63139
fix: import correct neoid generator
poeti8 Nov 29, 2022
041aed5
Merge pull request #657 from thedevs-network/chore/update-deps
poeti8 Nov 29, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 0 additions & 10 deletions .babelrc

This file was deleted.

16 changes: 1 addition & 15 deletions .docker.env
Original file line number Diff line number Diff line change
Expand Up @@ -18,16 +18,11 @@ DB_USER=
DB_PASSWORD=
DB_SSL=false

# ONLY NEEDED FOR MIGRATION !!1!
# Neo4j database credential details
NEO4J_DB_URI=bolt://localhost
NEO4J_DB_USERNAME=neo4j
NEO4J_DB_PASSWORD=BjEphmupAf1D5pDD

# Redis host and port
REDIS_HOST=redis
REDIS_PORT=6379
REDIS_PASSWORD=
REDIS_DB=

# Disable registration
DISALLOW_REGISTRATION=false
Expand Down Expand Up @@ -64,15 +59,6 @@ RECAPTCHA_SECRET_KEY=
# Get it from https://developers.google.com/safe-browsing/v4/get-started
GOOGLE_SAFE_BROWSING_KEY=

# Google Analytics tracking ID for universal analytics.
# Example: UA-XXXX-XX
GOOGLE_ANALYTICS=
GOOGLE_ANALYTICS_UNIVERSAL=

# Google Analytics tracking ID for universal analytics
# This one is used for links
# GOOGLE_ANALYTICS_UNIVERSAL=

# Your email host details to use to send verification emails.
# More info on http://nodemailer.com/
# Mail from example "Kutt <[email protected]>". Leave empty to use MAIL_USER
Expand Down
31 changes: 7 additions & 24 deletions .eslintrc
Original file line number Diff line number Diff line change
@@ -1,39 +1,22 @@
{
"extends": [
"eslint:recommended",
"next/core-web-vitals",
"plugin:@typescript-eslint/recommended",
"plugin:prettier/recommended"
"prettier"
],
"parser": "@typescript-eslint/parser",
"parserOptions": {
"ecmaVersion": "latest",
"sourceType": "module",
"project": ["./tsconfig.json", "./client/tsconfig.json"]
},
"plugins": ["@typescript-eslint"],
"plugins": ["@typescript-eslint", "prettier"],
"rules": {
"eqeqeq": ["warn", "always", { "null": "ignore" }],
"no-useless-return": "warn",
"no-var": "warn",
"no-console": "warn",
"max-len": ["warn", { "comments": 80 }],
"no-param-reassign": 0,
"require-atomic-updates": 0,
"@typescript-eslint/interface-name-prefix": "off",
"@typescript-eslint/no-unused-vars": "off", // "warn" for production
"@typescript-eslint/no-explicit-any": "off", // "warn" for production
"@typescript-eslint/no-var-requires": "off",
"@typescript-eslint/camelcase": "off",
"@typescript-eslint/no-object-literal-type-assertion": "off",
"@typescript-eslint/no-parameter-properties": "off",
"@typescript-eslint/explicit-function-return-type": "off"
"@typescript-eslint/no-explicit-any": ["off"]
},
"env": {
"es6": true,
"browser": true,
"node": true,
"mocha": true
},
"globals": {
"assert": true
"node": true
},
"settings": {
"react": {
Expand Down
18 changes: 3 additions & 15 deletions .example.env
Original file line number Diff line number Diff line change
Expand Up @@ -18,16 +18,13 @@ DB_USER=
DB_PASSWORD=
DB_SSL=false

# ONLY NEEDED FOR MIGRATION !!1!
# Neo4j database credential details
NEO4J_DB_URI=bolt://localhost
NEO4J_DB_USERNAME=neo4j
NEO4J_DB_PASSWORD=BjEphmupAf1D5pDD

# Redis host and port
REDIS_HOST=127.0.0.1
REDIS_PORT=6379
REDIS_PASSWORD=
# Optional: The number for Redis database, between 0 and 15. Defaults to 0.
# If you don't know what this is, then you probably don't need to change it.
REDIS_DB=0

# Disable registration
DISALLOW_REGISTRATION=false
Expand Down Expand Up @@ -65,15 +62,6 @@ RECAPTCHA_SECRET_KEY=
# Get it from https://developers.google.com/safe-browsing/v4/get-started
GOOGLE_SAFE_BROWSING_KEY=

# Google Analytics tracking ID for universal analytics.
# Example: UA-XXXX-XX
GOOGLE_ANALYTICS=
GOOGLE_ANALYTICS_UNIVERSAL=

# Google Analytics tracking ID for universal analytics
# This one is used for links
# GOOGLE_ANALYTICS_UNIVERSAL=

# Your email host details to use to send verification emails.
# More info on http://nodemailer.com/
# Mail from example "Kutt <[email protected]>". Leave empty to use MAIL_USER
Expand Down
45 changes: 45 additions & 0 deletions .github/workflows/docker-build-latest.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
name: docker-build-latest

env:
dockerhub_repository: "kutt/kutt"
dockerhub_tag: "develop"

on:
push:
branches:
- develop

jobs:
dockerhub-build-push:
runs-on: ubuntu-latest
steps:
-
name: Checkout
uses: actions/checkout@v2
-
name: Set up QEMU
uses: docker/setup-qemu-action@v1
-
name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
-
name: Login to DockerHub
uses: docker/login-action@v1
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
-
name: Build and push
uses: docker/build-push-action@v2
with:
context: .
platforms: linux/amd64,linux/arm64,linux/arm/v7
push: true
tags: ${{ env.dockerhub_repository }}:${{ env.dockerhub_tag }}
-
name: Update repo description
uses: peter-evans/dockerhub-description@v2
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_PASSWORD }}
repository: ${{ env.dockerhub_repository }}
36 changes: 36 additions & 0 deletions .github/workflows/docker-build-release.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: docker-build-latest

env:
dockerhub_repository: "kutt/kutt"

on:
release:
types: [published]

jobs:
dockerhub-build-push:
runs-on: ubuntu-latest
steps:
-
name: Checkout
uses: actions/checkout@v2
-
name: Set up QEMU
uses: docker/setup-qemu-action@v1
-
name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
-
name: Login to DockerHub
uses: docker/login-action@v1
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
-
name: Build and push
uses: docker/build-push-action@v2
with:
context: .
platforms: linux/amd64,linux/arm64,linux/arm/v7
push: true
tags: ${{ env.dockerhub_repository }}:${{ github.event.release.tag_name }}, ${{ env.dockerhub_repository }}:latest
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
.env
.vscode/
logs
client/.next/
node_modules/
client/config.js
Expand Down
4 changes: 4 additions & 0 deletions .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#!/usr/bin/env sh
. "$(dirname -- "$0")/_/husky.sh"

npm run lint:nofix
63 changes: 0 additions & 63 deletions .template.env

This file was deleted.

44 changes: 0 additions & 44 deletions MIGRATION.md

This file was deleted.

36 changes: 17 additions & 19 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,6 @@ _Contributions and bug reports are welcome._
[![GitHub license](https://img.shields.io/github/license/thedevs-network/kutt.svg)](https://github.com/thedevs-network/kutt/blob/develop/LICENSE)
[![Twitter](https://img.shields.io/twitter/url/https/github.com/thedevs-network/kutt/.svg?style=social)](https://twitter.com/intent/tweet?text=Wow:&url=https%3A%2F%2Fgithub.com%2Fthedevs-network%2Fkutt%2F)

## Migration from v1

The new version of Kutt is here. In version 2, we used TypeScript and we moved from Neo4j to PostgreSQL database in favor of performance and we're working on adding new features.

If you're coming from v1, refer to [MIGRATION.md](MIGRATION.md) to migrate data from Neo4j to PostgreSQL.

## Table of Contents

- [Key Features](#key-features)
Expand Down Expand Up @@ -72,8 +66,9 @@ You need to have [Node.js](https://nodejs.org/), [PostgreSQL](https://www.postgr

### Docker

Download the `docker-compose.yml` and the `.docker.env`-file from the repository and configure the `.docker.env` ([see below](#configuration)).
To execute Kutt you simply have to run `docker-compose up -d` command and then the app should be ready on port "3000".
1. Download the [`docker-compose.yml`](https://raw.githubusercontent.com/thedevs-network/kutt/develop/docker-compose.yml) and the [`.docker.env`](https://raw.githubusercontent.com/thedevs-network/kutt/develop/.docker.env) files.
2. Rename `.docker.env` to `.env` and fill it properly ([see below](#configuration)).
3. To execute Kutt you simply have to run `docker-compose up -d` command and then the app should be ready on port "3000".

The `docker-compose.yml` uses the official kutt docker image available on [Docker Hub](https://hub.docker.com/r/kutt/kutt).

Expand Down Expand Up @@ -110,17 +105,20 @@ You can use Kutt as your default URL shortener in [ShareX](https://getsharex.com
Download Kutt's official workflow for [Alfred](https://www.alfredapp.com/) app from [alfred-kutt](https://github.com/thedevs-network/alfred-kutt) repository.

## 3rd Party packages
| Language | Link | Description |
| ---------- | ---------------------------------------------------------- | -------------------------------------------------- |
| C# (.NET) | [KuttSharp](https://github.com/0xaryan/KuttSharp) | .NET package for Kutt.it url shortener |
| Python | [kutt-cli](https://github.com/RealAmirali/kutt-cli) | Command-line client for Kutt written in Python |
| Ruby | [kutt.rb](https://github.com/RealAmirali/kutt.rb) | Kutt library written in Ruby |
| Rust | [urlshortener](https://github.com/vityafx/urlshortener-rs) | URL shortener library written in Rust |
| Rust | [kutt-rs](https://github.com/robatipoor/kutt-rs) | Command line tool written in Rust |
| Node.js | [node-kutt](https://github.com/ardalanamini/node-kutt) | Node.js client for Kutt.it url shortener |
| JavaScript | [kutt-vscode](https://github.com/mehrad77/kutt-vscode) | Visual Studio Code extention for Kutt |
| Java | [kutt-desktop](https://github.com/cipher812/kutt-desktop) | A Cross platform Java desktop application for Kutt |
| Go | [kutt-go](https://github.com/raahii/kutt-go) | Go client for Kutt.it url shortener |
| Language | Link | Description |
| ---------- | --------------------------------------------------------------------------------- | -------------------------------------------------- |
| C# (.NET) | [KuttSharp](https://github.com/0xaryan/KuttSharp) | .NET package for Kutt.it url shortener |
| C# (.NET) | [Kutt.NET](https://github.com/AlphaNecron/Kutt.NET) | ✂️🔗 C# API Wrapper for Kutt
| Python | [kutt-cli](https://github.com/RealAmirali/kutt-cli) | Command-line client for Kutt written in Python |
| Ruby | [kutt.rb](https://github.com/RealAmirali/kutt.rb) | Kutt library written in Ruby |
| Rust | [urlshortener](https://github.com/vityafx/urlshortener-rs) | URL shortener library written in Rust |
| Rust | [kutt-rs](https://github.com/robatipoor/kutt-rs) | Command line tool written in Rust |
| Node.js | [node-kutt](https://github.com/ardalanamini/node-kutt) | Node.js client for Kutt.it url shortener |
| JavaScript | [kutt-vscode](https://github.com/mehrad77/kutt-vscode) | Visual Studio Code extension for Kutt |
| Java | [kutt-desktop](https://github.com/cipher812/kutt-desktop) | A Cross platform Java desktop application for Kutt |
| Go | [kutt-go](https://github.com/raahii/kutt-go) | Go client for Kutt.it url shortener |
| BASH | [GitHub Gist](https://gist.github.com/hashworks/6d6e4eae8984a5018f7692a796d570b4) | Simple BASH function to access the API |
| BASH | [url-shortener](https://git.tim-peters.org/Tim/url-shortener) | Simple BASH script with GUI |

## Donate

Expand Down
Loading