Giter Club home page Giter Club logo

plugin-proxy's Introduction

proxy

A plugin for Oh My Fish.

MIT License Fish Shell Version Oh My Fish Framework


The proxy plugin provides a couple helper functions to those of us who are stuck behind HTTP/HTTPS/FTP proxies that require authentication. The variables it exports are used by many command-line and GUI applications on Linux, as well as MacPorts and Homebrew on OS X.

Both uppercase and lowercase versions of the proxy environment variables are set, some applications are case sensitive. If you'd like to learn more about the use of these variables, this Arch Wiki Article is a good place to start.

Install

$ omf install proxy

Usage

No authentication

If you just want to have the proxy plugin configure all the environment variables, you may set proxy_host and proxy_auth in $OMF_CONFIG/before.init.fish:

set proxy_host myproxy.example.com:8000
set proxy_auth false

The proxy plugin will prepend http:// for you. Here's the result:

~> set -x |grep proxy
ALL_PROXY http://myproxy.example.com:8000
FTP_PROXY http://myproxy.example.com:8000
HTTPS_PROXY http://myproxy.example.com:8000
HTTP_PROXY http://myproxy.example.com:8000
all_proxy http://myproxy.example.com:8000
ftp_proxy http://myproxy.example.com:8000
http_proxy http://myproxy.example.com:8000
https_proxy http://myproxy.example.com:8000

With authentication

Set your proxy host and username in $OMF_CONFIG/before.init.fish:

set proxy_host myproxy.example.com:8000
set proxy_auth true
set proxy_user mylogin

When you need to make use of the proxy, just run proxy. It will prompt you for a password and setup your environment.

If you didn't setup a proxy_user variable, you will be prompted for a username.

If you wish to clear your proxy variables, run noproxy.

License

MIT © oh-my-fish et al

plugin-proxy's People

Contributors

jhillyerd avatar bobthecow avatar zzamboni avatar merrickluo avatar scorphus avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.