Skip to main content

BaseApp URL Shortening

Project description

BaseApp URL Shortening

Reusable app to enable url shortening.

How to install:

Add dependencies to your requirements/base.txt file:

baseapp-core @ git+https://github.com/silverlogic/baseapp-backend.git@v0.1#subdirectory=baseapp-core
baseapp-reactions @ git+https://github.com/silverlogic/baseapp-backend.git@v0.1#subdirectory=baseapp-url-shortening

And run provision or manually pip install -r requirements/base.ext

If you want to develop, install using this other guide.

How to use

Add baseapp_url_shortening to your project's INSTALLED_APPS

Add the following to your settings file. URL_SHORTENING_PREFIX can be any string

URL_SHORTENING_PREFIX = "c"

Add the following to your apps/urls.py file

urlpatterns = [
    re_path(r"", include("baseapp_url_shortening.urls")),
]

Writing test cases in your project

There is a ShortUrlFactory which helps you write other factories:

import factory
from baseapp_url_shortening.tests.factories import ShortUrlFactory

How to develop

Clone the project inside your project's backend dir:

git clone git@github.com:silverlogic/baseapp-backend.git

And manually install the package:

pip install -e baseapp-backend/baseapp-url-shortening

The -e flag will make it like any change you make in the cloned repo files will effect into the project.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

baseapp-url-shortening-0.1.1.tar.gz (5.1 kB view details)

Uploaded Source

File details

Details for the file baseapp-url-shortening-0.1.1.tar.gz.

File metadata

File hashes

Hashes for baseapp-url-shortening-0.1.1.tar.gz
Algorithm Hash digest
SHA256 6ef3827922dac0702aa941739499b88e0803a8aa65f8322c8e1e93fa22ca2afa
MD5 a81221db35e74c76266f42a0e5abe1d4
BLAKE2b-256 78385a223bb8fa6514ae4c364cd7c3b6b21d9f685316c5f511d7a1d5152caa7e

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page