Re: Editors are broken after update

2013-01-21 Thread Polytropon
On Mon, 21 Jan 2013 09:51:13 +0100, Ralf Mardorf wrote:
> On Mon, 21 Jan 2013 03:53:56 +0100, Polytropon  wrote:
> > /usr/home/rocketmouse, _not_ user/home/rocketmouse
> 
> It wasn't possible to copy the message, so I've written it. It's very  
> likely that I made a typo. I'm a dyslexic and since there's no big  
> difference between /usr and /user and it both is for "user" it's very  
> likely that I haven't notice it all the times when I read it. If I would  
> have written /usgr or something similar it could happen that I don't  
> notice it when reading it 2 or 3 times, but when reading it for the 4th  
> time I will notice it. It oven happens that people type 'unmount' instead  
> of 'umount', so I've seen Linux distros that ship with an alias 'unmount'  
> :D.

Seen in this context, the message was probably beginning
with "/usr" instead of "user" which makes sense (even though
it would be considered a bug when the editor is invoked
without a file name and it instead tries to open "something"
that is not a file to edit). It also fits the tradition that
"usr" is often pronounced "user" and therefor carries that
"mental image".



> OT:
> 
> # grep alias .cshrc
> alias h   history 25
> alias j   jobs -l
> alias la  ls -aF
> alias lf  ls -FA
> alias ll  ls -lAF
> 
> I avoid using aliases. FWIW on Linux mailing lists that aren't for a  
> specific distro, it's unwanted to use aliases when posting to the list.

That's a valid advice, especially when the alias name suggests
that it does something it doesn't do in reality. However, a
common alias "ll" for "list long" is widely accepted, even though
the implementation (and additional flags and preferences) may
differ from system to system.

alias   ls  'ls -FG -D "%Y-%m-%d %H:%M:%S"'
alias   ll  'ls -laFG -D "%Y-%m-%d %H:%M:%S"'
setenv  LSCOLORSExGxdxdxCxDxDxBxBxegeg

;-)



-- 
Polytropon
Magdeburg, Germany
Happy FreeBSD user since 4.0
Andra moi ennepe, Mousa, ...
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"


Re: Editors are broken after update

2013-01-21 Thread Ralf Mardorf

On Mon, 21 Jan 2013 03:53:56 +0100, Polytropon  wrote:

/usr/home/rocketmouse, _not_ user/home/rocketmouse


It wasn't possible to copy the message, so I've written it. It's very  
likely that I made a typo. I'm a dyslexic and since there's no big  
difference between /usr and /user and it both is for "user" it's very  
likely that I haven't notice it all the times when I read it. If I would  
have written /usgr or something similar it could happen that I don't  
notice it when reading it 2 or 3 times, but when reading it for the 4th  
time I will notice it. It oven happens that people type 'unmount' instead  
of 'umount', so I've seen Linux distros that ship with an alias 'unmount'  
:D.


I'm sorry for the confusion :). I only noticed it regarding to your  
comparison.


OT:

# grep alias .cshrc
alias h history 25
alias j jobs -l
alias lals -aF
alias lfls -FA
alias llls -lAF

I avoid using aliases. FWIW on Linux mailing lists that aren't for a  
specific distro, it's unwanted to use aliases when posting to the list.


Regards,
Ralf
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"


Re: Editors are broken after update

2013-01-20 Thread Polytropon
On Sun, 20 Jan 2013 14:20:10 +0100, Ralf Mardorf wrote:
> Since I only run "mcedit" without a file, the error message is grotesque  
> and btw.

Exactly - it is, and probably misleading as it implies that
mcedit is trying to access something that doesn't even exist,
even with a maximum of imagination.



> $ ls -l /usr/home
> total 2
> drwxr-xr-x  26 rocketmouse  rocketmouse  1536 Jan 20 13:07 rocketmouse
> $ ls -l /home
> lrwxr-xr-x  1 root  wheel  8 Dec 18 19:19 /home -> usr/home

That is a valid symlink on a FreeBSD installation (and has been
a default for a long time), so /home/rocketmouse will equal
/usr/home/rocketmouse, _not_ user/home/rocketmouse as shown
in the error message.



> Thank you for the hints. I take the issues with a good portion of humor.

I think this isn't funny anymore - an editor that stops working
without explaining the reason in an understandable way...



> This might explain why you're confused regarding to the /home path:
> 
> $ cat /etc/fstab
> # Device  Mountpoint  FStype  Options DumpPass#
> /dev/ad4s1b   noneswapsw  0   0
> /dev/ad4s1a   /   ufs rw  1   1
> /dev/ad4s1e   /tmpufs rw  2   2
> /dev/ad4s1f   /usrufs rw  2   2
> /dev/ad4s1d   /varufs rw  2   2
> /dev/acd0 /cdrom  cd9660  ro,noauto   0   0
> #proc   /proc   procfs  rw  0   0

No, looks perfectly valid. On my other system, for example, I
have /home being /export/home with the proper symlink, and no
problems at all.



> $ mc
> 
> does start midnight commander, but if I push "4 Edit" I get the same error  
> message.

Okay, so the problem lies deeply within the editor.



> I did "dump -0Launf [...]" everything and will continue later. Hopefully  
> with some fun, when starting with audio, instead of mcedit.

In worst case, try portdowngrade (or use svn to obtain an older
copy of the mc port where the editor hasn't been disimproved yet).




-- 
Polytropon
Magdeburg, Germany
Happy FreeBSD user since 4.0
Andra moi ennepe, Mousa, ...
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"


Re: Editors are broken after update

2013-01-20 Thread Ralf Mardorf
On Sun, 20 Jan 2013 16:49:12 +0100, Herbert J. Skuhra   
wrote:

On Sun, 20 Jan 2013 09:46:00 +0100
"Ralf Mardorf"  wrote:


Wow, if on Linux something is fishy, it usually has to do with Lennart
Poettering, does he break FreeBSD too?

$ su -
Password:
root@freebsd:/root # mcedit

Error
"/root" is not a regular file [ Dismiss ]


https://www.midnight-commander.org/ticket/2754

There is a patch that fixes this problem:



Maintainer CC'ed.


I didn't notice that it does run with an exiting file-name, but it does

$ mcedit /etc/fstab

is ok.

It's also ok for a file that doesn't exist

$ mcedit foo

this didn't work before I deleted the mc contend in /home/user_name.

Thank you!
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"


Re: Editors are broken after update

2013-01-20 Thread Herbert J. Skuhra
On Sun, 20 Jan 2013 09:46:00 +0100
"Ralf Mardorf"  wrote:

> Wow, if on Linux something is fishy, it usually has to do with Lennart
> Poettering, does he break FreeBSD too?
> 
> $ su -
> Password:
> root@freebsd:/root # mcedit
> 
> Error
> "/root" is not a regular file [ Dismiss ]

https://www.midnight-commander.org/ticket/2754

There is a patch that fixes this problem:



Maintainer CC'ed.

-- 
Herbert
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"


Re: Editors are broken after update

2013-01-20 Thread Ralf Mardorf
Since I only run "mcedit" without a file, the error message is grotesque  
and btw.


$ ls -l /usr/home
total 2
drwxr-xr-x  26 rocketmouse  rocketmouse  1536 Jan 20 13:07 rocketmouse
$ ls -l /home
lrwxr-xr-x  1 root  wheel  8 Dec 18 19:19 /home -> usr/home

Thank you for the hints. I take the issues with a good portion of humor.

This might explain why you're confused regarding to the /home path:

$ cat /etc/fstab
# DeviceMountpoint  FStype  Options DumpPass#
/dev/ad4s1b noneswapsw  0   0
/dev/ad4s1a /   ufs rw  1   1
/dev/ad4s1e /tmpufs rw  2   2
/dev/ad4s1f /usrufs rw  2   2
/dev/ad4s1d /varufs rw  2   2
/dev/acd0   /cdrom  cd9660  ro,noauto   0   0
#proc   /proc   procfs  rw  0   0

$ mc

does start midnight commander, but if I push "4 Edit" I get the same error  
message.


I did "dump -0Launf [...]" everything and will continue later. Hopefully  
with some fun, when starting with audio, instead of mcedit.


To be continued.

Regards,
Ralf
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"


Re: Editors are broken after update

2013-01-20 Thread Polytropon
On Sun, 20 Jan 2013 11:21:17 +0100, Ralf Mardorf wrote:
> On Sun, 20 Jan 2013 10:38:45 +0100, Polytropon  wrote:
> > # cd /root
> > # mv .mc .mc.orig
> > # mcedit
> 
> $ mv .mc .mc.pre.update-01-Jan-2013
> $ su root -c "mv /root/.mc /root/.mc.pre.update-01-Jan-2013"
> $ mcedit
> 
> Error
> "user/home/rocketmouse" is not a regular file [ Dismiss ]

Also looks wrong, that doesn't seem to be a valid path.
I assume /home/rocketmouse would be your home directory,
so MC (or mcedit) would access a configuration structure
within that directory (~/.mc).



> > That should start the editor with the defaults.
> 
> It doesn't do it for the user.

Are you able to start the "normal" Midnight Commander instead?
And if yes, PF4 on a file to invoke the editor?



> > Of course, /root is not a regular file, it's a directory. :-)
> 
> Yes and in this case it's true for the users home directory, but I only  
> run mcedit, without a file name.

That shouldn't be a problem. If I start mcedit without a filename
here, I _still_ get the editor launched with an empty file, with
PF2 allowing me to enter a file name.

(Version here: 4.7.5_1 on FreeBSD 8.2-STABLE i386).



> > This editor requires X. If you're running the above su command
> > in an xterm, use "su -m root" and try again.
> 
> On Linux regarding to this, there is a difference between "su" and "su -",  
> I never had to run "su -m root".

The -m option makes sure the environment is not touched, so $DISPLAY
will be kept. If you do a full root login (su - and su -l simulate
a full login, and omission of the name assumes root, so "su -" is
like "su -l root", discarding your user's environment).



> $ su -m root
> # mcedit
> 
> Error
> "user/home/rocketmouse" is not a regular file [ Dismiss ]

That was designed for running gedit as root (because of X). :-)

Again, the path specification just looks wrong - there is no
such thing (not absolute, not relative to ~).



> # ls -l .config/mc
> total 8
> -rw-r--r--  1 rocketmouse  rocketmouse  2931 Jan 20 10:55 ini
> drwx--  2 rocketmouse  rocketmouse   512 Jan 20 09:28 mcedit
> -rw-r--r--  1 rocketmouse  rocketmouse 1 Jan 20 10:51 panels.ini

Okay, so this looks like it would be the new configuration
location. For comparison:

% ls .mc
Treebindings_1  filepos ini
bindingscedit/  history panels.ini

And cedit/ is now mcedit/.



> # rm -r /root/.mc* /root/.config/mc /home/rocketmouse/.mc*  
> /home/rocketmouse/.config/.mc
> rm: /home/rocketmouse/.config/.mc: No such file or directory
> # rm -r /home/rocketmouse/.config/mc
> 
> # mcedit
> 
> Error
> "user/home/rocketmouse" is not a regular file [ Dismiss ]

Time for portdowngrade? :-)



> # gedit
> GConf Error: Failed to contact configuration server; some possible causes  
> are that you need to enable TCP/IP networking for ORBit, or you have stale  
> NFS locks due to a system crash. See http://projects.gnome.org/gconf/ for  
> information. (Details -  1: Failed to get connection to session: The  
> connection is closed)
> GConf Error: Failed to contact configuration server; some possible causes  
> are that you need to enable TCP/IP
> [snip]
> networking for ORBit, or you have stale NFS locks due to a system crash.  
> See http://projects.gnome.org/gconf/ for information. (Details -  1:  
> Failed to get connection to session: The connection is closed)
> g_dbus_connection_real_closed: Remote peer vanished with error: Underlying  
> GIOStream returned 0 bytes on an async read (g-io-error-quark, 0). Exiting.
> Terminated

What a scary error message. It seems that gedit relies a lot on
Gtk / Gnome services running to access its own configuration, and
that is not accessible from an instance running as root (in
opposite to running as the user who started X and the services
required).



> On Linux it's a common issue for some distros, when using apps from  
> bloated DEs.

So it seems that this "nice tradition" is also carried with programs
ported to FreeBSD. Excellent.

% gimp
(gimp:3045): GLib-WARNING **: goption.c:2132: ignoring no-arg, optional-arg or 
filename flags (8) on option of type 0



> It usually needs gksu or similar.

Programs being designed to be primarily used within specific
desktop environments heavily rely on the mechanisms provided
by those environments, even though one would consider them
optional (as the program can be used "stand-alone"). Obviously
it's not true to consider that.



> At the end of the update I  
> got the information, that for K3b I have to set the suid flag for cdrecord  
> and cdrdao.

That doesn't seem to be the default:

% ll /usr/local/bin/cdr*
-r-xr-xr-x  1 root  wheel  564156 2011-08-22 03:01:50 /usr/local/bin/cdrdao*
-r-xr-xr-x  1 root  wheel  399044 2011-08-22 03:12:57 /usr/local/bin/cdrecord*

% ll /dev/cd* /dev/pass* /dev/xpt*
crw-rw-r--  1 root  operator0, 110 2013-01-20 09:18:50 /dev/cd0
crw-rw-r--  1 root  operator0, 111 2013-01-20 09:18:50 /dev/cd1
lrwxr-xr-x  1 r

Re: Editors are broken after update

2013-01-20 Thread Ralf Mardorf

On Sun, 20 Jan 2013 10:38:45 +0100, Polytropon  wrote:

# cd /root
# mv .mc .mc.orig
# mcedit


$ mv .mc .mc.pre.update-01-Jan-2013
$ su root -c "mv /root/.mc /root/.mc.pre.update-01-Jan-2013"
$ mcedit

Error
"user/home/rocketmouse" is not a regular file [ Dismiss ]


That should start the editor with the defaults.


It doesn't do it for the user.


Of course, /root is not a regular file, it's a directory. :-)


Yes and in this case it's true for the users home directory, but I only  
run mcedit, without a file name.



This editor requires X. If you're running the above su command
in an xterm, use "su -m root" and try again.


On Linux regarding to this, there is a difference between "su" and "su -",  
I never had to run "su -m root".


$ su -m root
# mcedit

Error
"user/home/rocketmouse" is not a regular file [ Dismiss ]


Seems that the new MC version has migrated its configuration
files somewhere else...


Yes.

# ls -l .config/mc
total 8
-rw-r--r--  1 rocketmouse  rocketmouse  2931 Jan 20 10:55 ini
drwx--  2 rocketmouse  rocketmouse   512 Jan 20 09:28 mcedit
-rw-r--r--  1 rocketmouse  rocketmouse 1 Jan 20 10:51 panels.ini

# rm -r /root/.mc* /root/.config/mc /home/rocketmouse/.mc*  
/home/rocketmouse/.config/.mc

rm: /home/rocketmouse/.config/.mc: No such file or directory
# rm -r /home/rocketmouse/.config/mc

# mcedit

Error
"user/home/rocketmouse" is not a regular file [ Dismiss ]

# gedit
GConf Error: Failed to contact configuration server; some possible causes  
are that you need to enable TCP/IP networking for ORBit, or you have stale  
NFS locks due to a system crash. See http://projects.gnome.org/gconf/ for  
information. (Details -  1: Failed to get connection to session: The  
connection is closed)
GConf Error: Failed to contact configuration server; some possible causes  
are that you need to enable TCP/IP

[snip]
networking for ORBit, or you have stale NFS locks due to a system crash.  
See http://projects.gnome.org/gconf/ for information. (Details -  1:  
Failed to get connection to session: The connection is closed)
g_dbus_connection_real_closed: Remote peer vanished with error: Underlying  
GIOStream returned 0 bytes on an async read (g-io-error-quark, 0). Exiting.

Terminated

On Linux it's a common issue for some distros, when using apps from  
bloated DEs. It usually needs gksu or similar. At the end of the update I  
got the information, that for K3b I have to set the suid flag for cdrecord  
and cdrdao. Wow, for FreeBSD the kit family is installed, so setting suid  
IMO shouldn't be needed and should be avoided, perhaps there's the need to  
use kdesu?


# cd /usr/ports/sysutils/gksu ; make install clean
[...]

$ gksu gedit

Yes, it does work. I suspect for K3b it's not needed to set suid, but to  
install kdesu or perhaps gksu does work too.


However, there's still this issue for mcedit :(.

It would be nice if not so many Linux distros and FreeBSD won't follow  
upstream for some odd policies :(.

When I read the name Lennart Poettering my blood pressure does rise ;).

Regards,
Ralf
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"


Re: Editors are broken after update

2013-01-20 Thread Polytropon
On Sun, 20 Jan 2013 09:46:00 +0100, Ralf Mardorf wrote:
> Wow, if on Linux something is fishy, it usually has to do with Lennart  
> Poettering, does he break FreeBSD too?
> 
> $ su -
> Password:
> root@freebsd:/root # mcedit
> 
> Error
> "/root" is not a regular file [ Dismiss ]

Seems to be a problem with the configuration. Temporarily
try the following:

# cd /root
# mv .mc .mc.orig
# mcedit

That should start the editor with the defaults.

Of course, /root is not a regular file, it's a directory. :-)



> root@freebsd:/root # gedit
> 
> (gedit:17410): Gtk-WARNING **: cannot open display:

This editor requires X. If you're running the above su command
in an xterm, use "su -m root" and try again.



> root@freebsd:/root # vi
> 
> vi does run

Because vi belongs to the OS, it's not a port.



> root@freebsd:/root # logout
> $ mcedit
> Failed to run:
> Your old settings were migrated from /home/rocketmouse/.mc
> to Freedesktop recommended dirs.
> To get more info, please visit
> http://standards.freedesktop.org/basedir-spec/basedir-spec-latest.html [1]

Seems that the new MC version has migrated its configuration
files somewhere else...



> $ gedit
> 
> As user gedit does start, so perhaps I need gksu to run it as root.

That sounds wrong. What would be a reason for an installed editor
that is intended to be run on X _not_ to run from a user account
that currently runs X?



> [1] That's a nightmare :(, I don't want to read something that has to do  
> with Lennart Poettering.

I'm not sure in how far this XDG stuff applies to MC / mcedit...
but the message seems to originate from MC which adopts to the
FreeDesktop recommendations...



> What the hell is broken now, regarding to the insane ideas of this man?

Implied statement (not _my_ words): "Every program should store
its configuration data according to the XDG / FreeDesktop
specification." Seems that the MC agreed.



> OT:  
> http://linux-bsd-sharing.blogspot.de/2008/08/howto-musicpd-music-player-daemon-on.html
>   
> is not a valid howto for my upgraded FreeBSD ports :(.

>From a short look at it, the content looks valid. But I haven't
tried it in order to confirm that it's working.



-- 
Polytropon
Magdeburg, Germany
Happy FreeBSD user since 4.0
Andra moi ennepe, Mousa, ...
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"


Editors are broken after update

2013-01-20 Thread Ralf Mardorf
Wow, if on Linux something is fishy, it usually has to do with Lennart  
Poettering, does he break FreeBSD too?


$ su -
Password:
root@freebsd:/root # mcedit

Error
"/root" is not a regular file [ Dismiss ]

root@freebsd:/root # gedit

(gedit:17410): Gtk-WARNING **: cannot open display:

root@freebsd:/root # vi

vi does run

root@freebsd:/root # logout
$ mcedit
Failed to run:
Your old settings were migrated from /home/rocketmouse/.mc
to Freedesktop recommended dirs.
To get more info, please visit
http://standards.freedesktop.org/basedir-spec/basedir-spec-latest.html [1]
$ gedit

As user gedit does start, so perhaps I need gksu to run it as root.

Fortunately pico does run for the user and for root.

[1] That's a nightmare :(, I don't want to read something that has to do  
with Lennart Poettering.

What the hell is broken now, regarding to the insane ideas of this man?

OT:  
http://linux-bsd-sharing.blogspot.de/2008/08/howto-musicpd-music-player-daemon-on.html  
is not a valid howto for my upgraded FreeBSD ports :(.


Regards,
Ralf
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"