open

package module
v0.1.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 27, 2019 License: MIT Imports: 3 Imported by: 3

README

go-open

Cross-platform CLI application to open files, directories, URLs from the command-line, written in Go.

Build Status

Install

API
go get github.com/pbnj/go-open
CLI
go get github.com/pbnj/go-open/cmd/gopen

Usage

API
import open "github.com/pbnj/go-open"

open.Open("file.txt")             // will open file in default text editor
open.Open("https://google.com")   // will open url in default browser
open.Open("image.png")            // will open image in default image editor
CLI
gopen file.txt
gopen https://google.com
gopen some_file.txt another_file.txt https://google.com https://github.com

License

MIT © 2017 Peter Benjamin

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Open

func Open(obj string) error

Open will open resources (e.g. files, URLs ...etc) in their default applications

Types

This section is empty.

Directories

Path Synopsis
cmd

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL