# rc **Repository Path**: wangyubin/rc ## Basic Information - **Project Name**: rc - **Description**: command line tool for remote server - **Primary Language**: Go - **License**: MIT - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2017-03-13 - **Last Updated**: 2024-06-17 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README #+STARTUP: showall #+OPTIONS: toc:t #+OPTIONS: num:t #+OPTIONS: html-postamble:nil #+LANGUAGE: zh-CN #+OPTIONS: ^:{} #+DATE: 2017 月 02 月 12 日 #+AUTHOR: 汪玉斌 #+TITLE: rc (remote command line) * 概述 通过 SSH 协议 方便快速的登录远程机器,执行远程命令,远程文件的上传下载等。 对传统的 ssh 命令进行封装,使之能够更方便的使用。 1. 登录远程机器 2. 批量执行执行远程命令 3. 上传文件到远程机器 4. 从远程机器下载文件 * 安装 ** 从源码安装 本工程采用 dep(https://github.com/golang/dep) 来管理 #+BEGIN_SRC sh $ git clone https://git.oschina.net/wangyubin/rc.git $ cd rc $ dep ensure $ go install $ ln -s $GOPATH/bin/rc /your/PATH/rc #+END_SRC * 使用 ** 交互模式 直接 rc -i 命令进入命令行自己的环境。 #+BEGIN_SRC sh $ rc -i » help commands: list login exec get put set help exit q » exit $ #+END_SRC ** 命令模式 执行完成就退出,可以用来和其他命令结合使用 #+BEGIN_SRC sh $ rc help NAME: rc - A new cli application USAGE: rc [global options] command [command options] [arguments...] VERSION: v2017.09.17 build: develop build, not release COMMANDS: list list host info login login host get get file/directory from remote host put put file/directory to remote host set config command exec exec commands for remote host help, h Shows a list of commands or help for one command GLOBAL OPTIONS: -i is interactive --help, -h show help --version, -v print the version #+END_SRC 各个命令的使用方式参考 [[file:doc/commands.org][commands]]