Private archive copy · Unofficial site · Content copyright belongs to Runoob Tutorial and the original authors · View Original

Linux jed command

Linux jed command

Linux Command Reference Linux Command Reference

The Linux jed command is used to edit text files.

Jed is a program written in Slang, suitable for editing program source code.

Syntax

jed [-2n][-batch][-f<函数>][-g<行数>][-i<文件>][-I<文件>][-s<字符串>][文件]

Parameters:

Example

jed is mainly used to edit program source code; when editing source code, it displays the program's syntax with color highlighting. For example, to edit a C source code file with jed, you can use the following command:



jed main.c       #用jed编辑器打开main.c 文件 

The output is as follows:



F10 key ==> File Edit Mode Search Buffers Windows System Help #编辑器菜单  

/*-*- linux-c-*-*/ #Edit Area

#include  

#include  

#include  

static struct list_head *  

net_ctl_header_lookup(struct ctl_table_root *root, struct nsproxy *namespaces)  

{  

return &namespaces->net_ns->sysctl_table_headers;  

}  

static struct ctl_table_root net_sysctl_root = {  

.lookup = net_ctl_header_lookup,  

};  

static int sysctl_net_init(struct net *net)  

{  

INIT_LIST_HEAD(&net->sysctl_table_headers);  

return 0;  

}  

-----+(Jed 0.99.18U) Emacs: main.c (C) All 6:06pm-----------------------------  

#jed version number, current is simulating emacs editor, filename of the opened file, current time

loading /usr/share/jed/lib/modeinfo.slc 

Linux Command Reference Linux Command Reference