[lucid] dos2unix is not in tofrodos but dos2unix

Bug #523264 reported by Pavol Klačanský
62
This bug affects 13 people
Affects Status Importance Assigned to Milestone
command-not-found
Invalid
Undecided
Unassigned
command-not-found (Ubuntu)
Fix Released
Medium
Unassigned

Bug Description

Binary package hint: tofrodos

Hallo, I have installed tofrodos, but lucid says, the dos2unix is not in system, and I may install tofrodos (but it is installed!!!)

ProblemType: Bug
Architecture: amd64
Date: Wed Feb 17 17:04:53 2010
DistroRelease: Ubuntu 10.04
InstallationMedia: Ubuntu 9.10 "Karmic Koala" - Release amd64 (20091027)
Package: tofrodos 1.7.8.debian.1-2
ProcEnviron:
 LANG=sk_SK.utf8
 SHELL=/bin/bash
ProcVersionSignature: Ubuntu 2.6.32-13.18-generic
SourcePackage: tofrodos
Uname: Linux 2.6.32-13-generic x86_64

Revision history for this message
Pavol Klačanský (pavolzetor-deactivatedaccount) wrote :
Revision history for this message
Robin Munn (rmunn) wrote :

The dos2unix and unix2dos commands were dropped from the most recent tofrodos package to make room for a new "dos2unix" package (see /usr/share/doc/tofrodos/NEWS.Debian.gz for the reason why). However, the command-not-found package, which is what gives those suggestions, has not been updated with this information.

This is actually a bug in command-not-found, not a bug in tofrodos: switching bug to that package. Also marking as confirmed since I can reproduce on my own Lucid system.

affects: tofrodos (Ubuntu) → command-not-found (Ubuntu)
Changed in command-not-found (Ubuntu):
status: New → Confirmed
Rolf Leggewie (r0lf)
Changed in command-not-found (Ubuntu):
importance: Undecided → Medium
Daniel Hahler (blueyed)
Changed in command-not-found (Ubuntu):
status: Confirmed → Triaged
summary: - [lucid] dos2unix is not in tofrodos
+ [lucid] dos2unix is not in tofrodos but dos2unix
Revision history for this message
DizzyDS (dshiehmobile) wrote :

The quick workaround now is to create a link to the new package files. "fromdos" = "dos2unix" and "todos" = "unix2dos" Both files can be found under /usr/bin/

Revision history for this message
COKEDUDE (cokedude) wrote :

That workaround is not working for me.

Revision history for this message
HsH (hsh) wrote :

Try to use alias:

alias unix2dos="/usr/bin/fromdos -u" (or todos)
alias dos2unix="/usr/bin/fromdos -d" (or just fromdos)

Revision history for this message
Matthew (mattgen) wrote :

The easier way around this problem is to make a soft link to todos and fromdos. If you have sudo administrative rights, you can make the soft link in the same directory as follows...

sudo ln -s fromdos dos2unix
sudo ln -s todos unix2dos

Or if do not have sudo privileges, you can make the soft link from a directory that you have access to...

I prefer this method over creating an alias since the alias should be in a file that needs to be read during system initialise (or by typing source <alias_file>) . If done local, alias will work in the present window that it has been set; a soft link will work directly after creation.

I have made both soft links and I have already run dos2unix successfully....

I hope this helps...

Revision history for this message
Bruno Medeiros (brunojcm) wrote :

The title of this bug doesn't make sense to me. The dos2unix is supposed to be in the dos2unix package, but I can't find it:

brunojcm@brunojcm-laptop:~/Downloads$ sudo apt-get install dos2unix
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Couldn't find package dos2unix

Where is this package supposed to be?

Revision history for this message
Matthew (mattgen) wrote :

Bruno,

This bug is a misnomer. Ubuntu decided to replace the tofromdos modules with their own utilities as standard with the Lucid version. The issue is that the former links of dos2unix and unix2dos are not set properly but it is hard to determine this during the install; the Lucid version is missing the soft links to these utilities...

So, the user needs either to create a soft link or alias to /usr/bin/fromdos and /usr/bin/todos... If you at my post (#6), I show how this easily can be done...

I hope this helps you... Good luck...

By the way, it did take me some time to actually understand the bug as well; you are in good company...

Revision history for this message
David Litster (mrlitsta) wrote :

Actually, the REAL problem here is that fundamental, documented behavior has been changed in an LTS release.

The is a symptom of a larger problem: established norms randomly changing with every new release, completely breaking backwards compatibility.

Where in the world did the "fromdos" and "todos" commands come from?

It's like the ubuntu devs changing the "ls" command to "listdir" from one release to another. You can only imagine the uproar that would create as scripts break, people riot, cities burn down.

Someone shouldn't HAVE to create symlinks from "dos2unix" to "fromdos", or from "unix2dos" to "todos" upon installing a new version of Ubuntu. It should not have changed.

What is the point or incentive of learning to use Ubuntu if half the things you know change drastically every six months?

If the Ubuntu team decides the the "tofrodos" utilities are inadequate, then create another package.

Same bug noted here.

Revision history for this message
markoa (marko-marko) wrote :

I agree with David and I'm unsubscribing from this bug saddened that a discussion about this is going on for an entire year.

Revision history for this message
Zygmunt Krynicki (zyga) wrote :

This seems to be fixed on natty

Changed in command-not-found:
status: New → Invalid
Changed in command-not-found (Ubuntu):
status: Triaged → Fix Released
Revision history for this message
Peter Passchier (peter-passchier) wrote :

How about a backport? Lucid is a LTS, so you'd expect these kind of fixes to appear when they are fixed in later releases.

Revision history for this message
Neal McBurnett (nealmcb) wrote :

Note - it sounds like the dos2unix package may be preferable for those wanting a more general-purpose conversion tool, and the command names that are missing from tofrodos. That is according to the tofrodos package documentation (as noted in #2). Here is the relevant text from /usr/share/doc/tofrodos/NEWS.Debian.gz, as of 12.04:

 With this release the symlinks "unix2dos" and "dos2unix" are dropped from the
  package. This will allow the introduction of the original dos2unix package,
  which also supports conversion to MacOS style files.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.