ssh框架配置文件流程

by Marcus Wood

由马库斯·伍德(Marcus Wood)

通过配置文件和安排增强您的工作流程 (Supercharge your workflow with profiles and arrangements)

If you’ve ever had to manage multiple projects, keeping up with the command line can be cumbersome. Here are a couple of hot tips on how juggle multiple projects that will save you a ton of time.

如果您曾经必须管理多个项目,那么跟上命令行可能会很麻烦。 以下是一些热门技巧,说明如何处理多个项目可以为您节省大量时间。

If you’re using the regular Mac Terminal, I highly recommend switching over to iTerm2 (it’s just better). More on why in a bit.

如果您使用的是普通Mac终端,我强烈建议您切换到iTerm2 (这样更好)。 进一步说明原因。

SSH别名 (SSH Aliases)

Sometimes, you need to SSH into a server somewhere. Sometimes you have twenty different servers you’d like to SSH into. Remembering where they live and what they’re called can be a pain.

有时,您需要在某处通过SSH进入服务器。 有时您想使用SSH连接到二十台不同的服务器。 记住他们的住处和名字可能会很痛苦。

To save time, create aliases for each server in under a minute. Here’s how:

为了节省时间,请在一分钟内为每个服务器创建别名。 这是如何做:

// Open a terminal windownano ~/.ssh/config
// Fill in the following to create an aliasHost <Name you want to assign>  Hostname <Where you want to ssh>  User <User you want to login as>  IdentityFile ~/.ssh/<pem file you want to use>
//Exit and save the filectrl + xyenter
// Now instead of doing this to connectssh -i "<pem file>" <user>@<hostname>
// You can do thisssh name-you-assigned

iTerm2配置文件和安排 (iTerm2 Profiles and Arrangements)

Profiles are great and have changed my daily workflow. Sometimes your terminal looks like this:

个人资料很棒,并且改变了我的日常工作流程。 有时您的终端看起来像这样:

The problem is, you don’t know which window you want to click. You also don’t want to close out windows, because then you’ll have to open a new window, navigate back to the correct directory, and remember the copy pasta to make it go.

问题是,您不知道要单击哪个窗口。 您也不想关闭窗口,因为那样一来,您就必须打开一个新窗口,导航回到正确的目录,并记住复制意大利面的方法。

With profiles and window arrangements, you don’t have to worry about any of that.

使用配置文件和窗口排列,您不必担心任何这些。

There’s a quick video walk through below if you get lost on any of these steps.

如果您在以下任何一个步骤中迷失了方向,下面都会快速浏览视频。

A profile enables you to open a new command line window in a certain directory and run commands automatically. Let’s make one!

配置文件使您可以在特定目录中打开新的命令行窗口并自动运行命令。 让我们做一个!

First, close all open command line windows in iTerm, and start with a new command line window. Next, you’ll want to navigate to “Profiles” in the Menubar and click “Open Profiles…”

首先,关闭iTerm中所有打开的命令行窗口,然后从一个新的命令行窗口开始。 接下来,您将要导航至菜单栏中的“配置文件”,然后单击“打开配置文件...”

Now click “Edit Profiles…” which should bring you here:

现在,单击“编辑配置文件...”,它将带您到这里:

Click the + sign at the bottom left side to create a new profile. Make sure to give it a name and update the directory to be the the root of your project.

单击左下角的+号以创建新的配置文件。 确保为其命名,并将目录更新为项目的根目录。

If you want to run commands when this profile is opened, add them in the “Send text at start:” field. One of my favorite recipes is to open up the project in my code editor and build it for development.

如果要在打开此配置文件时运行命令,请将其添加到“在开始时发送文本:”字段中。 我最喜欢的食谱之一是在我的代码编辑器中打开该项目,并为开发而构建。

// Separate commands with a semi-colonatom .; preact watch

Exiting out of the window will save your changes (there’s no button to do this).

退出窗口将保存您的更改(没有按钮可以执行此操作)。

Next up, we need to test it out. Click on “Profiles” in the Menubar and select the profile you made to make sure it works. If you run into any issues, make sure your directory path is correct and that your commands are separated correctly.

接下来,我们需要对其进行测试。 点击菜单栏中的“个人资料”,然后选择您创建的个人资料以确保其有效。 如果遇到任何问题,请确保目录路径正确并且命令正确分隔。

Once all that works, it’s time to create a window arrangement to easily launch the newly made profile. Make sure you don’t have any lingering terminal windows open when you do this step or they’ll be saved as part of the arrangement.

一旦一切正常,是时候创建一个窗口布置以轻松启动新创建的配置文件了。 执行此步骤时,请确保没有打开任何残留的终端窗口,否则它们将被保存为安排的一部分。

In a new terminal window, click on the profile you just made. If it opens in a new tab make sure to close the “Default” tab. Navigate to the “Window” tab in the Menubar and select “Save Window Arrangement.” Give it a name and click ok. You’re good to go!

在新的终端窗口中,单击您刚创建的配置文件。 如果在新标签页中打开,请确保关闭“默认”标签。 导航至菜单栏中的“窗口”标签,然后选择“保存窗口排列”。 给它起一个名字,然后单击“确定”。 你很好!

Now all of your terminal windows will be named. They’ll automatically remember the commands you need to start each project.

现在,您所有的终端窗口都将被命名。 他们会自动记住启动每个项目所需的命令。

包装东西 (Wrapping Things Up)

After the first time you do so, you’ll be able to create new profiles and arrangements with ease. You can also combine multiple profiles into an arrangement, use tabbed terminal windows to run multiple parts of a project, and much more.

第一次这样做后,您将可以轻松创建新的配置文件和安排。 您还可以将多个配置文件组合到一个排列中,使用带选项卡的终端窗口来运行项目的多个部分,等等。

Was this helpful? If so, please clap on the story and let me know what else you’d like to know about my development process or tips on mastering the command line.

这个有帮助吗? 如果是这样,请拍一下故事,让我知道您还想了解我的开发过程或掌握命令行的技巧。

My name is Marcus Wood. I am the founder of Caldera, a full-service digital agency focusing on web applications.

我叫马库斯·伍德。 我是Caldera(一家专注于Web应用程序的全方位服务的数字代理)的创始人。

翻译自: https://www.freecodecamp.org/news/supercharge-your-workflow-with-profiles-and-arrangements-99099da313b5/

ssh框架配置文件流程

ssh框架配置文件流程_通过配置文件和安排增强您的工作流程相关推荐

  1. 开发工作流程_您应该了解的9个开发工作流程升级

    开发工作流程 Every once in a while I run into a tool or plugin so useful I can't not add it to my arsenal. ...

  2. java ssh框架面试题_五道关于SSH框架的面试题

    1.写出你熟悉的开源框架以及各自的作用(项目中为什么使用SSH) 答:框架:hibernate,spring,struts1/struts2. Hibernate主要用于数据持久化:封装了JDBC操作 ...

  3. ssh框架实现数据库_自顶向下介绍SSH及其如何实现安全的数据共享

    ssh框架实现数据库 by Sam Ollason 通过萨姆·奥拉森(Sam Ollason) This article will take a high-level and top-down app ...

  4. java ssh框架开源项目_几个比较棒的开源ssh框架

    集结最新主流时尚开源技术的面向企业级Web应用的基础开发框架,提供一个J2EE相关主流开源技术架构整合及一些企业应用基础通用功能和组件的设计实现的最佳实践和原型参考. http://www.jeasy ...

  5. github上 开源项目_在GitHub上组织开源项目的工作流程的3个技巧

    github上 开源项目 管理开源项目是一项艰巨的工作,挑战随着项目的发展而增长. 最终,一个项目可能需要满足不同的需求并跨越多个存储库. 这些问题不是技术问题,但对于解决扩展技术项目很重要. 诸如敏 ...

  6. 接收请求处理流程_从Tomcat入口了解Spring MVC的请求处理流程(2)问题答疑

    在上一篇 从Tomcat入口了解Spring MVC的请求处理流程 中主要介绍了spring mvc如何使用以及spring的DispatcherServlet加载细节以及URL映射配置,但是还是遗留 ...

  7. 安卓 camera 调用流程_[Camera]Camera1 open、preview、take picture流程分析(3)

    本文章转载自sheldon_blogs的博客,具体网址如下:https://www.cnblogs.com/blogs-of-lxl/p/5152578.html 本文章仅供学习研究使用,如须转载请附 ...

  8. ebay注册流程_跨境电商平台eBay企业入驻流程

    整个流程一共包括8个部分 了解企业入驻通道 企业入驻通道将帮助现有eBay大中华卖家申请并获得高刊登额度的新账户,以满足卖家在品类拓展 以及站点拓展的需求. 准备材料 1.营业执照 2.法人代表身份证 ...

  9. 小程序发布上线流程_微信小程序提交审核并发布详细流程

    微信小程序提交审核并发布详细流程 审核在1小时到N天不等 官方7天,一般3天内 提交审核?如何发布?审核过程中注意事项? 服务器: 域名只支持 https (request.uploadFile.do ...

最新文章

  1. 深入理解javascript函数系列第二篇——函数参数
  2. selenium search
  3. 对于redis底层框架的理解(一)
  4. SharePoint2007安装图文详解二:安装AD(活动目录)及DNS
  5. oracle数据如何采集,网页采集的数据如何导出到Oracle数据库 - 八爪鱼采集器
  6. LC振荡器的工作原理
  7. ios15验证失败因为你不在连接互联网
  8. 多图片上传插件webuploader
  9. 什么时候要抛出异常? !
  10. docker搭建c++开发环境
  11. 比比看手机安全软件谁更强?【系统收藏】
  12. Bit Vector算法
  13. DSP营销百亿点击量背后原理竟然是这样
  14. 贝叶斯决策理论(三):最小最大决策、序贯分类
  15. pure virtual method called terminate called without an active exception Abor
  16. c语言:购房从银行贷了一笔款d,准备每月还款额为p,月利率为r,计算多少月能还清。
  17. python将十位数变成0_Python:战略性地通过0-9的十位数字
  18. n阶台阶 java_上N阶楼梯,一次走1个台阶或者2个台阶,共有多少种走法?
  19. 计算机控制及网络技术pdf,计算机控制系统pdf
  20. osx android png图片自动 边,Mac/OSX上超好用的图片浏览工具iSee

热门文章

  1. 华科10年保送生计算机考研复试机试
  2. css 浮动效果 0302
  3. mysql-查询例题大全
  4. percona-toolkit(pt工具)使用总结
  5. linux基础知识3
  6. 调查显示超四成人“讨厌”大数据
  7. ZABBIX API简介及使用
  8. Nagios 安装教程
  9. android模拟按键问题总结[使用IWindowManager.injectKeyEvent方法](转)
  10. Web容器和Servlet生命周期