Saravanan666/pypi-org huggingface dataset:
Package: xontrib-cd
cdto any path without escaping inxonsh shell.Replacescdat the start of a line with asubprocess macrocd!If you like the idea click ⭐ on the repo and stay tuned.Installxpip install xontrib-cd
# or: xpip install -U git+https://github.com/eugenesvk/xontrib-cdThis xontrib will get loaded automatically for interactive sessions; to stop this, set$XONTRIBS_AUTOLOAD_DISABLED = {"cd", }ConfigureSet the following environment variables in your profile to enableextra options(disabled by default):$XONTRIB_CD_ALTSYMLINKFLAG = Trueto pass-p,-f, or-sflags (in addition to-P) to follow symlinks$XONTRIB_CD_ALTSYMLINKFUNC = Trueto usecdp,cdf, orcds(in addition tocd -P) to follow symlinks$XONTRIB_CD_SYMLINKAlWAYSON = Trueto makecdalways follow symlinks (always pass-P)$XONTRIB_CD_LASTCMD = Trueto makecdalso work when it's the last command in a multi-command lineUseUsecdas usual, but without the fear of copying&pasting arbitrary paths (e.g..../space separated/or.../[bracketed]/)xontrib load cd
cd ~/[Path] With Spaces	# equivalent to 'cd! ~/[Path] With Spaces'
cd C:/Program Files    	# equivalent to 'cd! C:/Program Files'
cd -P ~/SymlinkTo      	# follow symlinks, equivalent to 'cd -P! ~/SymlinkTo'Add a space beforecdto disable adding!Known issuesXontrib autoload can't be disabled and prevents user configured environment vars from being read on time due to axonsh bug, so if you want to change the default configs via env vars, install the deauto branchxpip install -U git+https://github.com/eugenesvk/xontrib-cd@deautoMultiple commands per line likecd ~; echo 1will fail sincecdis replaced withcd!, and everything after!is treated as a single string argument, ignoring the;separatorsButecho 1; cd ~will work with$XONTRIB_CD_LASTCMDCreditsThis package was created withxontrib cookiecutter templatebased on the idea of hooking into the command line input as implemented inxontrib-sh
Package: xontrib-chatgpt
Gives the ability to use ChatGPT directly from the command lineIf you like the idea click ⭐ on the repo andtweet.InstallationTo install use pip:xpip install xontrib-chatgpt
# or: xpip install -U git+https://github.com/jpal91/xontrib-chatgptThen use the following command in yourxonshshell or add it directly to your.xonshrcxontrib load chatgptEnvironment Variables❗REQUIRED❗# Recommended you put this in your .xonshrc
$OPENAI_API_KEY = <your api key>If you do not have an api key, you can create an account onOpenAI. You will need to add a credit card on file to pay for any of the api usage charges.You are 100% responsible for any and all cost you incur by using this xontrib.For more information onOpenAIusage pricing, please go toOpenAI Pricing.Optional$OPENAI_CHAT_MODEL = 'gpt-3.5-turbo'If this is not set, it will default togpt-3.5-turbo. Currently the only accepted options aregpt-3.5-turboorgpt-4.UsageNEW in Version 0.1.3Usechat-managerto easily create and manage new chatschat-manager add gpt
gpt "Hello, what's your name?"
# ChatGPT responds hereUse your chat as a callable alias orxonshcontext blockecho "Hello, what's your name" | gpt
gpt < input.txt
echo @(myvar) | gpt

# The entire contents of the block is sent as text to ChatGPT
with! gpt:
   Can you help me fix my python function?

   def hello_world():
      return
      print('Hello, world!')To get see more CLI options:chat-manager -hTo get a quick tutorial:chat-manager help
# or
chat-manager?⭐BONUS: Ifxontrib-abbrevsis loaded, usecmto expand tochat-managerSee AlsoTips and TricksHow To Edit System MessagesFuture PlansStreaming ResponsesExpand the ability to get streaming responses on the command line as opposed to waiting until the full completion is doneChat SettingsAllow customizable max tokensAllow each chat to have separate models (ie 3.5-turbo, 4, etc.)Timeouts on long responsesUpdate individual instance system messages/chat instructionsNEW in v0.1.6Additional ModelsOpen up the ability to use other models besides 3.5 and 4CompletionsNEW in v0.1.5Helper completions forchat-managerCreditsThis package was created withxontrib template.Xonsh Documentationprompt_toolkitPygmentsAwesome Xontribs- Much inspiration was taken from many projects in this fantastic repo
Package: xontrib-clp
Copy output to clipboard. Cross-platform.If you like the idea click ⭐ on the repo andtweet.InstallationTo install use pip:xpipinstallxontrib-clp# OR: xpip install -U git+https://github.com/anki-code/xontrib-clpUsagexontrib load clp
echo hello | clp   # Copy "hello\n" to clipboardUse casespyperclip$XONTRIB_CLP_ALIAS = 'pyperclip'  # default
xontrib load clp
echo hello | clp   # Copy "hello\n" to clipboard using pyperclipshutil$XONTRIB_CLP_ALIAS = 'shutil'  # default
xontrib load clp
echo hello | clp   # Copy "hello\n" to clipboard using platform-depending tool: pbcopy, xclip, etcCreditsThis package was created withxontrib template.
Package: xontrib-cmd-done
Send notification once long running command is finished. Add duration PROMP_FIELD.If you like the idea click ⭐ on the repo and stay tuned.InstallationTo install use pip:xpipinstallxontrib-cmd-done# or: xpip install -U git+https://github.com/jnoortheen/xontrib-cmd-doneUsagexontribloadcmd_doneExamples$RIGHT_PROMPT='{long_cmd_duration:⌛{}}{user:{{BOLD_RED}}🤖{}}{hostname:{{BOLD_#FA8072}}🖥{}}'CreditsThis package was created withxontrib cookiecutter template.
Package: xontrib-cmd-durations
OverviewSend notification once long-running command is finished and also show the execution time..InstallationTo install use pip:xpipinstallxontrib-cmd-durations# or: xpip install -U git+https://github.com/jnoortheen/xontrib-cmd-durationsUsageAdd thelong_cmd_durationsection to theprompt fieldsand load the xontrib i.e.:$RIGHT_PROMPT='{long_cmd_duration:⌛{}}{user:{{BOLD_RED}}🤖{}}{hostname:{{BOLD_#FA8072}}🖥{}}'$XONTRIB_CD_LONG_DURATION=5# defaultxontribloadcmd_doneIf the command is taking more than$XONTRIB_CD_LONG_DURATIONseconds thenlong_cmd_durationreturns the duration in human readable way:The desktop notification is sent if the terminal is not focused:Currently the focusing part requiresxdotoolto be installed.Known issuesnotifications in WindowsOn windows the notification will get triggered all the time.Finding whether the terminal is focusedis not implemented for Windows yet and PRs are very welcome on that.
Set$XONTRIB_CD_TRIGGER_NOTIFICATION = Falseto completely off the notification part.CreditsThis package was created withxontrib cookiecutter template.
Package: xontrib-common-fate-granted
UseCommon Fate's Granted CLI toolfor switching AWS profiles inXonsh shellIf you like the idea click ⭐ on the repo andtweet.PrerequisitesInstallGrantedand ensure theassumegocommand is in your path already (trywhich assumego).InstallationTo install use pip:xpipinstallxontrib-common-fate-granted# or: xpip install -U git+https://github.com/eppeters/xontrib-common-fate-grantedUsageLoad the plugin in your.xonshrc.e.g.:xontrib load common_fate_grantedYou can useassumenow, just like people who use boring old shells!...Known issuesPlease file an issue if you encounter a bug!...CreditsThis package was created withxontrib template.This port was first documented byEddie Petersin ablog post on dinogalactic.com
Package: xontrib-debug-tools
Debug tools for xonsh shell.If you like the idea click ⭐ on the repo andtweet.InstallationTo install use pip:xpipinstallxontrib-debug-tools# or: xpip install -U git+https://github.com/xonsh/xontrib-debug-toolsUsageThe package contains:pdb- Simple built-in debugger. Runs pdb on reception ofSIGUSR1 signal.xog- Simple command to establish and print$XONSH_TRACEBACK_LOGFILE.pdbxontribloadpdbxogxontribloadxog
xog--helpCreditsThis package was created withxontrib template.
Package: xontrib-default-command
xontrib-default-commandThisOh-My-Xonshplugin for thexonshshell runs a default command when you
press return on an empty command line.By default, this command will runls. If$PWDis a git project, it will also
run a short git status withgit status -s.CustomizingYou can redefine thedefaultcmdfunction in yourrc.xshto do whatever you want.For example, if you want a detailedlsandgit status, you could do this instead:defdefaultcmd():"""Run a detailed ls and git status when no other command given"""newcmd="ls -laFG"ifp'$PWD/.git'.exists():newcmd+=" && git status"returnnewcmdInstallationInstall from PyPI viaxpip:xpipinstallxontrib-default-command# or: xpip install -U git+https://github.com/oh-my-xonsh/xontrib-default-commandThen, add this to yourrc.xsh:xontribloaddefault_commandSimilar projectsZsh has anauto-ls plugin
Package: xontrib-distributed
Thedistributedparallel computing library hooks for xonshIf you like the idea click ⭐ on the repo andtweet.Importantly this provides a substitute 'dworker' command
which enables distributed workers to have access to xonsh builtins.Furthermore, this xontrib adds a 'DSubmitter' context manager
for executing a block remotely.
Moreover, this also adds a convenience function 'dsubmit()'
for creating DSubmitter and Executor instances at the same time.Thus users may submit distributed jobs with::with dsubmit('127.0.0.1:8786', rtn='x') as dsub:x = $(echo I am elsewhere)res = dsub.future.result()print(res)This is useful for long running or non-blocking jobs.InstallationTo install use pip:xpipinstallxontrib-distributed# or: xpip install -U git+https://github.com/xonsh/xontrib-distributedUsagexontribloaddistributed# TODO: what's next?Releasing your packageBump the version of your package.Create a GitHub release (The release notes are automatically generated as a draft release after each push).And publish withpoetry publish --buildortwineCreditsThis package was created withxontrib cookiecutter template.
Package: xontrib-django
Django auto-completions for Xonsh shellInstallationTo install use pip:xpipinstallxontrib-django# or: xpip install -U git+https://github.com/jnoortheen/xontrib-djangoUsagexontribloaddjangoReleasing your packageBump the version of your package.Create a GitHub release (The release notes are automatically generated as a draft release after each push).And publish withpoetry publish --buildortwine
Package: xontrib-enhancd
[b4b4r07/enhancd](https://github.com/b4b4r07/enhancd) for xonshInstallationTo install use pip:$ xpip install xontrib-enhancdOr clone the repo:$ pip install git+https://github.com/sun-yryr/enhancdUsagein xonsh$ xontrib load enhancdContributing[sun-yryr](https://twitter.com/taittide)CreditsThis package was created withcookiecutterand thexontribtemplate.
Package: xontrib-ergopack
Meta package that installs group of ergonomic xontribs in xonsh shell.If you like the idea click ⭐ on the repo and stay tuned.Default xontribsBy default ergopack contains xontribs that do not change the prompt or commands processing.
The xontribs that do more significant changes are in PyPi "extras".xpipinstall-Uxontrib-ergopackargcomplete- Tab completion of python and xonsh scripts.back2dir- Return to the most recently used directory when starting xonsh shell.output_search-  Get words from the previous command output for the next command. Not activated by default.pipeliner- Let your pipe lines flow thru the Python code.sh- Paste and run commands from bash, zsh, fish, tcsh in xonsh shell.autoxsh- Automatically execution of.autoxshxonsh script after entering into the directory. Not activated by default.history_encrypt- History backend that can encrypt the xonsh shell commands history. Not activated by default.clp- Copy output to clipboard. Cross-platform.cmd-durations- Show long running commands durations in prompt with option to send notification when terminal is not focused.Onepath xontribsxpipinstall-U'xontrib-ergopack[onepath]'onepath- Associate files with app and run it without preceding commands.All default xontribs.Prompt xontribsxpipinstall-U'xontrib-ergopack[prompt]'prompt_bar- The bar prompt for xonsh shell with customizable sections.prompt_starship- Starship cross-shell prompt in xonsh shell.All default xontribs.Dev xontribsxpipinstall-U'xontrib-ergopack[dev]'macro- Library of the useful macros for the xonsh shell.debug-tools- Debug tools for xonsh shell.hist_format- Format xonsh history to post it to Github or another page.readable-traceback- Make traceback readable and colorized.hunter- A flexible code tracing toolkit.How to use with xonsh.All default xontribs.All xontribsxpipinstall-U'xontrib-ergopack[onepath,prompt,dev]'UsageLoad default xontribs:xontribloadergopackLinksxonsh-cheatsheet- Cheat sheet for xonsh shell with copy-pastable examples. The best doc for the new users.xontrib-rc-awesome- Awesome snippets of code for xonshrc in xonsh shell.Ergopack is compatible withdotfiles pluginforxxh- bring your favorite shell wherever you go through the ssh.This package was created withxontrib cookiecutter template.Get more xontribs for xonsh on Github
Package: xontrib-fish-completer
Populate rich completions using fish and remove the default bash based completer in xonsh shell.If you like the idea click ⭐ on the repo andtweet.InstallationTo install use pip:xpipinstallxontrib-fish-completer# or: xpip install -U git+https://github.com/xonsh/xontrib-fish-completerUsagexontribloadfish_completerCreditsThis package was created withxontrib template.
Package: xontrib-free-cwd
To release the lock on the current directory whenever the prompt is shown in xonsh shell. Windows only xontrib.If you like the idea click ⭐ on the repo andtweet.InstallationTo install use pip:xpipinstallxontrib-free-cwd# or: xpip install -U git+https://github.com/xonsh/xontrib-free-cwdUsagexontribloadfree_cwdEnabling this will allow other programs or
Windows Explorer to delete or rename the current or parent
directories. Internally, it is accomplished by temporarily resetting
CWD to the root drive folder while waiting at the prompt.Known issuesThis only works with the prompt_toolkit backend and can cause issues
if any extensions are enabled that hook the prompt and relies onos.getcwd().CreditsThis package was created withxontrib template.
Package: xontrib-gitinfo
xontrib-gitinfoDisplays git information on entering a repository folder.
Usesonefetchif available.RequirementsPython 3.7+ (might work with older version as well)xonsh[optional]onefetchInstall$ pip install xontrib-gitinfo
$ xontrib load gitinfoLogoIf an image calledlogo.pngexists in the repository root then it is used byonefetch.
Package: xontrib-histcpy
xontrib-histcpyUseful aliases and shortcuts for extracting links and text from command
output history inxonsh.UsageIf you useptk(2)-prompts,histcpywill bind the follow shortcuts:Alt+u: Open one of the URLs that a previous command wrote to output in your web browserAlt+y: Copy one of the URLs to clipboardThe same functionality and more is available with the following command aliases (even when not using ptk):getout: Copy the output of one of the last few commands to clipboard (without re-running the command - uses history)cpyclip: Copy one of the last few URLs that a command wrote to stdout to clipboard (Alt+y keybinding)cpyclip: Open one of the last few URLs that a command wrote to stdout in your browser (Alt+u keybinding)InstallationJust do apip install xontrib-histcpyor you can clone the repo with pippip install git+https://github.com/con-f-use/xontrib-histcpyConfigurationTo automatically loadhistcpyon startup, putxontrib load histcpyin your.xonshrc.
Package: xontrib-hist-format
Format xonsh history to post it to Github or another page.The mission of xontrib-hist-format is to make commands repeatable, copy-pastable and save time to preparing.If you like the idea click ⭐ on the repo and stay tuned.Installationxpipinstallxontrib-hist-format# or: xpip install -U git+https://github.com/anki-code/xontrib-hist-formatUsagexontribloadhist_format
hist-format--help# Basic commandhist-md# Markdown format shortcuthist-txt# Text format shortcutArguments:usage: hist-format [-h] [-f FORMAT] [-c COMMANDS_COUNT] [-l]
                   [-H [OUTPUT_HEAD_COUNT]] [-T [OUTPUT_TAIL_COUNT]]
                   [-m] [--lines]

Format xonsh history to post it to Github or another page.

optional arguments:
  -h, --help            show this help message and exit
  -f FORMAT, --format FORMAT
                        Format: md, txt.
  -c COMMANDS_COUNT, --commands-count COMMANDS_COUNT
                        Count of commands
  -l, --commands-list   Show commands in distinct section.
  -H [OUTPUT_HEAD_COUNT], --output-head-count [OUTPUT_HEAD_COUNT]
                        Count of lines from output head to show.
  -T [OUTPUT_TAIL_COUNT], --output-tail-count [OUTPUT_TAIL_COUNT]
                        Count of lines from output tail to show.
  -m, --min             Make block minimized i.e. by adding <details> tag in Markdown.
  --lines               Add additional lines before and after.Note! Theclearcommand is used as marker of the beginning of commands list. If you run commands 1, 2, 3
then runclear, and run 4, 5, 6 and finally runhist-mdit will show 4, 5, 6 commands.
Feel free to open an issue with feedback on this approach.ExampleRun commands:echo123ls/|head-n3Run hist-format:hist-md-c2-l--lines# latest 2 commands + commands list + header and footer as lineAs result you will get the output that you can copy and paste to the Github comment or md-file:Output:echo123#123ls/|head-n3#boot#cdrom#dev# Prepared by xontrib-hist-formatCommands:echo123ls/|head-n3# Prepared by xontrib-hist-formatYou can disable the "Prepared by" message by settingXONTRIB_HIST_FORMAT_FOOTER = ''in your environment. If you like this xontrib, tell your friends!ClipboardYou can redirect the output to clipboard. Example forxclip:hist-md|xclipKnown issuesNot every command has output in the__xonsh__.history.Workaround in some cases is to use pipe intoheadi.e.cat file | head.Not working afterxonsh 0.10.0(4283)Workaround: CheckXONSH_CAPTURE_ALWAYSenvironment variable to bring the capturing of the output back.CreditsThis package is the part ofergopack- the pack of ergonomic xontribs.This package was created withxontrib cookiecutter template.
Package: xontrib-hist-navigator
xontrib-hist-navigatorFish-shell likeprevdandnextdforxonshwith keyboard shortcutsUsageinstall using pippipinstallxontrib-hist-navigatoror xpip (that is installed alongside xonsh)xpipinstallxontrib-hist-navigatoradd to list of xontribs loaded.xontribloadhist_navigatorOverviewit keeps track ofcdusage per sessionShortcutscommanddescriptionshortcutnextdmove to previous working directoryAlt + Left Arrowprevdmove to next working directory in the history (ifprevdis used)Alt + Right Arrowlistdlist cd historycd ..move to parent directoryAlt + Up ArrowReleasepoetryversion
poetrypublish
Package: xontrib-history-encrypt
History backend that encrypt the xonsh shell commands history fileto prevent leaking sensitive data from the commands history(keys, passwords, hosts, names).If you like the idea click ⭐ on the repo andtweet now.InstallationTo install use pip:xpipinstallxontrib-history-encrypt# or: xpip install -U git+https://github.com/anki-code/xontrib-history-encryptUsage: supported encryptionBase64 (default)Protection level: no protection.Base64 is not the real encrypter and implemented as fast way to encode history file and for education reasons.
It can save you from the massive scanning the file system for keywords (i.e. password, key)
as well as reading the history file by not experienced user. But it can be decoded in five minutes by the professional.# Add to xonsh RC file$XONSH_HISTORY_ENCRYPTOR='base64'xontribloadhistory_encryptFernetProtection level: high.The implementation ofFernet(AES CBC + HMAC) that was strongly
recommended onstackoverflow. On first start it generates a key that you
should save in secure place. Than you can use this key to decrypt the history.# Add to xonsh RC file$XONSH_HISTORY_ENCRYPTOR='fernet'xontribloadhistory_encryptDummyProtection level: super high.The best encryption of the data when there is no the data. The dummy encryptor stores command only in the memory during
the session without saving it on the disk. After the end of the session the commands will be lost.# Add to xonsh RC file$XONSH_HISTORY_ENCRYPTOR='dummy'xontribloadhistory_encryptCustomProtection level: all in your hands.To create custom encryptor you should implement three functions: key getter function, encryptor and decryptor.# Add to xonsh RC file$XONSH_HISTORY_ENCRYPTOR={'key':lambda:input('[xontrib-history-encrypt] Enter any key just for fun: '),'enc':lambdadata,key=None:data[::-1],# just flip the string'dec':lambdadata,key=None:data[::-1]# flip the string back}xontribloadhistory_encryptAfter debugging you can add your encryptor to thehistory_encryptdirectory of the xontrib by PR.What should I know?How to check the backend is workinghistoryinfo# backend: xontrib-history-encrypt# sessionid: 374eedc9-fc94-4d27-9ab7-ebd5a5c87d12# filename: /home/user/.local/share/xonsh/xonsh-history-encrypt.txt# commands: 1Some points about the backendAt start the backend read and decrypt all commands and this could take time. Basically we assume that you will use the xontrib on your servers and haven't so big history.The commands are stored in the memory and flush to the disk at the exit from the shell. If the shell has crash there is no flushing to the disk and commands will be lost. Usehistory flushcommand if you plan to run something experimental.The backend has minimal history management support in comparing with json or sqlite backends and you can find the lack of features.If you want to improve something from the list PRs are welcome!CreditsThis package is the part ofergopack- the pack of ergonomic xontribs.This package was created withxontrib cookiecutter template.
Package: xontrib-homebrew
AddHomebrew's shell environment toxonshshell onmacOS/Linux(alternative toshellenv).If you like the idea click ⭐ on the repo andtweet. This might also accelerate addingxonsh support to Homebrew.IntroductionHomebrewhas ashellenvcommand to addits environmentto your shell: it adds a few
environment variables (HOMEBREW_PREFIX/CELLAR/REPOSITORY) and updates a few paths (MAN/INFO/PATH).This xontrib automatically translates the defaultbashexport statements ofshellenvintoxonsh.InstallationTo install use pip:xpipinstallxontrib-homebrew# or: xpip install -U git+https://github.com/eugenesvk/xontrib-homebrewThis xontrib will get loaded automatically for interactive sessions; to stop this, set$XONTRIBS_AUTOLOAD_DISABLED = {"homebrew", }UsageAdd this to your xonsh run control file (~/.xonshrcor~/.config/rc.xsh):xontribloadhomebrewSet custom Homebrew installation path via$XONTRIB_HOMEBREW_PATHBREWto/full/path/to/bin/brewif it's not installed at these default paths (which always take precedence):macOSLinux/usr/local/bin/brew/home/linuxbrew/.linuxbrew/bin/brew/opt/homebrew/bin/brew~/.linuxbrew/bin/brewSet the level of verbosity via$XONTRIB_HOMEBREW_LOGLEVELto0–3(default1):0 print nothing (fail silently)1print errors (e.g. can't findbrewat default locations)2 print warnings (e.g issues when parsingshellenv)3 print more verbose messagesKnown issuesXontrib autoload currently can't be disabled due to axonsh bug, so if you need precise control over when your environment variables are set (e.g., whether/path/to/homebrew/binis at the top ofPATH), try installing from adeautobranch:xpip install -U git+https://github.com/eugenesvk/xontrib-homebrew@deautoLikely due to the same bug your$XONTRIB_HOMEBREW_PATHBREWand$XONTRIB_HOMEBREW_LOGLEVELenv vars might be ignored in the autoloaded version, so install the@deautoversion mentioned aboveCreditsThis package was created withxontrib cookiecutter template.
Package: xontrib-init-ssh-agent
Inits ssh-agentIf you like the idea click ⭐ on the repo andtweet.InstallationTo install use pip:xpipinstallxontrib-init-ssh-agent# or: xpip install -U git+https://github.com/theRealBithive/xontrib-init-ssh-agentUsagexontribloadinit_ssh_agentKnown issuesWorks fine on my PC(tm)CreditsThis package was created withxontrib cookiecutter template.
Package: xontrib-iterm2
iTerm2 Shell IntegrationiTerm2Shell integrationfor Xonsh shell.InstallationTo install use pip:xpipinstallxontrib-iterm2# or: xpip install -U git+https://github.com/jnoortheen/xontrib-iterm2Usage# this modifies the $PROMPT function. So load it after setting $PROMPT if you have a custom valuexontribloaditerm2