linux命令排行榜

Kaggle 命令行工具查看 AI 最新竞赛和下载数据集 1. 安装 1.1 普通安装 kaggle 命令行工具安装在系统搜索路径下。 pip install kaggle 1.2 Mac/Linux 推荐安装 kaggle 命令行工具安装在当前登陆用户目录 ~/.local/bin 下。 pip install --user kaggle 安装完成功后,确保 ~/.local/bin 添加到 PATH 环境变量中。 echo $PATH 如果未看... 阅读详情

1. sudo!!

Run the last command as root.
Useful when you forget to use sudo for a command. "!!" grabs the last run command.

一些变种:`!!`

Use result of the last command
\$ which python
/usr/bin/python
\$ ll `!!`
lrwxrwxrwx 1 root root 9 2010-11-08 22:01 /usr/bin/python -> python2.6


2. python -m SimpleHTTPServer

Serve current directory tree at http://$HOSTNAME:8000/

在python3中需要使用:python -m http.server


3. cd -

change to the previous working directory


4 ^foo^bar

Runs previous command but replacing
Really useful for when you have a typo in a previous command. Also, arguments default to empty so if you accidentally run:
echo "no typozs"
you can correct it with
^z


5. mtr google.com

mtr, better than traceroute and ping combined
mtr combines the functionality of the traceroute and ping programs in a single network diagnostic tool.
As mtr starts, it investigates the network connection between the host mtr runs on and HOSTNAME. by sending packets with purposly low TTLs. It continues to send packets with low TTL, noting the response time of the intervening routers. This allows mtr to print the response percentage and response times of the internet route to HOSTNAME. A sudden increase in packetloss or response time is often an indication of a bad (or simply over‐loaded) link.


6. ctrl+x+e

Rapidly invoke an editor to write a long, complex, or tricky command
Next time you are using your shell, try typing ctrl-x e (that is holding control key press x and then e). The shell will take what you've written on the command line thus far and paste it into the editor specified by $EDITOR. Then you can edit at leisure using all the powerful macros and commands of vi, emacs, nano, or whatever.


7. <space>comand

Execute a command without saving it in the history
Prepending one or more spaces to your command won't be saved in history.
Useful for pr0n or passwords on the commandline.
Tested on BASH.


8. > file.txt

Empty a file
For when you want to flush all content from a file without removing it (hat-tip to Marc Kilgus).


9. reset

Salvage a borked terminal
If you bork your terminal by sending binary data to STDOUT or similar, you can get your terminal back using this command rather than killing and restarting the session. Note that you often won't be able to see the characters as you type them.


10. <Esc> + .

Place the argument of the most recent command on the shell
When typing out long arguments, such as:
cp file.txt /var/www/wp-content/uploads/2009/03/
You can put that argument on your command line by holding down the ALT key and pressing the period '.' or by pressing <ESC> then the period '.'. For example:
cd 'ALT+.'
would put '/var/www/wp-content/uploads/2009/03/ as my argument. Keeping pressing 'ALT+.' to cycle through arguments of your commands starting from most recent to oldest. This can save a ton of typing.


11. mount | column -t

currently mounted filesystems in nice layout
Particularly useful if you're mounting different drives, using the following command will allow you to see all the filesystems currently mounted on your computer and their respective specs with the added benefit of nice formatting.


12 echo "ls -l" | at midnight

Execute a command at a given time
This is an alternative to cron which allows a one-off task to be scheduled for a certain time.

其他一些用法:

mrttlemonde, your command is not exactly right with the quotes, i.e. it should be something like:
echo "ls -l >/dev/pts/3"  | at 23:59
or we could also direct to a file:
echo "ls -lah >/foo/bar/ls.txt"  | at 07:00


13 netstat -tlnp

Lists all listening ports together with the PID of the associated process
The PID will only be printed if you're holding a root equivalent ID.


14 !!:gs/foo/bar

Runs previous command replacing foo by bar every time that foo appears
Very useful for rerunning a long command changing some arguments globally.
As opposed to ^foo^bar, which only replaces the first occurrence of foo, this one changes every occurrence.


15. ssh user@host cat /path/to/remotefile | diff /path/to/localfile -

Compare a remote file with a local file
Useful for checking if there are differences between local and remote files.


16  wget --random-wait -r -p -e robots=off -U mozilla http://example.com

Download an entire website

-r 表示递归下载

-l 最大递归深度(0表示无限制,最大下载,默认是5)
-p parameter tells wget to include all files, including images.
-e robots=off you don't want wget to obey by the robots.txt file
-U mozilla as your browsers identity.
--random-wait to let wget chose a random number of seconds to wait, avoid get into black list.
Other Useful wget Parameters:
--limit-rate=20k limits the rate at which it downloads files.
-b continues wget after logging out.
-o $HOME/wget_log.txt logs the output

-k  --convert-links
After the download is complete, convert the links in the document to make them suitable for local viewing. This affects not only the visible hyperlinks, but any part of the document that links to external content,
such as embedded images, links to style sheets, hyperlinks to non-HTML content, etc.

-p is not necessary if you're using -r
-K will keep copies of original files before modifying links with -k
-N for timestamps: useful for refreshing a mirror, only downloading new stuff


17. ctrl + l

clean the terminal screen


http://www.commandlinefu.com/commands/browse/sort-by-votes/25


Linux-Xshell-Redis Redis 是一个开源的 key-value 存储系统。·和 Memcached 类似,它支持存储的 value 类型相对更多,包括 string(字符串)、list(链表)、set(集合)、zset(sorted set --有序集合)和 hash(哈希类型)。·这些数据类型都支持 push/pop、add/remove 及取交集并集和差集及更丰富的操作,而且这些操作都是原子性的。·在此基础上,Redis 支持各种不同方式的排序。 阅读详情

相关推荐

洛谷 P5736 【深基7.例2】质数筛

题目描述 输入 n(n\le100)n(n≤100) 个不大于 100000 的整数。要求全部储存在数组中,去除掉不是质数的数字,依次输出剩余的质数。 输入格式 无 输出格式 无 输入输出样例 输入 #1 复制 5 3 4 5 6 7 输出 #1 复制 3 5 7 板子题,使用一下线性筛 #include <iostream> #include <cstdio> #include <cstring> #include <algorithm> using n

qq_37978559的博客 1119

Linux 中使用频率最高的命令 —— ls

如果有一个 Linux 命令使用频度排行榜的话,「ls」肯定榜上有名,而且说不定还是第一名。ls 是目录处理命令,是英文单词 list 的缩写,它的功能是显示某一目录下的文件或子目录。 ls 命令的使用格式是:ls [选项] [目录名]。中括号代表可选。 1. 小试牛刀 ls 最简单的用法就是直接在某一目录下输入 ls,然后回车,会显示当前目录下的所有文件和子目录(不包括隐藏文件)。如下图, 如...

supermouse的博客 843

统信UOS系统盘扩容保姆级教程:用GParten-分区编辑器5分钟搞定

本文提供统信UOS系统盘扩容的详细图形化教程。针对系统盘空间不足问题,重点介绍如何使用系统自带的GParten-分区编辑器,在5-10分钟内安全、直观地完成扩容操作,无需记忆复杂命令,适合所有用户快速解决存储空间告急的困扰。

e3f4g5的博客 647

Linux学习笔记:常用100条命令(一)

linux常用命令 1、关机 shutdown -h now 立刻关机 poweroff shutdown -r now 立刻重启 reboot logout 注销 2、进入图形界面 startx 3、vi编辑器 [vi] [path]/[file]; [i]进入编辑模式; [esc]进入命令模式; [:wq]保存并退出;[:q!]退...

weixin_34032621的博客 1952

Vim 入门到够用:Linux 文本编辑器的三种模式、常用操作与实战技巧

i 进入编辑模式Esc 退出编辑模式回到命令模式: 从命令模式进入底行模式编辑,不一定非得“打开就直接打字”。一旦你接受了“模式”这件事,后面很多操作都会顺起来。学 Vim,不要追求一次学全,先把“命令模式—编辑模式—底行模式”这条主线练熟。只要这条主线通了,后面的复制、删除、搜索、替换,都是顺手补上去的能力。

Web安全工具库 804

海光(hygon)CPU ESXI vSphere 紫屏问题修复记录

海光服务器ESXI 紫屏问题修复

edison202302的博客 3564

史上最全的Linux常用命令汇总(超全面!超详细!)收藏这一篇就够了!

这绝对是整理的最全面最详细最认真最适合用来当笔记的Linux终端命令汇总的文章了

万里羊的博客 105万+

PWM与光耦的完美联姻:低成本4-20mA转换方案揭秘

本文揭秘了PWM与光耦结合的低成本4-20mA转换方案,适用于工业自动化领域。通过PWM信号控制输出电流,光耦实现电气隔离,该方案成本低廉、电路简单且隔离可靠。文章详细介绍了两种经典电路实现方案,包括四光耦线性模式方案和PWM控制LM317方案,并提供了实战技巧与优化策略,帮助中小企业和电子DIY爱好者构建经济高效的4-20mA转换系统。

weixin_29229055的博客 539

Mozilla研究—图片显示

Mozilla研究—图片显示 转载时请注明出处和作者联系方式:http://blog.youkuaiyun.com/absurd作者联系方式:李先静更新时间:2007-3-25 mozilla是一个以浏览器为中心的软件平台,它在我们平台中占有重要地位。我们用它来实现WEB浏览器、WAP浏览器、邮件系统、电子书和帮助阅读器等应用程序。为此,我最近花了不少时间去阅读mozilla的代码和文

国产开源 GUI 引擎 AWTK 3975

Flutter蓝牙开发实战:flutter_blue_plus核心功能与实现原理剖析

本文深入剖析了Flutter蓝牙开发插件flutter_blue_plus的核心功能与实现原理。文章从源码解析入手,详细讲解了蓝牙状态管理、设备扫描、GATT连接、服务发现以及数据读写等关键流程的实现机制,并分享了实战中的性能调优与常见问题解决方案,帮助开发者高效构建跨平台蓝牙应用。

weixin_29014237的博客 446

爬取国家统计局最近10年年度数据

一、编码流程 1.目标网址:https://data.stats.gov.cn/easyquery.htm?cn=C01 2.编码思路: (1) 解析左侧指标树,实现4级标签定位 (难点:层层嵌套,下一级指标的xpath路径以上一级指标为基础;不是所有二级指标都含有三和四级指标,需要进行判断) (2) 使用selenium webdriver 点选指标,加载出右侧表格数据 (难点:当指标无法在全局页面显示时,需向下拖动滚动条) (3) 解析右侧数据,实现数据存储 3.使用模块: (1) selenium:解

weixin_39645690的博客 4563

linux ps 按内存排行榜,linux ps命令查看最消耗CPU、内存的进程

1.CPU占用最多的前10个进程:ps auxw|head -1;ps auxw|sort -rn -k3|head -102.内存消耗最多的前10个进程ps auxw|head -1;ps auxw|sort -rn -k4|head -103.虚拟内存使用最多的前10个进程ps auxw|head -1;ps auxw|sort -rn -k5|head -104.也可以试试ps auxw -...

weixin_42346693的博客 598

如何从RHEL 8升级到RHEL 9

Red Hat 于 2022 年 5 月 17 日宣布全面推出 RHEL 9。这是 RHEL(Red Hat Enterprise Linux)的最新版本,它具有许多功能和增强功能。

u012748257的博客 1022

2013年5月编程语言排行榜:UNIX下的Bash

2013年5月9日,Tiobe公司发布新一期编程语言排行榜。新一期榜单前10位没有太多的变化,只是Objective-C与C++,Ruby与JavsScript在互相交换位置罢了。今天我们要关注的是排在TOP 20后半部的一门语言——Bash。 大家先请看本期TOP20榜单 从2013年4月的编程语言排行榜我们惊异的发现Bash这门UNIX下的壳语言,竟然有了飞速的上升。从第34位最...

weixin_30267691的博客 88

精雕软件(JDpaint) 5.5 绿色版

精雕软件(JDpaint) 5.5 绿色版精雕软件(JDpaint) 5.5 绿色版精雕软件(JDpaint) 5.5 绿色版

VC中sqlite的使用

在VC中对sqlite的使用,实现数据库大批数据的快速插入,读取数据库中的数据在ListCtrl中显示

shell 之统计ES 索引的error日志数量

1.需求:需要大屏展示每个应用的错误日志,以供开发其错误排行榜… 2.思路:Linux命令调用es的api 进行查询。 3.脚本如下: #!/bin/bash function webmanager { count=`curl -sH "Content-Type: application/json" -XGET 'http://192.168.1.155:9200/webmanager*/_s...

品尝人生百态 931

Statistics and Machine Learning Toolbox

Statistics and Machine Learning Toolbox(带书签),MATLAB统计学习工具

Redis简介及安装

Redis安装全指导

m0_63324465的博客 1038

TMS_WebGMaps_1.9.8.0_Full_Source

TMS_WebGMaps_1.9.8.0_Full_Source 全源码 delphi cbuilder

C++学习记录:C++连接Redis数据库

C++学习记录:C++连接Redis数据库   之前学习了Redis数据库相关的内容,但是并没有在编写C++代码中用到Redis相关内容。   本篇笔记记录了个人在 Linux 环境下使用 C++ 连接 Redis 数据库的过程。实现了一个简单的排行榜功能。   由于现在的主流是使用 java 连接 redis,所以在网上查询 C语言 的API消耗了一部分时间,在本篇笔记中,我将记录相关数据结构和API的使用方法。 目录C++学习记录:C++连接Redis数据库一、基础准备1. 找到`hiredis.h`

这里是河边 1704

微软一顿操作猛如虎,PowerShell排名直线上升

\n近日,TIOBE发布了2019年3月编程语言排行榜,PowerShell首次进入到了榜单的Top 50中,排在第45位。\n\nPowerShell 是运行在 Windows 操作系统上实现对系统以及应用程序进行管理自动化的命令行脚本环境。\n\n(PowerShell排在了TIOBE榜单中的第45位)\nPowerShell是用C#实现的,由于早先 .NET不支持Linux,所以 .NET和...

啊啊啊啊2 348

redis相关知识

redis简介 redis是一个基于key_value的存储系统,支持的数据类型很丰富:string、list、set、hash、zset redis是用内存来存储数据,读写效率远远高于数据库;存储在 redis中的数据都是持久化的,断电或者重启后不用担心数据会丢失,redis的存储可以分为三部分:内存存储、磁盘存储、log文件,重启后,redis可以从磁盘重新把数据加载到内存中 redis支持...

祖哥的博客 271

Redis的基本使用

一个分布式Web服务将用户的Session信息(例如用户登录信息)保存在各自服务器中,这样会造成一个问题,出于负载均衡的考虑,分布式服务会将用户的访问均衡到不同服务器上,用户刷新一次访问可能会发现需要重新登录,这个问题是用户无法容忍的。哈希类型的操作命令中,hdel,hmget,hmset的时间复杂度和命令所带的field的个数相关O(k),hkeys,hgetall,hvals和存储的field的总数相关,O(N)。列表是一种比较灵活的数据结构,它可以充当栈和队列的角色,在实际开发上有很多应用场景。

weixin_42619556的博客 191

Redis入门学习

客户端调用都经历发送命令、执行命令、返回结果的三个过程,redis使用单线程处理命令,所以一条命令从客户端到达服务端不会被立刻执行,所有的命令都会进入一个队列中逐个被执行即上面3个客户端命令执行的顺序不确定,但是不会存在两条命令同时执行,所以不会存在并发的问题,所以incr的结果都是2不会产生并发的问题。8.列表:存储多个有序的字符串,列表中每个字符串称为元素,一个列表最多可有2^32-1个元素,在redis中,可以对列表两端插入和弹出,还可以获取指定范围的元素列表,获取指定索引下标的元素。

2201_75920541的博客 1235

python 桌面歌词_GitHub - Python-Z/musicbox: 网易云音乐命令行版本

NetEase-MusicBox感谢为 MusicBox 的开发付出过努力的每一个人!高品质网易云音乐命令行版本,简洁优雅,丝般顺滑,基于Python编写。功能特性320kbps的高品质音乐歌曲,艺术家,专辑检索网易22个歌曲排行榜网易新碟推荐网易精选歌单网易主播电台私人歌单,每日推荐随心打碟本地收藏,随时加❤播放进度及播放模式显示现在播放及桌面歌词显示歌曲评论显示一键进入歌曲专辑定时退出Vime...

weixin_35709851的博客 521
上一篇: linux shell 正则表达式(BREs,EREs,PREs)差异比较
下一篇: TCP协议三次握手过程分析
overstack
博客等级 码龄14年 115粉丝 55原创
评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

个

红包个数最小为10个

元

红包金额最低5元

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

抵扣说明:

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

余额充值