env2(Converts environment variables to various script languages)

关于这个的博客很少

Do you prefer running bash while the rest of the team runs tcsh? Or
perhaps you learned csh and the system administrators only know ksh.
What happens when they (or you) supply an initialization script to
source? If any of these situations sounds familiar, then this may be the
script for you. 
env2 takes shell scripts of one flavor in and spits out scripts
effectively equivalent in another dialect. We say "effectively
equivalent" because it does not translate syntax such as if/else
statements. Instead, the original (source) script is evaluated to
determine what environment variables it modifies, and the effective
values of those variables are simply expressed in the syntax of the
destination script's dialect. Typically, this is all you really need for
scripts that modify the environment.

NOTE: If you need to the conditionals and for-loops to be used for
different situations (e.g. different host architectures), then simply
use this script repeatedly as needed.

Future extensions may include aliases or <functions>. Supported
languages currently include: bash, csh, ksh, modulecmd, perl, plist, sh, tclsh, tcsh, vim, yaml, and zsh.

NOTE: The file version is identified by an internally computed SHA1 hash
similar to the way git does versioning. If you get a warning message
about inconsistent hash, it means that somebody modified the file
without updating the $SHA variable.

http://blog.chonor.cn/index.php/environment-module/
https://software.intel.com/en-us/articles/using-environment-modules-with-the-intel-development-tools

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值