☰ Menu
CLI Open source 4 installs/mo

trurl for Mac

trurl

Command-line tool for URL parsing and manipulation

trurl — overview

Command line tool for URL parsing and manipulation

Examples

Replace the hostname of a URL:

Create a URL by setting components:

Redirect a URL:

Change port number:

Extract the path from a URL:

Extract the port from a URL:

Append a path segment to a URL:

Append a query segment to a URL:

Read URLs from stdin:

Output JSON:

Remove tracking tuples from query:

Show a specific query key value:

Sort the key/value pairs in the query component:

Work with a query that uses a semicolon separator:

Accept spaces in the URL path:

Install

Linux

It is quite easy to compile the C source with GCC:

trurl is also available in some package managers. If it is not listed you can try searching for it using the package manager of your preferred distribution.

Windows Download and run Cygwin installer. Follow the instructions provided by the installer. When prompted to select packages, make sure to choose the following: curl, libcurl-devel, libcurl4, make and gcc-core. (optional) Add the Cygwin bin directory to your system PATH variable. Use make, just like on Linux.

Prerequisites

Development files of libcurl (e.g. libcurl4-openssl-dev or libcurl4-gnutls-dev) are needed for compilation. Requires libcurl version 7.62.0 or newer (the first libcurl to ship the URL parsing API).

trurl also uses CURLUPART_ZONEID added in libcurl 7.81.0 and curl_url_strerror() added in libcurl 7.80.0

It would certainly be possible to make trurl work with older libcurl versions if someone wanted to.

Older libcurls

trurl builds with libcurl older than 7.81.0 but will then not work as well. For all the documented goodness, use a more modern libcurl.

trurl / libcurl Compatibility

For more details on how trurl will behave if these features are missing see URL Quirks. To see the features your version of trurl supports as well as the version of libcurl it is built with, run the following command: trurl --version

Details

用于 URL 解析和操作的命令行工具

How to install trurl

  1. Open Terminal (press ⌘ + Space and type “Terminal”).
  2. If Homebrew is not installed yet, run the command below first.
  3. Run this command:

Latest 10 releases

Last updated 2025-05-12; current version trurl-0.16.1, with the latest 10 releases listed.

VersionReleasedTypeSizemacOSWindowsLinux
trurl-0.16.12025-05-12Stable63 KBDownload——
trurl-0.162024-09-19Stable58 KB———
trurl-0.15.12024-09-12Stable53 KB———
trurl-0.152024-08-28Stable53 KB———
trurl-0.142024-07-29Stable————
trurl-0.132024-05-15Stable————
trurl-0.122024-04-18Stable————
trurl-0.112024-04-18Stable————
trurl-0.102024-02-19Stable————
trurl-0.92023-10-31Stable————

Data from GitHub Releases; stable releases first, each group sorted newest first.

Compared with similar apps

Only public metadata is compared, with no subjective recommendation; see the compare pages for field-by-field comparisons.

Compared with similar apps
AppVersionLicenseArchitecture30-day installs
trurltrurl-0.16.1curlCLI4
cpptomlv0.1.1MITCLI915
perl-xml-parser2.59Artistic-2.0CLI17
libicns0.8.1LGPL-2.0-or-later OR LGPL-2.1-or-laterCLI6

Similar apps: Command-line Tools

Leave a comment

评论表单加载中…