Skip to content

l0.DependencyControl.helpers.open-url

open_url = require "l0.DependencyControl.helpers.open-url"
local open_url = require("l0.DependencyControl.helpers.open-url")

Functions

open

open_url.open url
open_url.open(url)

Opens an http(s) URL in the user's default browser. The URL is validated and never passed through a shell command line, so an attacker-controlled feed URL can't inject a command.

param type description
url string The URL to open.

Returns:

  • ok true? — True on success; nil if the URL was rejected, the platform is unsupported, or the open failed.
  • err string? — A human-readable reason on failure; nil on success.