AmanoTeam / Unalix-nim

Small, dependency-free, fast Nim package and CLI tool for removing tracking fields from URLs.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Unalix

Unalix is a library and CLI tool written in Nim, it implements the specification used by the ClearURLs addon for removing tracking fields from URLs.

Installation

Install using nimble:

nimble install --accept 'unalix'

Note: Unalix requires Nim 1.4.0 or higher.

Usage:

Removing tracking fields:

import unalix

const url: string = "https://deezer.com/track/891177062?utm_source=deezer"
let result: string = clearUrl(url = url)

assert result == "https://deezer.com/track/891177062"

Resolving shortened URL:

import unalix

const url: string = "https://bitly.is/Pricing-Pop-Up"
let result: string = unshortUrl(url = url)

assert result == "https://bitly.com/pages/pricing"

Tip: The unshortUrl() proc will strip tracking fields from any URL before following a redirect, so you don't need to manually call clearUrl() for it's return value.

Downloads

You can get prebuilt static executables of the CLI tool for Linux and Android here.

Contributing

If you have discovered a bug in this library and know how to fix it, fork this repository and open a Pull Request.

Third party software

Unalix includes some third party software in its codebase. See them below:

About

Small, dependency-free, fast Nim package and CLI tool for removing tracking fields from URLs.

License:GNU Lesser General Public License v3.0


Languages

Language:Nim 85.3%Language:C 14.7%