macOS
brew install dos2unixlocal Homebrew formula metadata
sudo port install dos2unixMacPorts ports tree · textproc/dos2unix/Portfile · 来源: api.github.com
安装
brew install dos2unixlocal Homebrew formula metadata
sudo port install dos2unixMacPorts ports tree · textproc/dos2unix/Portfile · 来源: api.github.com
sudo apk add dos2unixAlpine Linux edge package indexes · dos2unix · 来源: dl-cdn.alpinelinux.org
sudo apt install dos2unixDebian stable package indexes · dos2unix · 来源: deb.debian.org
sudo dnf install dos2unixFedora Rawhide package metadata · dos2unix · 来源: dl.fedoraproject.org
nix profile install nixpkgs#dos2unixnixpkgs package indexes · pkgs/by-name/do/dos2unix/package.nix · 来源: api.github.com
sudo pacman -S dos2unixArch Linux sync databases · dos2unix · 来源: geo.mirror.pkgbuild.com
sudo zypper install dos2unixopenSUSE Tumbleweed package metadata · dos2unix · 来源: download.opensuse.org
choco install dos2unixChocolatey community package catalog · dos2unix · 来源: community.chocolatey.org
scoop install main/dos2unixScoop official bucket manifest trees · bucket/dos2unix.json · 来源: api.github.com
winget install --id waterlan.dos2unix -eWindows Package Manager source index · waterlan.dos2unix · 来源: cdn.winget.microsoft.com
概览
Convert text between DOS, UNIX, and Mac formats
历史
dos2unix is the long-running command-line utility family for converting plain-text line endings among DOS/Windows CRLF, Unix LF, and classic Mac CR formats. Its package-nerd appeal is that it solves one of the oldest cross-platform source-tree annoyances with tiny, scriptable tools that became familiar on Unix, Linux, Windows, DOS, Cygwin, and OS/2.
The current dos2unix package is an Erwin Waterlander-maintained update of Benjamin Lin's dos2unix and unix2dos implementations. The official history traces the lineage back to John Birchfield's 1989 versions, Benjamin Lin's 1995 rewrite, Bernd Johannes Wuebben's 1998 Mac-to-Unix addition, and Waterlander's 2010 Unix-to-Mac addition.
The Waterlander package bundled the formerly separate dos2unix and unix2dos packages into a single dos2unix release at version 5.0 in 2010. Later milestones included UTF-16 support in version 6.0 in 2012 and a major cleanup plus test suite in version 7.0 in 2014.
Benjamin Lin's implementations were distributed through SunSITE.unc.edu, later MetaLab and ibiblio, and became part of Linux distributions including Red Hat, SUSE, Gentoo, and others. The Homebrew source facts also list broad packaging across apk, Debian, Fedora, MacPorts, Nix, pacman, Scoop, Ubuntu, winget, and zypper.
The official homepage continues to publish source archives and ready-to-run binaries for DOS, Windows, and OS/2 alongside Unix-style documentation, reflecting a tool whose user base spans old and modern operating systems.
The package includes dos2unix, unix2dos, mac2unix, and unix2mac commands. It is commonly used in source checkouts, release scripts, build systems, and data-cleanup pipelines when files cross Windows and Unix-like environments.
Modern dos2unix does more than swap CRLF and LF: official documentation covers in-place and paired conversion modes, binary-file skipping, symbolic-link behavior, Unicode UTF-16 to UTF-8 conversion, byte-order-mark handling, recursive conversion recipes, and translated manuals.
dos2unix is a classic small package that persists because text line endings remain a real interoperability boundary. Package maintainers care about it because it is tiny, has no credential or daemon surface, and shows up wherever archives, generated files, or vendored code cross platform conventions.
Its significance is also historical: it preserves SunOS/Solaris-style behavior while adjusting defaults for practical Unix packaging, such as in-place conversion by default in this implementation.
安全态势
narrow executable package without higher-risk signals.
绿色 风险 · 低 置信度 · appliance
在无人值守的代理使用前,请检查该工具是否读取明文凭据、写入远程状态、发布制品或调用插件。
可执行文件
| 命令 | 类型 | 暴露范围 | 备注 |
|---|---|---|---|
dos2unix | cli | 全局可执行文件 | |
mac2unix | cli | 全局可执行文件 | |
unix2dos | cli | 全局可执行文件 | |
unix2mac | cli | 全局可执行文件 |
新鲜度
这些信号区分页生成时间、软件包管理器活动和上游发布比较。只有存在证据 URL 和可比较版本时,才会提示版本落后。
https://waterlander.net/dos2unix/
安装元数据
| 软件包键 | brew:dos2unix |
|---|---|
| 版本 | 7.5.6 |
| 软件包管理器 | Homebrew |
| 软件包管理器页面 | https://formulae.brew.sh/formula/dos2unix |
| 主页 | https://waterlander.net/dos2unix/ |
| 仓库 | https://git.code.sf.net/p/dos2unix/dos2unix |
| 上游文档 | https://dos2unix.sourceforge.io/dos2unix/man1/dos2unix.htm |
| 许可证 | BSD-2-Clause |
| 源码归档 | https://waterlander.net/dos2unix/files/dos2unix-7.5.6.tar.gz |
| 最后更新 | 2026-06-27T04:30:36Z |
| Pulse | updated |
| Bottle | 可用 (于 arm64_linux, arm64_sequoia, arm64_sonoma, arm64_tahoe, sonoma, x86_64_linux) |
| Homebrew post-install | 未定义 |
| 服务 | 未声明 |
注册表事实
| Source Database | Homebrew formula API |
|---|---|
| Tap | homebrew/core |
| Full Name | dos2unix |
| Aliases |
|
| Version Scheme | 0 |
| Revision | 0 |
| Bottle Stable Root URL | https://ghcr.io/v2/homebrew/core |
| Deprecated | no |
| Disabled | no |
| Keg Only | no |
| URL Keys |
|
源数据库匹配
匹配项来自外部软件包管理器索引,并与本地 Automic Vault 软件包链接分开显示。
dos2unix 7.5.2-1
convert text file line endings between CRLF and LF
https://waterlan.home.xs4all.nl/dos2unix.html
sudo apt install dos2unixdos2unix
nix profile install nixpkgs#dos2unixdos2unix 7.5.1-1
convert text file line endings between CRLF and LF
https://waterlan.home.xs4all.nl/dos2unix.html
sudo apt install dos2unixdos2unix 7.5.5-r0
Text file format converters
https://waterlan.home.xs4all.nl/dos2unix.html
sudo apk add dos2unixdos2unix-doc 7.5.5-r0
Text file format converters (documentation)
https://waterlan.home.xs4all.nl/dos2unix.html
sudo apk add dos2unix-docdos2unix 7.5.5-1.fc45
Text file format converters
https://waterlan.home.xs4all.nl/dos2unix.html
sudo dnf install dos2unixdos2unix 7.5.6-1
Text file format converter
https://waterlan.home.xs4all.nl/dos2unix.html
sudo pacman -S dos2unixdos2unix 7.5.6-1.1
Text converters to and from DOS/MAC to UNIX
https://waterlander.net/dos2unix/
sudo zypper install dos2unixdos2unix
sudo port install dos2unixdos2unix
choco install dos2unixmain/dos2unix
scoop install main/dos2unixwaterlan.dos2unix
winget install --id waterlan.dos2unix -e来源线索
此页面由 av-web 从 scripts/generate-pkg-sqlite.py 生成的私有软件包 SQLite 工件提供。
View the package source record on GitHub.