EmEditor Command Line Options

本文详细介绍了如何使用EmEditor的命令行选项进行文件打开、创建、打印、比较、编码转换等常见操作,提供了丰富的命令行参数说明及示例,帮助用户高效完成文件管理任务。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

Using Command Line Options

http://www.emeditor.com/help/howto/file/file_commandline.htm

 

Command line options can be specified in the Run dialog box on the Start menu or a  Command Prompt window.

Syntax

Open a file or files

"File1" "File2" "File3" ... [/r] [/fh] [/nr] [/sp] [/l LineNumber] [/cl ColumnNumber] [/cp encoding] [/c "Config"] [/mf "MacroPath"]

Create a new file

[/cd] [/sp] [/c "Config"] [/mf "MacroPath"]

Create a new file and paste

[/i] [/cd] [/sp] [/c "Config"] [/mf "MacroPath"]

Create a new file and paste with quote

[/iq] [/cd] [/sp] [/c "Config"] [/mf "MacroPath"]

Create a new file and paste with quote and returns

[/iqr] [/cd] [/sp] [/c "Config"] [/mf "MacroPath"]

Display the Tray Icon

/ti

Print a file

"File" /p [/nr] [/sp] [/cp encoding]

Compare two files

/cmp "File1" "File2"

Convert a file encoding

"SrcFile" [/nr] [/sp] [/cp EncodingToOpen] [/c "Config"] /cps EncodingToSave /ss+ /sa "DestFile"

To save without the Unicode signature (BOM), use /ss- instead of /ss+.

Display Find in Files dialog box

/fd

Display Replace in Files dialog box

/rd

Find in files

/fc "FindWhat" [/fr] [/fw] [/x] [/fn] [/fu "FilesToIgnore"] [/cp encoding] "path"

This command is called internally when the Find button is selected in the Find in Files dialog box. To search without matching case, use /fi instead of /fc.

Replace in files

/fc "FindWhat" [/fr] [/fw] [/x] [/ko] [/fu "FilesToIgnore"] [/cp encoding] "path" /rw "RepalceWith" [/bk "BackupFolder"]

This command is called internally when the Replace All button is selected in the Replace in Files dialog box. To search without matching case, use /fi instead of /fc. /ko and /bk cannot be specified simultaneously.

Open a file and replace

"File" /rc "FindWhat" [/fw] [/x] [/cp encoding] /rw "RepalceWith"

This command is called internally during the Replace in Files process. To search without matching case, use /ri instead of /rc.

Restore workspace

/ws

This command is called internally when the Restore Workspace command is selected.

Save workspace

/wss

This command is called internally when the Save Workspace command is selected.

Grab text with EmEditor

/eh

This command is called from the Tray Icon when the shortcut key to grab text with EmEditor defined in the Customize Tray Icon dialog box is pressed.

Display Help

/?

Options

/?displays Help.
/actactivates EmEditor if it is already running, or launches EmEditor if it is not already running.
/bk "BackupFolder"specifies a backup folder when replacing in files.
/c "Config"sets the configuration.
/cacloses all documents.
/carcloses all documents including a hidden window if the "Quick Start" option is enabled.
/cdset the current directory as the default folder in the Open dialog box.
/cjlcustomizes the Jump List on Windows 7 or later.
/cl ColumnNumber logical column number.
/clwclears the workspace.
/cmpcompares two files.
/cp Encoding sets an encoding to open as.  An encoding can be one of Encoding Constants. A combination with following values can be specified.
131072Detects Unicode signature (BOM).
262144Detects UTF-8.
524288Detects HTML/XML Charset.
1048576Detects all encodings.
/cps Encoding sets an encoding to save as.  An encoding can be one of Encoding Constants.
/dispecifies the working folder when creating a new document. Used internally by EmEditor.
/ehgrabs a text box contents.
/fc "FindWhat"find in files (case sensitive).
/fddisplays the Find in Files dialog box.
/ff "FindWhat"find a string directly within the opened document. Can be combined with /mc or /x.
/fi "FindWhat"find in files (ignore case).
/fhhighlights searched strings.
/fndisplays only file names when finding in file.
/fu "FilesToIgnore"ignores the following file or folder names.
/frsearch in sub folders when finding in files (use with /fc or /fi).
/fwsearches only words.
/hideruns EmEditor as a hidden window when the "Quick Start" option is enabled.
/ipastes a text string from the Clipboard.
/ipirefreshes the plug-in list. used from plug-in installers.
/iqpastes a text string in quotes from the Clipboard.
/iqrpastes a text string in quotes and returns from the Clipboard.
/kokeeps modified files open when replacing in files.
/l LineNumber move cursor to the logical line number.
/mcmatches cases when /ff is used to find a string.
/mfspecifies a macro file to run.
/nalways start as a new file.
/ncpsuppresses "The specified file does not exist. Open as a new file?" prompt when a specified file is not found.
/nespecifies event-triggered macros should be disabled.
/nrdoes not add the file path to the recent file list.
/oddisplays the Open dialog box to select files to open.
/pprints the file.
/pos left top right bottomspecifies the window position with four integers (left, top, right, bottom).
/rread-only mode.
/rc "FindWhat"replaces in files (case sensitive).
/rddisplays the Replace in Files dialog box.
/rhopens HTML files as read-only. Used internally.
/ri "FindWhat"replaces in files (ignore case).
/rropens files in folders recursively.
/rwspecifies a string to be replaced with.
/sa "DestFile"specifies a file name to save as after the encoding conversion.
/scasaves and closes all opened documents.
/scrlfsaves the file using CR+LF as return method after the encoding conversion.
/scrsaves the file using the CR only as return method after the encoding conversion.
/slfsaves the file using the LF only as return method after the encoding conversion.
/spspecifies that a new separate process from other EmEditor windows should be run. This option is useful when a new EmEditor window must be launched from another application because the application must monitor the process termination so it can detect the file modification. If this is specified, however, some features including tab operations will be disabled, and will void support.
/ss+saves the file with a Unicode signature (BOM) after the encoding conversion.
/ss-saves the file without a Unicode signature (BOM) after the encoding conversion.
/tidisplays the Tray Icon.
/uobuses the Output Bar to display the Find in Files results.
/xfinds or finds in files using a regular expression.
/wsrestores the workspace.
/wsssaves the workspace.

Examples

/rr *.htm

opens all .htm files including all sub folders.

/p "filename"

prints filename.

/r "filename"

opens filename in read only mode.

/c "Normal" "filename"

opens filename in the default configuration.

/l 123 "filename"

opens filename, jumps to 123rd line and display it.

/ff "what" /mc "filename"

opens filename, and finds what matching cases.

/fh

highlights string of last search.

/ti

opens as a tray icon.

/fi "ABC" "c:\Temp\*.txt"

searches for the string ABC from all files with the extension .txt on the c:\Temp folder while ignoring case.

/fi "abc" /fr /fw /fn /fu "_*;*.bak" /cp 65536 "c:\test\*.htm;*.txt"

searches for the string abc from all files with the extension .htm and .txt on the c:\test folder while ignoring case. it searches sub folders, searches only words, displays only file names, ignores file or folder names matching "_*;*.bak", and uses the system default encoding.

/fc "[a-e]" /fr /x /fu "_*;*.bak" /cp 65536 "c:\test\*.htm;*.txt"

searches for text matching a regular expression [a-e] from all files with the extension .htm and .txt on the c:\test folder while not ignoring case. it searches sub folders, ignores file or folder names matching "_*;*.bak", and uses the system default encoding.

"c:\test\utf16.txt" /cp 65537 /cps 65001 /ss- /sa "c:\test\utf8.txt" /scrlf

converts a UTF-16LE file c:\test\utf16.txt to UTF-8 without a Unicode signature and saves as c:\test\utf8.txt. The return method is converted to CR+LF.

Tips

  • The string searched for in files must be after /fc or /fi.
  • If no options are specified, the selected file will simply be opened.
  • If /c is not specified and the associated extensions of the configuration are the same, open the file with that configuration.
  • If a folder name is specified instead of a file name, the Open dialog box with that folder will be displayed.
  • Command line options are case sensitive. For instance /r will not be recognized if written as /R.
  • Escape seaquences are always on when searching from the command line.
内容概要:《中文大模型基准测评2025年上半年报告》由SuperCLUE团队发布,详细评估了2025年上半年中文大模型的发展状况。报告涵盖了大模型的关键进展、国内外大模型全景图及差距、专项测评基准介绍等。通过SuperCLUE基准,对45个国内外代表性大模型进行了六大任务(数学推理、科学推理、代码生成、智能体Agent、精确指令遵循、幻觉控制)的综合测评。结果显示,海外模型如o3、o4-mini(high)在推理任务上表现突出,而国内模型如Doubao-Seed-1.6-thinking-250715在智能体Agent和幻觉控制任务上表现出色。此外,报告还分析了模型性价比、效能区间分布,并对代表性模型如Doubao-Seed-1.6-thinking-250715、DeepSeek-R1-0528、GLM-4.5等进行了详细介绍。整体来看,国内大模型在特定任务上已接近国际顶尖水平,但在综合推理能力上仍有提升空间。 适用人群:对大模型技术感兴趣的科研人员、工程师、产品经理及投资者。 使用场景及目标:①了解2025年上半年中文大模型的发展现状与趋势;②评估国内外大模型在不同任务上的表现差异;③为技术选型和性能优化提供参考依据。 其他说明:报告提供了详细的测评方法、评分标准及结果分析,确保评估的科学性和公正性。此外,SuperCLUE团队还发布了多个专项测评基准,涵盖多模态、文本、推理等多个领域,为业界提供全面的测评服务。
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值