Re: Useful Unix compatible commands

2024-02-26 Thread Will Mengarini
* Jonathan Matthew Gresham  [24-02/25=Su 16:01 -0500]:
> [...] I have been reading a Unix system administrators textbook.
> ps -e
> [...]
> kill process
> [...]
> ls -R
> [...]
> If you know any more that can work on GNU compatible software or
> Unix compatible software please indicate the commands in your reply.

This is a decent introduction to the important commands:

https://www.freecodecamp.org/news/the-linux-commands-handbook/



Re: Useful Unix compatible commands

2024-02-26 Thread Byunghee HWANG
Hellow Jonathan,

Jonathan Matthew Gresham  writes:

> 
> ps -e
> ls -R
>

ls -F


Thanks, Byunghee from South Korea

-- 
^고맙습니다 _布德天下_ 감사합니다_^))//


Re: Useful Unix compatible commands

2024-02-25 Thread Dan Ritter
Jonathan Matthew Gresham wrote: 
> If you know any more that can work on GNU compatible software or Unix 
> compatible software please indicate the commands in your reply.


Perhaps you want to read the Debian Administrator's Handbook? 

https://www.debian.org/doc/manuals/debian-handbook/

Or an introduction to Linux command line work?

Or to BASH?

Your question is very unfocused.

-dsr-



Re: Useful Unix compatible commands

2024-02-25 Thread Michael Kjörling
On 25 Feb 2024 16:01 -0500, from m...@jmgresham.xyz (Jonathan Matthew Gresham):
> ps -e
> 
> This lists the processes
> 
> In that display (if I'm correct) if you see a program that has
> extremely high time, then you should kill the process.
> 
> kill process

_Definitely_ not blindly.

For example, among the highest-time processes on my system I currently
see xfce4-panel, Xorg, apcupsd, rclone and a few ZFS housekeeping
processes. Among slightly lower times, there's xfwm4, pipewire and
systemd-journal. (All of these share the trait that they also have
been running for a long period of wallclock time.) Another that could
show up would likely be qemu/KVM related processes for long-running
VMs, but I don't have any up and running currently. And if I'm doing
something like watching a movie, mpv or one of its friends would
probably be right up there as well.

Killing those would have potentially severe negative impacts on my
ability to actually use the computer to perform normal, useful tasks.

_That a process is doing a lot of work doesn't by itself mean that it
shouldn't be running._

-- 
Michael Kjörling  https://michael.kjorling.se
“Remember when, on the Internet, nobody cared that you were a dog?”



Useful Unix compatible commands

2024-02-25 Thread Jonathan Matthew Gresham
Sorry for the misleading post the other day. However, I have been reading a 
Unix system administrators textbook. 

ps -e

This lists the processes

In that display (if I'm correct) if you see a program that has extremely high 
time, then you should kill the process.

kill process

There is also

ls -R

This command lists the files in each subdirectory.

If you know any more that can work on GNU compatible software or Unix 
compatible software please indicate the commands in your reply.

Request for output of commands [WAS Re: AW: AW: AW: su su- sudo dont work]

2024-02-07 Thread Andrew M.A. Cater
On Wed, Feb 07, 2024 at 02:15:06PM +, Schwibinger Michael wrote:
> 
> Good afternoon
> 
> I did send the bugreport.
> 
> Thank You.
> Did anybody use the rescue mode?
> 
> Regards Sophie
> 
> 
> 
> Von: Andrew M.A. Cater 
> Gesendet: Mittwoch, 31. Januar 2024 20:36
> An: debian-user@lists.debian.org ; Schwibinger 
> Michael 
> Betreff: Re: AW: AW: su su- sudo dont work
> 
> On Wed, Jan 31, 2024 at 01:58:41PM +, Schwibinger Michael wrote:
> > Good afternoon
> > I think
> > maybe Im sure
> > it is because of rescue mode.
> >
> Hi Sophie,
> 
> Once again: we need to you to show us what commands you run.
> 
> We need to see error messages.
> 
> if you cannot run sudo or su, we need you to run the id command
> as previously suggested.
> 

Where is the output of the id command?

The other message you quote suggests that you aren't in the sudo group

*Show the error messages*


> Also - please address requests first to the list and not to individuals -
> it makes it a lot easier to follow on the list.
> 

>From the output of my mailer: you sent first to me, copy to the list -
could you please do this the other way round as requested. It is more
important for the list to see this - and it also means that there is
no personal reply sent to the list by mistake: any personal reply is
intended as such.

> > Normal booting did not have this problem.
> >
> > Anybody familiar with panic?
> >

Yes: a (kernel) panic can have many causes: if you can give us meaningful
responses, we may be able to help. In the absence of these, you only
get guesses - wheich may or may not be helpful.

Again, as previously requested, please use meaningful subjects on your
emails so that we can deal with one issue at a time.

Andy
(amaca...@debian.org)


> > Regards
> > Thank You
> > Sophie
> >
> Andy
> >
> > 
> > Von: Andrew M.A. Cater 
> > Gesendet: Donnerstag, 25. Januar 2024 18:40
> > An: debian-user@lists.debian.org 
> > Betreff: Re: AW: su su- sudo dont work
> >
> > On Thu, Jan 25, 2024 at 03:53:10PM +, Schwibinger Michael wrote:
> > > Good afternoon
> > > Why do I have to open a group?
> > >
> >
> > This is to *tell* us information about why you're having problems with su
> > and sudo
> >
> > Running the
> >
> > id
> >
> > command should give you information like
> >
> > uid=1000(amacater) gid=1000(amacater) groups=1000(amacater),27(sudo)
> >
> > which shows you that my user - amacater - is the first user on the
> > machine (because Debian starts user id numbers at 1000 for ordinary
> > users) and that I'm a member of group sudo - so can use sudo instead of su.
> >
> > /etc/sudoers will show you what privileges the sudo user has.
> > Here are the last lines of the file on my machine (which has not been
> > modified from Debian defaults)
> >
> > # User privilege specification
> > rootALL=(ALL:ALL) ALL
> >
> > # Allow members of group sudo to execute any command
> > %sudo   ALL=(ALL:ALL) ALL
> >
> > # See sudoers(5) for more information on "@include" directives:
> >
> > @includedir /etc/sudoers.d
> > (END)
> >
> > If you are _not_ a user of group sudo for whatever reason - and want to
> > use sudo - then you will need root privileges and the root password
> > (once) to add your user name to the group.
> >
> > For example: adduser sophie sudo
> >
> > I hope this helps
> >
> > > 2 years ago
> > > sudo was no problem.
> > >
> >
> > As yet, we have *no idea* what you have done in the last two years to
> > break your Debian system - or even to know which kernel you boot or
> > how you "rescue" your system when you log onto it every day.
> >
> > Please give us information in order that the readers on this list can
> > use their knowledge to help you.
> >
> > With every good wish, as ever,
> >
> > Andy
> > (amaca...@debian.org)
> > > Regards
> > >
> > > Sophie
> > >
> > > Thank You
> > > 
> > > Von: Timothy M Butterworth 
> > > Gesendet: Montag, 22. Januar 2024 00:07
> > > An: Schwibinger Michael 
> > > Cc: Greg Wooledge ; debian-user@lists.debian.org 
> > > 
> > > Betreff: Re: su su- sudo dont work
> > >
> > >
> > >
> > > On Sun, Jan 21, 2024 at 4:07 PM Schwibinger Michael 
> > > mailto

Re: [Solved] LXDE ― Autorun on Every Start up — Applications, Commands, Scripts

2023-05-25 Thread Vincent Lefevre
On 2023-05-18 16:53:39 +0700, Max Nikulin wrote:
> On 18/05/2023 14:38, Susmita/Rajib wrote:
> > Nearly none relevant on the internet:
> > https://www.google.com/search?q=lxde+docu
> > 
> > Forums isn't very informative:
> > https://forum.lxde.org/
> > 
> > So much wasted efforts all around!
> 
> Your internet is rather useless. Mine is much better:
> 
> https://wiki.archlinux.org/title/LXDE

Yes, wiki.archlinux.org often contains interesting information,
which applies to Debian.

-- 
Vincent Lefèvre  - Web: 
100% accessible validated (X)HTML - Blog: 
Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)



Re: [Solved] LXDE ― Autorun on Every Start up — Applications, Commands, Scripts

2023-05-18 Thread Max Nikulin

On 18/05/2023 14:38, Susmita/Rajib wrote:

Nearly none relevant on the internet:
https://www.google.com/search?q=lxde+docu

Forums isn't very informative:
https://forum.lxde.org/

So much wasted efforts all around!


Your internet is rather useless. Mine is much better:

https://wiki.archlinux.org/title/LXDE

3.2 Autostart

LXDE implements XDG Autostart

...





[Solved] LXDE ― Autorun on Every Start up — Applications, Commands, Scripts

2023-05-18 Thread Susmita/Rajib
Solution at:
https://lists.debian.org/debian-user/2023/05/msg00789.html

Nearly no documentation exists on LXDE:
https://wiki.lxde.org/en/

Nearly none relevant on the internet:
https://www.google.com/search?q=lxde+docu

Forums isn't very informative:
https://forum.lxde.org/

So much wasted efforts all around!

Best wishes,
Rajib B



Re: Commands service and systemctl.

2023-04-16 Thread David Wright
On Sun 16 Apr 2023 at 10:47:21 (+0200), Michel Verdier wrote:
> Le 16 avril 2023 David Wright a écrit :
> 
> > systemd-sysv-install. AFAICT from ls, the only /e/i.d/ script I use
> > is anacron, and I don't think systemd will ever write a unit for that.
> 
> anacron is launched from systemd
> /lib/systemd/system/anacron.service
> /lib/systemd/system/anacron.timer

Yes, my fault for not looking more carefully. I may well have poked
around anacron in the meantime. So I checked on another machine and
realised I'd overlooked the two that are used: exim4 and hddtemp
(run automagically, not by me). I hadn't heard of hddtemp, but inxi
pulls it in.

Cheers,
David.



Re: Commands service and systemctl.

2023-04-16 Thread Brad Rogers
On Sun, 16 Apr 2023 10:47:21 +0200
Michel Verdier  wrote:

Hello Michel,

>anacron is launched from systemd
>/lib/systemd/system/anacron.service
>/lib/systemd/system/anacron.timer

Unless;


anacron (2.3-36) unstable; urgency=medium

  If you run Debian testing/unstable and ever installed anacron 2.3-33 on
  a systemd based system, then anacron will no longer be enabled and the
  daily/weekly/monthly cron jobs will not be run until it is.



I'm sure most people affected by the issue (I was one of them) have now
corrected it.  However, just in case, here's how to find out if you are
affected and the solution;



  To see if a system is affected you can use these commands:

zgrep -i anacron.*2.3-33 /var/log/apt/history.log*
systemctl status anacron.service anacron.timer

  To re-enable anacron you can use these commands:

sudo systemctl enable anacron.service anacron.timer
sudo systemctl start anacron.service anacron.timer


Credit to: Lance Lin  Wed, 11 Jan 2023 21:15:22 +0700
(who included the above as part of an anacron update)

-- 
 Regards  _   "Valid sig separator is {dash}{dash}{space}"
 / )  "The blindingly obvious is never immediately apparent"
/ _)rad   "Is it only me that has a working delete key?"
Don't worry about tomorrow
Live For Today - Lords of the New Church


pgpiX1GpGHQqt.pgp
Description: OpenPGP digital signature


Re: Commands service and systemctl.

2023-04-16 Thread Michel Verdier
Le 16 avril 2023 David Wright a écrit :

> systemd-sysv-install. AFAICT from ls, the only /e/i.d/ script I use
> is anacron, and I don't think systemd will ever write a unit for that.

anacron is launched from systemd
/lib/systemd/system/anacron.service
/lib/systemd/system/anacron.timer



Re: Commands service and systemctl.

2023-04-15 Thread David Wright
On Fri 14 Apr 2023 at 21:01:30 (-0700), pe...@easthope.ca wrote:
> From: David Wright 
> Date: Fri, 14 Apr 2023 11:12:18 -0500
> > man 8 service
> 
> "SERVICE(8) ...
>  ...
> service  runs  a System V init script or systemd unit ..."
> 
> Initial release of System V was in 1983.  Initial release of systemd
> was in 2010.  Probably service predates systemd.

I'm not sure what you're reading into that. The bullseye manpage has
a copyright date of 2006 (Red Hat). But if we look at service itself,
which is a script, we can see that the ?earliest Debian version was
written in 2004 by our very own John Hasler, for sarge through lenny,
by which time the version we have now, I think, joins it, and replaces
it in squeeze.

As far as I can ascertain, I've never installed a package containing
/usr/sbin/service until it was moved into init-system-helpers in
stretch, and made a dependency of init.

> > service passes COMMAND  and OPTIONS to the init script unmodified.
> > For systemd units, start,  stop, status, and reload are passed through
> > to their systemctl/initctl equivalents.
> 
> For start, stop & etc. systemctl is more direct than service.  Might be
> some functionality from service not available from systemctl.  Have to
> dig deeper for that.

For systemctl, service is a wrapper, so I don't see how it would have
more functionality.

I can see why a script might use service to save knowing which init
system was being used to control a package, but other than that,
I can't see why one wouldn't just use the appropriate command for
each service.

> No mention that service will be outmoded by systemctl but appears so.

I don't see any evidence for that. Besides, if you decide to use
sysvinit or some other init system, why would you want to use
systemctl for anything?

Or perhaps you're talking about controlling /etc/init.d scripts on
a systemd system. AFAIK, systemctl does that tranparently through
systemd-sysv-install. AFAICT from ls, the only /e/i.d/ script I use
is anacron, and I don't think systemd will ever write a unit for that.

So I think I can safely say that I've never run service, wittingly or
unwittingly, in the decade or more that it was around. (Sorry, John.)

> > ... rather than a wiki webpage.
> 
> The table in https://en.wikipedia.org/wiki/Iproute2 is comprehensive
> and direct. Note heading "Utilities obsoleted ...".

So you asked, "Does the relationship between service and systemctl
parallel that between ifconfig and ip?", to which I would answer no.
AFAIK, while not obsolete, net-tools has been deprecated for years,
and can't be used for many tasks that ip can perform.

OTOH, service is designed to handle sysvinit scripts (and ones for
other init systems), and those init systems are still in active use.

> > ... wiki ...
> 
> Any J. Doe can correct an error in a wiki.  In many (most?) man pages
> deficiencies and errors endure.

But I don't know what the systemd wiki has to do with the service
command? You said it yourself: … many occurrences of "service",
none referring to the service command.

Cheers,
David.



Re: Commands service and systemctl.

2023-04-15 Thread Anssi Saari
pe...@easthope.ca writes:

> Does the relationship between service and systemctl parallel that
> between ifconfig and ip? service is a legacy command?

I guess that's one way of putting it.

Simply put, the systemctl command is for controlling systemd services.
The service is for running SysV init scripts.



Re: Commands service and systemctl.

2023-04-15 Thread Max Nikulin

On 14/04/2023 22:05, peter wrote:


https://en.wikipedia.org/wiki/Systemd has many occurrences of
"service", none referring to the service command.


See systemd.unit(5). Besides services, systemd has sockets, timers and
other unit types.


For several somethings, the result of command,
service something COMMAND
approximates the result of
systemctl COMMAND something.service
although systemctl might be more powerful.


Systemd may generate service units for scripts in /etc/init.d that do
not have their .service files. When systemd is running than the service
command should delegate operation to systemd that tracks states of
system services. So systemctl is native and more powerful in such case.

When SysV init is used than systemctl is not available. There are
even more subtle cases:

https://www.debian.org/doc/manuals/debian-handbook/unix-services.en.html
The Debian Administrator's Handbook
Chapter 9. Unix Services
9.1.2. The System V init system

DEBIAN POLICY Restarting services

The maintainer scripts for Debian packages will sometimes restart
certain services to ensure their availability or get them to take
certain options into account. The command that controls a service —
service service operation — doesn't take runlevel into consideration,
assumes (wrongly) that the service is currently being used, and may thus
initiate incorrect operations (starting a service that was deliberately
stopped, or stopping a service that is already stopped, etc.). Debian
therefore introduced the invoke-rc.d program: this program must be used
by maintainer scripts to run services initialization scripts and it will
only execute the necessary commands. Note that, contrary to common
usage, the .d suffix is used here in a program name, and not in a
directory. 


A specific init script might support operation that systemd is not aware 
of. I do think that you are fighting with portability issues, so use 
tool native to running init system.





Re: Commands service and systemctl.

2023-04-14 Thread peter

To: debian-user@lists.debian.org
In-reply-to: 
References:  


Subject: Re: Commands service and systemctl.

From: David Wright 
Date: Fri, 14 Apr 2023 11:12:18 -0500

man 8 service


"SERVICE(8) ...
 ...
service  runs  a System V init script or systemd unit ..."

Initial release of System V was in 1983.  Initial release of systemd
was in 2010.  Probably service predates systemd.


service passes COMMAND  and OPTIONS to the init script unmodified.
For systemd units, start,  stop, status, and reload are passed through
to their systemctl/initctl equivalents.


For start, stop & etc. systemctl is more direct than service.  Might be
some functionality from service not available from systemctl.  Have to
dig deeper for that.

No mention that service will be outmoded by systemctl but appears so.


... rather than a wiki webpage.


The table in https://en.wikipedia.org/wiki/Iproute2 is comprehensive
and direct. Note heading "Utilities obsoleted ...".


... wiki ...


Any J. Doe can correct an error in a wiki.  In many (most?) man pages
deficiencies and errors endure.

  ... p.



Re: Commands service and systemctl.

2023-04-14 Thread davidson

On Fri, 14 Apr 2023 to...@tuxteam.de wrote:

On Fri, Apr 14, 2023 at 11:12:18AM -0500, David Wright wrote:

[...]


How about consulting   man 8 service   rather than a wiki webpage.


Reading man pages is cheating ;-)


[Humor detected.]

If that were so, then consulting the corresponding Wikipedia article,
*instead of* the manual, would be like trusting a collection of
completely unaccountable strangers to cheat on your behalf.

Probably a fine strategy for someone who really likes surprises.

--
Hackers are free people. They are like artists. If they are in a good
mood, they get up in the morning and begin painting their pictures.
-- Vladimir Putin



Re: Commands service and systemctl.

2023-04-14 Thread tomas
On Fri, Apr 14, 2023 at 07:46:04PM +0100, Brian wrote:
> On Fri 14 Apr 2023 at 18:25:43 +0200, to...@tuxteam.de wrote:
> 
> > On Fri, Apr 14, 2023 at 11:12:18AM -0500, David Wright wrote:
> > 
> > [...]
> > 
> > > How about consulting   man 8 service   rather than a wiki webpage.
> > 
> > Reading man pages is cheating ;-)
> 
> Reading man pages is relatively rare on most OSs. Debian isn't any exception.

This sentence makes almost no sense. Reading by whom? What does
"reading on an OS" mean? (I mean: I usually read them "on" my
computer screen).

There are people who read man pages, there are people who don't.
Around here, we positively try to encourage people to do; free
software, after all, has something to do with empowerment and all
that.

Cheers
-- 


signature.asc
Description: PGP signature


Re: Commands service and systemctl.

2023-04-14 Thread davidson

On Fri, 14 Apr 2023 David Wright wrote:

On Fri 14 Apr 2023 at 08:05:38 (-0700), pe...@easthope.ca wrote:


https://en.wikipedia.org/wiki/Systemd has many occurrences of
"service", none referring to the service command.

For several somethings, the result of command,
service something COMMAND
approximates the result of
systemctl COMMAND something.service
although systemctl might be more powerful.

Does the relationship between service and systemctl parallel that
between ifconfig and ip? service is a legacy command?


How about consulting   man 8 service   rather than a wiki webpage.


More elaborately: Before searching the web (for topics of this sort),
consider checking your local system's documentation.

Local resources are often more relevant. And if you have interest in a
topic, then it is good to discover what resources exist on the system
you actually use:

List manual pages whose title is the term:

 $ man -f locale # equivalently, "whatis locale"
 locale (7)   - description of multilanguage support
 locale (1)   - get locale-specific information
 locale (5)   - describes a locale definition file
 locale (3perl)   - Perl pragma to use or avoid POSIX locales for built-in 
operations

List manual pages that employ the term:

 $ man -k locale # equivalently, "apropos locale"
 duplocale (3)- duplicate a locale object
 Encode::Locale (3pm) - Determine the locale encoding
 ExtUtils::MakeMaker::Locale (3perl) - bundled Encode::Locale
 freelocale (3)   - create, modify, and free a locale object
 I18N::Collate (3perl) - compare 8-bit scalar data according to the current 
locale
 I18N::Langinfo (3perl) - query locale information
 legacy_coding (3ncurses) - override locale-encoding checks
 locale (1)   - get locale-specific information
 locale (3perl)   - Perl pragma to use or avoid POSIX locales for built-in 
operations
 locale (5)   - describes a locale definition file
 locale (7)   - description of multilanguage support
 locale-gen (8)   - generates localisation files from templates
 locale.conf (5)  - Configuration file for locale settings
 locale.gen (5)   - Configuration file for locale-gen
 Locale::gettext (3pm) - message handling functions
 Locale::Maketext (3perl) - framework for localization
 Locale::Maketext::Cookbook (3perl) - recipes for using Locale::Maketext
 Locale::Maketext::Guts (3perl) - Deprecated module to load Locale::Maketext 
utf8 code
 Locale::Maketext::GutsLoader (3perl) - Deprecated module to load 
Locale::Maketext utf8 code
 Locale::Maketext::Simple (3perl) - Simple interface to 
Locale::Maketext::Lexicon
 Locale::Maketext::TPJ13 (3perl) - - article about software localization
 localeconv (3)   - get numeric formatting information
 localectl (1)- Control the system locale and keyboard layout settings
 localedef (1)- compile locale definition files
 luit (1) - Locale and ISO 2022 support for Unicode terminals
 lxterm (1)   - locale-sensitive wrapper for xterm
 MB_CUR_MAX (3)   - maximum length of a multibyte character in the current 
locale
 MB_LEN_MAX (3)   - maximum multibyte length of a character across all 
locales
 newlocale (3)- create, modify, and free a locale object
 nl_langinfo (3)  - query language and locale information
 nl_langinfo_l (3)- query language and locale information
 org.freedesktop.locale1 (5) - The D-Bus interface of systemd-localed
 perllocale (1)   - Perl locale handling (internationalization and 
localization)
 setlocale (3)- set the current locale
 strcoll (3)  - compare two strings using the current locale
 systemd-localed (8)  - Locale bus mechanism
 systemd-localed.service (8) - Locale bus mechanism
 Unicode::Collate::Locale (3perl) - Linguistic tailoring for DUCET via 
Unicode::Collate
 update-locale (8)- Modify global locale settings
 use_legacy_coding (3ncurses) - override locale-encoding checks
 uselocale (3)- set/get the locale for the calling thread
 validlocale (8)  - Test if a given locale is available
 x-terminal-emulator (1) - locale-sensitive wrapper for xterm
 XLocaleOfFontSet (3) - obtain fontset information
 XLocaleOfIM (3)  - open, close, and obtain input method information
 XLocaleOfOM (3)  - open output methods
 XrmLocaleOfDatabase (3) - retrieve and store resource databases
 XSetLocaleModifiers (3) - determine locale support and configure locale 
modifiers
 XSupportsLocale (3)  - determine locale support and configure locale modifiers

--
Hackers are free people. They are like artists. If they are in a good
mood, they get up in the morning and begin painting their pictures.
-- Vladimir Putin



Re: Commands service and systemctl.

2023-04-14 Thread tomas
On Fri, Apr 14, 2023 at 11:12:18AM -0500, David Wright wrote:

[...]

> How about consulting   man 8 service   rather than a wiki webpage.

Reading man pages is cheating ;-)

Cheers
-- 
t


signature.asc
Description: PGP signature


Re: Commands service and systemctl.

2023-04-14 Thread David Wright
On Fri 14 Apr 2023 at 08:05:38 (-0700), pe...@easthope.ca wrote:
> 
> https://en.wikipedia.org/wiki/Systemd has many occurrences of
> "service", none referring to the service command.
> 
> For several somethings, the result of command,
> service something COMMAND
> approximates the result of
> systemctl COMMAND something.service
> although systemctl might be more powerful.
> 
> Does the relationship between service and systemctl parallel that
> between ifconfig and ip? service is a legacy command?

How about consulting   man 8 service   rather than a wiki webpage.

Cheers,
David.



Commands service and systemctl.

2023-04-14 Thread peter

Hi,

https://en.wikipedia.org/wiki/Systemd has many occurrences of
"service", none referring to the service command.

For several somethings, the result of command,
service something COMMAND
approximates the result of
systemctl COMMAND something.service
although systemctl might be more powerful.

Does the relationship between service and systemctl parallel that
between ifconfig and ip? service is a legacy command?

Thx,  ... P.



Re: Commands dont work

2023-04-02 Thread Andrew M.A. Cater
On Sun, Apr 02, 2023 at 11:27:15PM -0400, darryl bruton wrote:
> I just rebooted my lenovo ideapad to debian 11 and no commands work or
> cant  get wifi working im stuck on terminal I've tried everything
> (kenneth@debianspiderweb)

First things first:

Did this ideapad run Debian before?
If so - which version - did it work correctly?

If not, how did you install Debian? 
Which image? If you know, where did you get it from??

No commands work - so, you can login?

Really sorry - the list probably needs much more information.

With every good wish, as ever,

Andy Cater 






Commands dont work

2023-04-02 Thread darryl bruton
I just rebooted my lenovo ideapad to debian 11 and no commands work or
cant  get wifi working im stuck on terminal I've tried everything
(kenneth@debianspiderweb)


Re: use of awk instead of complex multielement commands (was Re: 'grep -o -m' (was Re: Can't mount CD image of Win95 game))

2022-12-20 Thread David
On Wed, 21 Dec 2022 at 04:18, Lee  wrote:
> On 12/20/22, David  wrote:

> > $ echo -e '100:CD001\nXXX\n200:CD001' | awk 'BEGIN { FS=":" ; done=0 }
> > /CD001/ && done==0 { print $1 - 50 ; done=1 }'
> > 50
>
> You can do it without flags:
>
> $ echo -e '100:CD001\nXXX\n200:CD001' | awk -F: '/CD001/ { print $1 -
> 50 ; exit }'
> 50

That's better indeed. Thanks for sharing those improvements!
It really is worthwhile to know some basics of 'awk'.



Re: use of awk instead of complex multielement commands (was Re: 'grep -o -m' (was Re: Can't mount CD image of Win95 game))

2022-12-20 Thread Lee
On 12/20/22, David  wrote:
> On Tue, 20 Dec 2022 at 22:04, David  wrote:
>> On Tue, 20 Dec 2022 at 22:02, David  wrote:
>
>> > $ echo -e '100:CD001\n200:CD001' | awk 'BEGIN { FS=":" } /CD001/ &&
>> > NR==1 { print $1 - 50 }'
>> > 50
>>
>> Oops, my mistake, that's not the solution. Give me another minute and I
>> will post a better one one.
>
> The below does a better job:
> (command should be all on one line)
>
> $ echo -e '100:CD001\nXXX\n200:CD001' | awk 'BEGIN { FS=":" ; done=0 }
> /CD001/ && done==0 { print $1 - 50 ; done=1 }'
> 50

You can do it without flags:

$ echo -e '100:CD001\nXXX\n200:CD001' | awk -F: '/CD001/ { print $1 -
50 ; exit }'
50



Re: use of awk instead of complex multielement commands (was Re: 'grep -o -m' (was Re: Can't mount CD image of Win95 game))

2022-12-20 Thread Stefan Monnier
> Not that that is always important. But I just commented today
> because so often 'awk' is ignored as if its only capability is 'print $1'
>  when in fact it is actually very powerful but neglected.

FWIW, `sed` can also do that job.  Tho the subtraction part would take
a lot more work (`sed` doesn't know how to subtract, so you'd have to
write a chunk of `sed` code which implements subtraction by hand.
A fun exercise for the masochists out there who like to write code for
Turing machines).


Stefan



Re: use of awk instead of complex multielement commands (was Re: 'grep -o -m' (was Re: Can't mount CD image of Win95 game))

2022-12-20 Thread David
On Tue, 20 Dec 2022 at 22:04, David  wrote:
> On Tue, 20 Dec 2022 at 22:02, David  wrote:

> > $ echo -e '100:CD001\n200:CD001' | awk 'BEGIN { FS=":" } /CD001/ &&
> > NR==1 { print $1 - 50 }'
> > 50
>
> Oops, my mistake, that's not the solution. Give me another minute and I
> will post a better one one.

The below does a better job:
(command should be all on one line)

$ echo -e '100:CD001\nXXX\n200:CD001' | awk 'BEGIN { FS=":" ; done=0 }
/CD001/ && done==0 { print $1 - 50 ; done=1 }'
50

Still quite clean and obvious for a one liner (for folks who know how 'awk'
works), and it will be significantly faster than pipelines and
subshell collections.

Not that that is always important. But I just commented today
because so often 'awk' is ignored as if its only capability is 'print $1'
 when in fact it is actually very powerful but neglected.



Re: use of awk instead of complex multielement commands (was Re: 'grep -o -m' (was Re: Can't mount CD image of Win95 game))

2022-12-20 Thread David
On Tue, 20 Dec 2022 at 22:02, David  wrote:

> $ echo -e '100:CD001\n200:CD001' | awk 'BEGIN { FS=":" } /CD001/ &&
> NR==1 { print $1 - 50 }'
> 50

Oops, my mistake, that's not the solution. Give me another minute and I
will post a better one one.



Re: use of awk instead of complex multielement commands (was Re: 'grep -o -m' (was Re: Can't mount CD image of Win95 game))

2022-12-20 Thread David
On Tue, 20 Dec 2022 at 21:53, The Wanderer  wrote:
> On 2022-12-20 at 05:37, David wrote:
> > On Tue, 20 Dec 2022 at 21:10, The Wanderer  wrote:
> >> On 2022-12-20 at 02:51, Thomas Schmitt wrote:

> >>> This contradicts the promises of man grep about option -m.

> >> It does seem to, at least at a glance - but I think I've figured
> >> out what's going on, and it's actually consistent with the option
> >> set you gave.
> >
> > [...]
> >
> > Hi,
> >
> > Slightly offtopic rambling ...
> >
> > I haven't looked at the 'grep' part of the above expression, but
> > I assume that its output lines look something like:
> > 100:CD001
> >
> > If that is the case, then awk does not need any assistance
> > from 'expr' or 'sed' (and even not from 'grep' if we were not
> > searching a binary file).
> >
> > Short demo:
> > $ echo 100:CD001 | awk 'BEGIN { FS=":" } /CD001/ { print $1 - 50 }'
> > 50
>
> If you replace the "echo 100:CD001" with "echo -e
> '100:CD001\n200:CD001'" (not sure if that syntax is portable to all
> shells, but it works in my version of bash), this does print '50' and
> '150' on consecutive lines - which (if I'm not mistaken) matches the
> behavior of the original pipeline, but is not what is actually desired
> here.
>
> > I only write this because I just magine how poor old 'awk' feels:
> > "don't embed me in this pipelines and subshells and unnecessary
> > commands, I can do all that stuff myself without any help!!".
>
> Because of the above, it looks like a pipeline may still be necessary
> here, to filter it down to just the first number being output. Unless
> awk has another feature that would let us do that limiting internally too?

Fair point. Thanks for noticing my laziness. :)

But 'awk' does indeed have vast powers, that are sadly very overlooked
in modern times:

$ echo -e '100:CD001\n200:CD001' | awk 'BEGIN { FS=":" } /CD001/ &&
NR==1 { print $1 - 50 }'
50

And I'm not anything like an 'awk' expert.

I just like to share what little knowledge I have because it is a bit
sad when cool tools fall out of fashion.



use of awk instead of complex multielement commands (was Re: 'grep -o -m' (was Re: Can't mount CD image of Win95 game))

2022-12-20 Thread The Wanderer
On 2022-12-20 at 05:37, David wrote:

> On Tue, 20 Dec 2022 at 21:10, The Wanderer 
> wrote:
> 
>> On 2022-12-20 at 02:51, Thomas Schmitt wrote:

>>> This contradicts the promises of man grep about option -m.
>>
>> It does seem to, at least at a glance - but I think I've figured
>> out what's going on, and it's actually consistent with the option
>> set you gave.
> 
> [...]
> 
> Hi,
> 
> Slightly offtopic rambling ...
> 
> I haven't looked at the 'grep' part of the above expression, but
> I assume that its output lines look something like:
> 100:CD001
> 
> If that is the case, then awk does not need any assistance
> from 'expr' or 'sed' (and even not from 'grep' if we were not
> searching a binary file).
> 
> Short demo:
> $ echo 100:CD001 | awk 'BEGIN { FS=":" } /CD001/ { print $1 - 50 }'
> 50

If you replace the "echo 100:CD001" with "echo -e
'100:CD001\n200:CD001'" (not sure if that syntax is portable to all
shells, but it works in my version of bash), this does print '50' and
'150' on consecutive lines - which (if I'm not mistaken) matches the
behavior of the original pipeline, but is not what is actually desired
here.

> I only write this because I just magine how poor old 'awk' feels:
> "don't embed me in this pipelines and subshells and unnecessary
> commands, I can do all that stuff myself without any help!!".

Because of the above, it looks like a pipeline may still be necessary
here, to filter it down to just the first number being output. Unless
awk has another feature that would let us do that limiting internally too?

-- 
   The Wanderer

The reasonable man adapts himself to the world; the unreasonable one
persists in trying to adapt the world to himself. Therefore all
progress depends on the unreasonable man. -- George Bernard Shaw



signature.asc
Description: OpenPGP digital signature


Re: Looking for a generic drag and drop gui for custom commands

2020-10-13 Thread Christoph K.
Am Tue, 08 Sep 2020 17:41:55 +0100
schrieb Tixy :

> #
> ~$ cat Desktop/test.desktop 
> [Desktop Entry]
> Encoding=UTF-8
> Version=1.0
> Type=Application
> Terminal=true
> Exec=/home/tixy/test.sh %F
> Name=Test launcher
> Icon=/home/tixy/test.svg
> 
> #

Thanks so much Tixy.

To my shame I have to admit that I was missing the %F (or %U) in my
desktop starter file.

Now with '%F' I can drag and drop, the programm accepts the argument,
but only one. When I give two arguments (select two files from the
desktop, drag and drop them on the starter), xfce will spawn two
instances, even though I used capital '%F'.

I've asked a question in the xfce forums about this:
https://forum.xfce.org/viewtopic.php?pid=60260

> This is what I did to test, including some code to distinguish audio
> files from extension. (The 'file' command would probably be best for
> testing file type properly, never used this though.)

Thanks for your audio/video code, but I *really* want a gui that will
handle stuff in a more generic way. Your example inpired me to "auto
sort" the arguments if there are multiple that need to be in exact order.
That would be a super feature for the really lazy "grab all - drop all"
users ;-)

Actually I've got the basic idea implemented already (using Python/QT).
The GUI lets me select the task from a list (by files in a configuration
directory) and load the "command template" from that file. The program
will then substitue the placeholders with my drag and drop arguments.

For now I can combine/split video files and also upload files to a server
using scp and interactivly ask for a password (spawned a terminal running
bash). And of course I have a "hello argument" test ;-)

There are plenty of ideas how to improve the program. The source code is
still quite dirty (it's more a proof of concept at the moment). But I
might decided to release it in case some of my friends find it useful ;-)

Best regards,
Christoph



Re: Why does Debian not include POSIX-specified commands like bc and ed by default?

2020-09-16 Thread David Wright
On Sat 12 Sep 2020 at 07:41:19 (-0500), Nate Bargmann wrote:
> * On 2020 12 Sep 02:06 -0500, Lone Learner wrote:
> > POSIX.1-2001 Utilities[1] and POSIX.1-2008 Utilities[2] both list the
> > commands "bc" and "ed" to be part of POSIX.
> > 
> > Yet, in a brand new Debian installation (version 10 for example),
> > these commands are missing by default:
> > 
> > […]
> > 
> > Why does Debian not include these commands by default?
> 
> It's likely because the focus of the Debian Project is not that of
> shipping a strict POSIX compliant system out of the box.
> 
> > Of course, I can install them with "apt-get" and I did that.
> > 
> > apt-get install bc ed
> 
> I believe that 'apt' is preferred over "apt-get" these days.  Simple
> "apt" works well for me.

Some might prefer it for interactive use, but apt-get has a more
stable command line interface, so is better for scripting when,
say, installing all one's preferred packages on a new system.

Cheers,
David.



Re: Why does Debian not include POSIX-specified commands like bc and ed by default?

2020-09-12 Thread Nate Bargmann
* On 2020 12 Sep 02:06 -0500, Lone Learner wrote:
> POSIX.1-2001 Utilities[1] and POSIX.1-2008 Utilities[2] both list the
> commands "bc" and "ed" to be part of POSIX.
> 
> Yet, in a brand new Debian installation (version 10 for example),
> these commands are missing by default:
> 
> $ bc
> bash: bc: command not found
> $ ed
> bash: ed: command not found
> 
> Why does Debian not include these commands by default?

It's likely because the focus of the Debian Project is not that of
shipping a strict POSIX compliant system out of the box.

> Of course, I can install them with "apt-get" and I did that.
> 
> apt-get install bc ed

I believe that 'apt' is preferred over "apt-get" these days.  Simple
"apt" works well for me.

> The "bc" binary is only 87K in size. The entire package including the
> man page and documentation is only 209K in size.
> 
> Similarly the "ed" binary is only 55K in size. The entire package is
> only 93K in size.
> 
> What good reason is there not to include these tiny packages even
> though they are specified in POSIX?

Debian has an opt-in survey of the most used packages/files via the
"popularity-contest" package:

https://popcon.debian.org/

It likely shows that the utilities in question are not used often so why
include something that is seldom used?  Those that need them know how to
install them and packages that depend on them will install them.
Including them  by default apparently does little to further the goals
of the Debian Project.

Of course, as one interested in Debian, you are free to create your own
spin that is as POSIX compliant as you can make it.

Good luck!

- Nate

-- 

"The optimist proclaims that we live in the best of all
possible worlds.  The pessimist fears this is true."

Web: https://www.n0nb.us
Projects: https://github.com/N0NB
GPG fingerprint: 82D6 4F6B 0E67 CD41 F689 BBA6 FB2C 5130 D55A 8819



signature.asc
Description: PGP signature


Re: Why does Debian not include POSIX-specified commands like bc and ed by default?

2020-09-12 Thread Alex Mestiashvili
On 9/12/20 9:05 AM, Lone Learner wrote:
> POSIX.1-2001 Utilities[1] and POSIX.1-2008 Utilities[2] both list the
> commands "bc" and "ed" to be part of POSIX.
> 
> Yet, in a brand new Debian installation (version 10 for example),
> these commands are missing by default:
> 
> $ bc
> bash: bc: command not found
> $ ed
> bash: ed: command not found
> 
> Why does Debian not include these commands by default? Of course, I
> can install them with "apt-get" and I did that.
> 
> apt-get install bc ed
> 
> The "bc" binary is only 87K in size. The entire package including the
> man page and documentation is only 209K in size.
> 
> Similarly the "ed" binary is only 55K in size. The entire package is
> only 93K in size.
> 
> What good reason is there not to include these tiny packages even
> though they are specified in POSIX?
> 
> [1]: https://pubs.opengroup.org/onlinepubs/009695399/idx/utilities.html
> 
> [2]: https://pubs.opengroup.org/onlinepubs/9699919799/idx/utilities.html
> 

Why should it include? POSIX is just a standard and Debian is even not POSIX
compliant AFAIK :) Also the certification is kind of costly.
But looking from the technical point of view, obviously none of reverse
dependencies of ed or bc are installed on your system and thus theses packages
are not needed. See apt-cache rdepends ed for example.

Best,
Alex



Re: Why does Debian not include POSIX-specified commands like bc and ed by default?

2020-09-12 Thread Fabrice Bauzac
12 sept. 2020 09:06:19 Lone Learner :

> Why does Debian not include these [posix] commands by default?
> 
I guess many debian users don't care about these commands, so it would be rude 
to impose something wanted by only a part of the users.  And there's the case 
of tiny embedded scarce systems too. If posix compliance is needed, these 
packages (and maybe others) can be easily installed, though an additional 
POSIXLY_CORRECT global setting would need to be done also. Maybe we could 
decide to create a package called "posix" that woult depend on all of them, if 
really needed and someone cares to spend time on that. But if you need to use 
software that need e.g. bc, the package certainly already depends on bc anyway.

Best regards
Fabrice



Why does Debian not include POSIX-specified commands like bc and ed by default?

2020-09-12 Thread Lone Learner
POSIX.1-2001 Utilities[1] and POSIX.1-2008 Utilities[2] both list the
commands "bc" and "ed" to be part of POSIX.

Yet, in a brand new Debian installation (version 10 for example),
these commands are missing by default:

$ bc
bash: bc: command not found
$ ed
bash: ed: command not found

Why does Debian not include these commands by default? Of course, I
can install them with "apt-get" and I did that.

apt-get install bc ed

The "bc" binary is only 87K in size. The entire package including the
man page and documentation is only 209K in size.

Similarly the "ed" binary is only 55K in size. The entire package is
only 93K in size.

What good reason is there not to include these tiny packages even
though they are specified in POSIX?

[1]: https://pubs.opengroup.org/onlinepubs/009695399/idx/utilities.html

[2]: https://pubs.opengroup.org/onlinepubs/9699919799/idx/utilities.html



Re: Looking for a generic drag and drop gui for custom commands

2020-09-08 Thread David Christensen

On 2020-09-08 05:16, Christoph K. wrote:


David Christensen wrote:



I'll probably go with the QT GUI Framework with either C++ or Python as
programming language.


Those sound like plausible choices.



Will the app include accessibility  features?  Privacy?  Security?


No.


That response may not be compatible with releasing the software or using 
external development infrastructure.



But if you keep it personal use only, many issues go away.



Will you use any external development infrastructure (e.g SourceForge,
GitHub).


I'm not planning to do that, but if a lot of people find my command-gui
useful, I might do that. Are you interested? ;-)


I have come to a realization:

Moore's Law -- "The king is dead!".

Amdahl's Law -- "Long live the new king!".


The future is concurrent distributed programming.


My preferred tool has been Perl for 20+ years.  I have been struggling 
with writing multi-threaded apps, libraries, and frameworks in Perl for 
a several years now.  Distributed execution will be a whole new Odyssey. 
 If and when I give up, Erlang is at the top of my list.



Choose your tools carefully.


David



Re: Looking for a generic drag and drop gui for custom commands

2020-09-08 Thread Charles Curley
On Mon, 7 Sep 2020 22:43:37 +0200
"Christoph K."  wrote:

> I'd like to "automate" a couple of tasks that I (until now) do on the
> command line manually. Examples include splitting of video files using
> ffmpeg, run backups with specific parameters, display checksums(md5),
> etc.
> 
> I'm tired of typing the same long commands that I often need to look
> up in my wiki and just replace one or two parameters, usually just
> the file names.

Is there any reason it has to be a GUI tool? Much of what you want is
already in BASH.

To retrieve past command lines ready for editing and re-execution,
CTL-R.

To retrieve past command lines and edit them on the fly, FC.

http://charlescurley.com/blog/posts/2019/Aug/02/bash-line-editing/

-- 
Does anybody read signatures any more?

https://charlescurley.com
https://charlescurley.com/blog/



Re: Looking for a generic drag and drop gui for custom commands

2020-09-08 Thread Tixy
On Tue, 2020-09-08 at 17:41 +0100, Tixy wrote:
[...]
> You don't have to rely on the GUIs default terminal. If you set
> "Terminal=false" in the .desktop file you can launch your script how
> you want, e.g. I've used something...
> 
> Exec=lxterminal --geometry=80x30 -e "sh -c /my/script"
> 

I've just realised that may not work for you as the freedesktop spec
[1] says

"Field codes must not be used inside a quoted argument, the result of
field code expansion inside a quoted argument is undefined."

So it may not work for you using %F to specify passing multiple files
to your script like:

Exec=lxterminal --geometry=80x30 -e "sh -c /my/script %F"

[1] 
https://specifications.freedesktop.org/desktop-entry-spec/latest/ar01s07.html

-- 
Tixy



Re: Looking for a generic drag and drop gui for custom commands

2020-09-08 Thread Tixy
On Tue, 2020-09-08 at 17:15 +0200, Christoph K. wrote:
[...]
> It doesn't work for me. Am I doing something wrong?
> 
> Anyway, this wouldn't be an optimal solution. In some cases I need to
> pass multiple arguments in a specific order. For example an audio and
> video file that should be combined into a single .mp4 file.

It works for me, though I found that multiple files launches multiple
copies of the script, one for each file. To get around that you can use
and explicit %F in the desktop file's Exec command, see [1].

This is what I did to test, including some code to distinguish audio
files from extension. (The 'file' command would probably be best for
testing file type properly, never used this though.)

#
~$ cat Desktop/test.desktop 
[Desktop Entry]
Encoding=UTF-8
Version=1.0
Type=Application
Terminal=true
Exec=/home/tixy/test.sh %F
Name=Test launcher
Icon=/home/tixy/test.svg

#
~$ cat test.sh
#!/bin/bash

if [ -z "$1" ] || [ -z "$2" ]
then
echo Expected two files
sleep 2
exit 1
fi

audiofile=$1
videofile=$2

if [ "${videofile##*.}" = "mp3" ]
then
# files in wrong order, swap them
audiofile=$2
videofile=$1
fi

echo Audio=$audiofile Video=$videofile

sleep 2

#
~$ touch audio.mp3
~$ touch video.avi
~$ ./test.sh video.avi audio.mp3
Audio=audio.mp3 Video=video.avi

#

If using the GUI file manager I highlight the audio.mp3 and video.avi
files and drag them onto "Test launcher" then I get a terminal window
open up with the same output as I got above using the commandline.

You don't have to rely on the GUIs default terminal. If you set
"Terminal=false" in the .desktop file you can launch your script how
you want, e.g. I've used something...

Exec=lxterminal --geometry=80x30 -e "sh -c /my/script"

To have my preferred terminal at a preferred size,

[1] 
https://specifications.freedesktop.org/desktop-entry-spec/latest/ar01s07.html

-- 
Tixy




Re: Looking for a generic drag and drop gui for custom commands

2020-09-08 Thread Christoph K.
Am Tue, 08 Sep 2020 13:40:03 +0100
schrieb Tixy :

> > Put the (ffmpeg) command in a script and run it with argument/s ?
> 
> And run the script from a 'desktop entry' [1] and your desktop GUI may
> let you run it with file arguments just by dropping files onto it. You
> can put these 'desktop' files on you desktop or in there own directory
> you can open when you have tasks to do.

That ssound like a good idea and close to what I want to achieve, but it
doesn't seem to work in XFCE. When I drop some a file on a desktop file
("starter") that is associated with my testdnd.sh script, the script
doesn't get any input:

testdnd.sh
#!/bin/bash

echo 'testdnd.sh'

echo 'First two arguments:'
echo -n '$1: '
echo $1
echo -n '$2: '
echo $2

echo 'Standard Input: '
while read line
do
  echo "$line"
done < "${VAR:-/dev/stdin}"

read
end

When I drag a text file on the starter / desktop file, the mouse cursor
displays a '+' Symbol, as if the starter accepts that file. But when I
drop it, I get neither parameters nor standard input (that's what I
expect).

output
testdnd.sh
First two arguments:
$1: 
$2: 
Standard Input: 
end

In contrast, when I call the script from the command line, it gives me
both, parameters and stdin:


$ cat test.txt | ./testdnd.sh a b
testdnd.sh
First two arguments:
$1: a
$2: b
Standard Input: 
This is
a multiline
text file



> The above works for me with LXDE. Though you don't get to edit
> parameters to you scripts, just pass files to them.

It doesn't work for me. Am I doing something wrong?

Anyway, this wouldn't be an optimal solution. In some cases I need to
pass multiple arguments in a specific order. For example an audio and
video file that should be combined into a single .mp4 file.

Christoph



Re: Looking for a generic drag and drop gui for custom commands

2020-09-08 Thread Tixy
On Tue, 2020-09-08 at 13:40 +0100, Tixy wrote:
> And run the script from a 'desktop entry' [1] and your desktop GUI may
> let you run it with file arguments just by dropping files onto it. You
> can put these 'desktop' files on you desktop or in there own directory
> you can open when you have tasks to do.
> 
> The above works for me with LXDE. Though you don't get to edit
> parameters to you scripts, just pass files to them.

Or get the 'desktop' file to run the script in a terminal and use shell
scripting to ask for parameters. E.g. a 'video-resize' script could ask
to width and height with a default to using your most common
requirement.

-- 
Tixy 



Re: Looking for a generic drag and drop gui for custom commands

2020-09-08 Thread Tixy
On Tue, 2020-09-08 at 13:05 +0100, mick crane wrote:
> On 2020-09-07 21:43, Christoph K. wrote:
> > Dear all,
> > 
> > I'd like to "automate" a couple of tasks that I (until now) do on
> > the
> > command line manually. Examples include splitting of video files
> > using
> > ffmpeg, run backups with specific parameters, display
> > checksums(md5), 
> > etc.
> > 
> > I'm tired of typing the same long commands that I often need to
> > look up
> > in my wiki and just replace one or two parameters, usually just
> > the 
> > file
> > names.
> 
> Put the (ffmpeg) command in a script and run it with argument/s ?

And run the script from a 'desktop entry' [1] and your desktop GUI may
let you run it with file arguments just by dropping files onto it. You
can put these 'desktop' files on you desktop or in there own directory
you can open when you have tasks to do.

The above works for me with LXDE. Though you don't get to edit
parameters to you scripts, just pass files to them.

[1] https://wiki.archlinux.org/index.php/desktop_entries

-- 
Tixy



Re: Looking for a generic drag and drop gui for custom commands

2020-09-08 Thread Christoph K.
Hello David,

Am Tue, 8 Sep 2020 02:57:30 -0700
schrieb David Christensen :

> There are a great many ways to implement graphical user interface 
> applications.  Drag-and-drop support implies good integration with the 
> window manager or desktop environment.  One option is to use a 
> programming language and a GUI library to build a script or executable 
> (e.g. Tcl/Tk, C/GTK).

That's what I'm thinking about.

I'll probably go with the QT GUI Framework with either C++ or Python as
programming language.


> You should define some criteria to narrow the choices.  This is a Debian 
> mailing list, so I assume you want to build and run apps on Debian using 
> tools packaged on Debian (?).

Yes, mostly. But if there's some nice command line utility that doesn't
ship with Debian (such as stereo tool audio processor), I'll use that as
well. BTW I'm doing a lot of audio / video editing at the moment.


> Do you want to develop and/or deploy on other platforms?

I was primarily aiming at Linux, but you made me realize it would be
useful to have the same applications on other system, e. g. Windows
(which I'm using occasionally). I'll develop on Linux (Debian).


> Will the apps be single-user or multi-user (including 
> yourself on multiple devices)?

Single User. Did you get the idea of what I want to do?
Did you just copy/paste an app development questionaire? ;-)
I'll answer the rest of your questions anyway ...


> Will the app include accessibility  features?  Privacy?  Security?

No.
It'll be just one window that accepts files and folders to drag onto.
The only goal (for now) of this "app" is to execute a single command.


> What license(s) will apply to the app? 

I don't care. Maybe MIT or Public domain.


> Will you use any external development infrastructure (e.g SourceForge, 
> GitHub). 

I'm not planning to do that, but if a lot of people find my command-gui
useful, I might do that. Are you interested? ;-)


> Tell us about your programming knowledge and skills.

I've done similar, more complicated Projects in the past.
Some experience with C/C++, Python, Kivy, wxWidgets, perl, php, etc.


> How much time and money do you want to put into developing the first app?

As little as possible. That's why I asked if there's a similar app
available already. There are many beautiful and useful pieces of software
out in the world. The main reason to ask here on the list is that I
assume people know more about those tools than I do.


> What about apps after that (and how many)?  Are the apps a hobby, or do you 
> want to leverage this into a programmer job and/or commercial venture? 
> And, whatever else comes to mind.

The program is meant to be used by myself – to simplify my life /
workflow. So you could call it a hobby. And I haven't done programming
for a couple of months, which I would like to do now. And I would enjoy to
learn something new (QT in this case).

I've just installed the QT Designer this morning, clicked around for a
couple of minutes and managed to get the window displayed with python
(PyQT / Pyside2). The next step will be to get the drop functionality
working. After that, I will put some predefined command statements in the
list of selectable tasks. Then I'll go for the argument replacement and
with that in place, I have a working tool. Everything else will be "nice
to have". But I'll soon figure out it's annoying to only have predefined
commands, so I will add some configuration file whicht might be editable
from the gui.

That's my plan for now.

Thanks for your support,
Christoph



Re: Looking for a generic drag and drop gui for custom commands

2020-09-08 Thread mick crane

On 2020-09-07 21:43, Christoph K. wrote:

Dear all,

I'd like to "automate" a couple of tasks that I (until now) do on the
command line manually. Examples include splitting of video files using
ffmpeg, run backups with specific parameters, display checksums(md5), 
etc.


I'm tired of typing the same long commands that I often need to look up
in my wiki and just replace one or two parameters, usually just the 
file

names.


Put the (ffmpeg) command in a script and run it with argument/s ?

mick

--
Key ID4BFEBB31



Re: Looking for a generic drag and drop gui for custom commands

2020-09-08 Thread David Christensen

On 9/7/20 1:43 PM, Christoph K. wrote:


I'd like to "automate" a couple of tasks that I (until now) do on the
command line manually. Examples include splitting of video files using
ffmpeg, run backups with specific parameters, display checksums(md5), etc.



My idea is that I'd start up the gui and select a task (e. g. split a
video file). A command line will be loaded (maybe from a config file)
with placeholders for input, output and other parameters.
I will then drag some file on the gui and the filename will be used as a
parameter, in this case as the input file.
Then I will click some run button, which executes the command.
Ideally the output and exit code will be displayed.


There are a great many ways to implement graphical user interface 
applications.  Drag-and-drop support implies good integration with the 
window manager or desktop environment.  One option is to use a 
programming language and a GUI library to build a script or executable 
(e.g. Tcl/Tk, C/GTK).  Another option is to use a stack to deliver an 
application with a web browser interface (e.g. 
LAMP/HTML/CSS/JavaScript).  Another option is to use a RAD/IDE 
environment that expedites one or both of the former and/or provides a 
platform-agnostic platform whose apps can be cross-compiled to many 
platforms (e.g. Delphi, Java, .NET, Unity, LiveCode).  And there are 
more options to choose from, especially if you are wiling to consider 
commercial tools (many of which offer free-as-in-beer editions).



You should define some criteria to narrow the choices.  This is a Debian 
mailing list, so I assume you want to build and run apps on Debian using 
tools packaged on Debian (?).  Do you want to develop and/or deploy on 
other platforms?  Will the apps be single-user or multi-user (including 
yourself on multiple devices)?  Will the app include accessibility 
features?  Privacy?  Security?  What license(s) will apply to the app? 
Will you use any external development infrastructure (e.g SourceForge, 
GitHub).  Tell us about your programming knowledge and skills.  How much 
time and money do you want to put into developing the first app?  What 
about apps after that (and how many)?  Are the apps a hobby, or do you 
want to leverage this into a programmer job and/or commercial venture? 
And, whatever else comes to mind.



David



Looking for a generic drag and drop gui for custom commands

2020-09-07 Thread Christoph K.
Dear all,

I'd like to "automate" a couple of tasks that I (until now) do on the
command line manually. Examples include splitting of video files using
ffmpeg, run backups with specific parameters, display checksums(md5), etc.

I'm tired of typing the same long commands that I often need to look up
in my wiki and just replace one or two parameters, usually just the file
names.

So I was thinking about writing an application which will do just what I
want. But then I thought: Maybe someone did that already! ;-)

So that's my question:

Is there a kind of generic drag and drop gui for custom commands?

My idea is that I'd start up the gui and select a task (e. g. split a
video file). A command line will be loaded (maybe from a config file)
with placeholders for input, output and other parameters.
I will then drag some file on the gui and the filename will be used as a
parameter, in this case as the input file.
Then I will click some run button, which executes the command.
Ideally the output and exit code will be displayed.

Any hints will be appreciated.

Thanks,
Christoph



Re: bash-completion pros/cons (was: Re: Need commands)

2020-06-18 Thread l0f4r0
Hi,

18 juin 2020 à 09:00 de david...@freevolt.org:

> On Tue, 16 Jun 2020, l0f...@tuta.io wrote:
>
>> 16 juin 2020 à 10:47 de david...@freevolt.org:
>>
>>> I hear some people find bash-completion helpful. Personally, though,
>>> no. Do not want.
>>>
>> Interesting/intriguing point of view.
>>
> I will remember this polite new way to call somebody a weirdo.
>
Don't get me wrong, I just meant that your previous answer aroused my curiosity.
So I wanted to look deeper into it because maybe *I* was the weirdo after all ;p

Thanks & Best regards,
l0f4r0



Re: bash-completion pros/cons (was: Re: Need commands)

2020-06-18 Thread tomas
On Thu, Jun 18, 2020 at 07:25:40AM +, davidson wrote:
> On Tue, 16 Jun 2020, l0f...@tuta.io wrote:

[...]

> >Maybe sometimes completion is not working as it should, nothing is
> >perfect, but globally I think that it saves time more than its
> >wastes.
> 
> For those it suits, I am glad the package is available.

Absolutely. Don't get me wrong. I decided it's not /for me/. I'm
still glad it exists and I'm happy it's free.

Cheers
-- t


signature.asc
Description: Digital signature


Re: bash-completion pros/cons (was: Re: Need commands)

2020-06-18 Thread davidson

On Tue, 16 Jun 2020, l0f...@tuta.io wrote:
[dd]

16 juin 2020 à 13:23 de wool...@eeg.ccf.org


It's flaky and full of errors.  (Many of these errors end up on the
bash mailing lists as bug reports in bash, but nope, they're from
bash-completion.)  It bloats bash, using a lot of memory, and taking
extra CPU and wall-clock time (may not be noticeable on modern hardware).

That said, many people still find its benefits outweight its problems,
and are quite happy with it.  You get to make your own choice.


Thanks.
Proofreading the final command is not forbidden, right? ^^


That is always a good idea. And I prefer the mistakes that I find, the
ones I correct, and the ones I overlook, to be my own.

Because I learn best from my own mistakes.


Maybe sometimes completion is not working as it should, nothing is
perfect, but globally I think that it saves time more than its
wastes.


For those it suits, I am glad the package is available.


It's probably more a conceptual/philosophical approach here ;)


Agreed.

--
https://news.ycombinator.com/item?id=12518471 alexk already addressed
your concern: your keys, preferably issued by your org's CA (instead
of being generated by you) should be short-lived, oftentimes for the
duration of your "work shift". The tools listed above support this.

Re: bash-completion pros/cons (was: Re: Need commands)

2020-06-18 Thread davidson

On Tue, 16 Jun 2020, l0f...@tuta.io wrote:


16 juin 2020 à 10:47 de david...@freevolt.org:


I hear some people find bash-completion helpful. Personally, though,
no. Do not want.


Interesting/intriguing point of view.


I will remember this polite new way to call somebody a weirdo.


Why would someone not be interested in autocompletion please?


I am perfectly happy with autocompletion in general. Disabling
bash-completion package does not mean one must peck out their bash
command lines verbatim, character-by-character, as one must in grub
rescue shell. Others have also pointed this out.

I use a lot of the autocompletion (and command history) functionality
described in bash(1), under the sections

 * READLINE:Completing
 * READLINE:Commands for Manipulating the History
 * HISTORY EXPANSION

Those functions are agnostic: No matter what particular fragmentary
command presently awaits completion (manual or otherwise), their
behavior does not vary. And their very agnosticism is significant; it
is largely why learning the shape of their behavior, and how to take
advantage of it, has been worth the time and effort.

Now consider the following:

bash(1), section READLINE:Programmable Completion (AKA progcomp)
  [...]
  By default, if a compspec is found, whatever it generates is
  returned to the completion code as the full set of possible
  completions.  The default bash completions are not attempted, and
  the readline default of filename completion is disabled.  If the -o
  bashdefault option was supplied to complete when the compspec was
  defined, the bash default completions are attempted if the compspec
  generates no matches.  If the -o default option was supplied to
  complete when the compspec was defined, readline's default
  completion will be performed if the compspec (and, if attempted, the
  default bash completions) generate no matches.
  [...]

In other words, with progcomp I can (and the bash-completion package
does) lay booby-traps that will override the behavior I've become so
accustomed to.

I might, in specialised context, choose to do this. But when any
exceptional behavior has been specified by myself, then I know who to
blame for the surprises. (And my own mistakes teach me things much
more reliably than the mistakes of others.)

In the shell I'm trying to play a nice orderly game of croquet. If
there are going to be mines under the lawn, I want to install them
myself, carefully.

When I want someone to surprise me there is always NetHack.

--
 \ '   .,
 o O  /  It looks like you're writing a letter!  )
 / Would you like some help?/
  Y : \.__./

Re: bash-completion pros/cons (was: Re: Need commands)

2020-06-16 Thread tomas
On Tue, Jun 16, 2020 at 01:53:59PM +0200, l0f...@tuta.io wrote:

[...]

> Maybe sometimes completion is not working as it should, nothing is perfect, 
> but globally I think that it saves time more than its wastes.

Then just use it and be happy. And just accept that some
(me, among others) are happier without :-)

Yes, I've tried it. Yes, I think it's technically nifty.
But no, it doesn't mesh well with the way I work. Even
if it were bug-free, it wouldn't be "my" thing.

I live by the command line, and there are roughly two classes
of things I do: those I do very often, where history search
is just unbeatable, and those I do rarely. For those I have
a man page open, sometimes a notebook (in Emacs, but I disgress)
to take notes and I proceed slowly.

The top of the first class are candidates for automation and
scripting.

In the first class, I don't need autocompletion, since I know
what I'm doing (heck, my muscle memory nearly knows. In the
second class, autocompletion is a train wreck waiting to happen:
I really *want* to know why each piece is there.

The only really useful autocompletion is actually file path
autocompletion, and I have that without any extra packages.

> It's probably more a conceptual/philosophical approach here ;)

For me it isn't. It is an eminently practical issue.

Cheers
-- t


signature.asc
Description: Digital signature


Re: bash-completion pros/cons (was: Re: Need commands)

2020-06-16 Thread l0f4r0
Hi Greg,

16 juin 2020 à 13:23 de wool...@eeg.ccf.org

> It's flaky and full of errors.  (Many of these errors end up on the
> bash mailing lists as bug reports in bash, but nope, they're from
> bash-completion.)  It bloats bash, using a lot of memory, and taking
> extra CPU and wall-clock time (may not be noticeable on modern hardware).
>
> That said, many people still find its benefits outweight its problems,
> and are quite happy with it.  You get to make your own choice.
>
Thanks.
Proofreading the final command is not forbidden, right? ^^
Maybe sometimes completion is not working as it should, nothing is perfect, but 
globally I think that it saves time more than its wastes.

It's probably more a conceptual/philosophical approach here ;)

Best regards,
l0f4r0



Re: bash-completion pros/cons (was: Re: Need commands)

2020-06-16 Thread Greg Wooledge
On Tue, Jun 16, 2020 at 12:54:58PM +0200, l0f...@tuta.io wrote:
> Hi,
> 
> 16 juin 2020 à 10:47 de david...@freevolt.org:
> 
> > I hear some people find bash-completion helpful. Personally, though,
> > no. Do not want.
> >
> Interesting/intriguing point of view.
> Why would someone not be interested in autocompletion please? 

It's flaky and full of errors.  (Many of these errors end up on the
bash mailing lists as bug reports in bash, but nope, they're from
bash-completion.)  It bloats bash, using a lot of memory, and taking
extra CPU and wall-clock time (may not be noticeable on modern hardware).

That said, many people still find its benefits outweight its problems,
and are quite happy with it.  You get to make your own choice.



Re: Need commands

2020-06-16 Thread mick crane

On 2020-06-16 09:47, davidson wrote:

many thanks
mick
--
Key ID4BFEBB31



bash-completion pros/cons (was: Re: Need commands)

2020-06-16 Thread l0f4r0
Hi,

16 juin 2020 à 10:47 de david...@freevolt.org:

> I hear some people find bash-completion helpful. Personally, though,
> no. Do not want.
>
Interesting/intriguing point of view.
Why would someone not be interested in autocompletion please? 

Best regards,
l0f4r0



Re: Need commands

2020-06-16 Thread davidson

On Sun, 14 Jun 2020, mick crane wrote:


On 2020-06-14 12:42, to...@tuxteam.de wrote:

On Sun, Jun 14, 2020 at 12:23:15PM +0100, mick crane wrote:

On 2020-06-13 19:51, Darac Marjal wrote:
...
>The full list of commands depends on what's installed, but you can
>retrieve that list by opening a terminal and typing:
>
>    compgen -ac

what are these words that begin with the underscore ?

__load_completion
__ltrim_colon_completions
__parse_options
__reassemble_comp_words_by_ref
_allowed_groups
_allowed_users
_available_interfaces
_cd
_cd_devices
_command


I don't have those. Most probably they are shell functions defined for your
session. Just issue the command

  type __load_completion

to shed light on that.

Which package or program defines them is anyone's guess, but you can try
to look into your shell initialization files (i.e. /etc/profile, ~/.bashrc,
all those mentioned in the FILES section of man bash [1]) to learn more.

Cheers

[1] or whatever shell is yours.

-- tomás


I wish I'd never looked now.
so they are functions defined in the actual bash code for other words to get 
the result of ?


Er, they look like shell functions that bash_completion (from package
"bash-completion") defines for the greater glory of Bash
Completionstan.

 $ apt-description bash-completion # Not a real command
 bash-completion - programmable completion for the bash shell
  bash completion extends bash's standard completion behavior to achieve
  complex command lines with just a few keystrokes.  This project was
  conceived to produce programmable completion routines for the most
  common Linux/UNIX commands, reducing the amount of typing sysadmins
  and programmers need to do on a daily basis.
 Homepage: https://github.com/scop/bash-completion

You can read about shell functions in general in the bash man page,
either briefly under section "SHELL GRAMMAR" in subsection "Shell
Function Definitions", or at greater length in the section
"FUNCTIONS".

I hear some people find bash-completion helpful. Personally, though,
no. Do not want.

So, when using a system with bash-completion installed, I disable it
in my own accounts with two steps:

STEP 1

Create a file ~/.config/bash_completion containing the line "shopt -u
progcomp". (If you happen not to have a directory ~/.config already,
create one first.)

 $ echo "# Disable bash-completion" >> ~/.config/bash_completion
 $ echo "shopt -u progcomp" >> ~/.config/bash_completion

This makes /etc/profile.d/bash_completion.sh do nothing when it runs
(other than source your ~/.config/bash_completion), because
/etc/profile.d/bash_completion.sh is polite like that.

In order for this to be effective, the file you create in ~/.config
must have that precise name (with an underscore, not a hyphen), and it
must unset the progcomp shell option (which is what the line "shopt -u
progcomp" does).

/usr/share/doc/bash-completion/README.md.gz explains STEP 1 more
generally like so:

  The `profile.d` script provides a configuration file hook that can
  be used to prevent loading `bash_completion` on per user basis when
  it's installed system wide. To do this:

  1. Turn off programmable completion with `shopt -u progcomp` in
 `$XDG_CONFIG_HOME/bash_completion` (or
 `~/.config/bash_completion` if `$XDG_CONFIG_HOME` is not set)

  2. Turn it back on (for example in `~/.bashrc`) if you want to use
 programmable completion for other purposes.


STEP 2

Examine ~/.bashrc and look for any sections that enable
bash_completion, and comment them out:

# enable programmable completion features (you don't need to enable
# this, if it's already enabled in /etc/bash.bashrc and /etc/profile
# sources /etc/bash.bashrc).
# if [ -f /etc/bash_completion ] && ! shopt -oq posix; then
#. /etc/bash_completion

Both steps are required. The first keeps system-wide profile from
running bash_completion for you. The second keeps your ~/.bashrc from
running it for yourself.

After doing both, start a new bash session and check to see if

 $ typeset -F

still shows presence of the offending functions.

--
https://news.ycombinator.com/item?id=12518471 alexk already addressed
your concern: your keys, preferably issued by your org's CA (instead
of being generated by you) should be short-lived, oftentimes for the
duration of your "work shift". The tools listed above support this.

Re: Need commands

2020-06-15 Thread tomas
On Mon, Jun 15, 2020 at 08:03:05AM -0400, Greg Wooledge wrote:
> On Sun, Jun 14, 2020 at 03:48:19PM +0200, to...@tuxteam.de wrote:
> > OK. My hunch [...]

> Bear in mind that the OP was running Kali, not Debian.  I don't know off
> hand whether Kali makes changes to their bash-completion package, but
> in any event, it's something to keep in mind when responding.

Thanks for the heads-up, I wasn't aware (rough sleep schedule, currently :-/

In any case, my aim was to provide a fishing rod along with the fish ;-)

Cheers
-- t


signature.asc
Description: Digital signature


Re: Need commands

2020-06-15 Thread Greg Wooledge
On Sun, Jun 14, 2020 at 03:48:19PM +0200, to...@tuxteam.de wrote:
> OK. My hunch is that they have something to do with bash autocompletion.
> Since they are functions, not files, it's hard to say which package
> they come from (with on-board means, that is).
> 
> But there are way more powerful off-board means. Enter Debian Code Search:
> 
>   https://codesearch.debian.net/

Bear in mind that the OP was running Kali, not Debian.  I don't know off
hand whether Kali makes changes to their bash-completion package, but
in any event, it's something to keep in mind when responding.



Re: Need commands

2020-06-14 Thread David Wright
On Sat 13 Jun 2020 at 21:23:51 (-0600), Charles Curley wrote:
> -- 
> Does anybody read signatures any more?

On Sat 13 Jun 2020 at 22:36:15 (-0700), Mike McClain wrote:
> 
> --
> Always remember:
> It is a mathematical certainty that half the people
> in this country are below average in intelligence!

If that's meant to be a signature, you should put one space after the --
like the example above.

s/average/median/ is the mathematical certainty. It's a well-known
fact that most people have an above-average number of legs.

Cheers,
David.



Re: Need commands

2020-06-14 Thread tomas
On Sun, Jun 14, 2020 at 01:38:29PM +0100, mick crane wrote:

[...]

> I wish I'd never looked now.

Why? Granted, curiosity kills the cat, they say. But that's what we
hackers and tinkerers thrive on, ain't it?

What's a life without learning?
> so they are functions defined in the actual bash code for other
> words to get the result of ?

OK. My hunch is that they have something to do with bash autocompletion.
Since they are functions, not files, it's hard to say which package
they come from (with on-board means, that is).

But there are way more powerful off-board means. Enter Debian Code Search:

  https://codesearch.debian.net/

Put __load_completion into that little box and... yes, it comes from
the package "bash-completion" (which I explicitly don't install: I
tried it once and didn't like it. Too much magic. But horses for courses,
as they say, too :)

Enjoy
-- tomás


signature.asc
Description: Digital signature


Re: Need commands

2020-06-14 Thread mick crane

On 2020-06-14 12:42, to...@tuxteam.de wrote:

On Sun, Jun 14, 2020 at 12:23:15PM +0100, mick crane wrote:

On 2020-06-13 19:51, Darac Marjal wrote:
...
>The full list of commands depends on what's installed, but you can
>retrieve that list by opening a terminal and typing:
>
>    compgen -ac

what are these words that begin with the underscore ?

__load_completion
__ltrim_colon_completions
__parse_options
__reassemble_comp_words_by_ref
_allowed_groups
_allowed_users
_available_interfaces
_cd
_cd_devices
_command


I don't have those. Most probably they are shell functions defined for 
your

session. Just issue the command

  type __load_completion

to shed light on that.

Which package or program defines them is anyone's guess, but you can 
try
to look into your shell initialization files (i.e. /etc/profile, 
~/.bashrc,
all those mentioned in the FILES section of man bash [1]) to learn 
more.


Cheers

[1] or whatever shell is yours.

-- tomás


I wish I'd never looked now.
so they are functions defined in the actual bash code for other words to 
get the result of ?


mick
--
Key ID4BFEBB31



Re: Need commands

2020-06-14 Thread mick crane

On 2020-06-14 12:42, to...@tuxteam.de wrote:

On Sun, Jun 14, 2020 at 12:23:15PM +0100, mick crane wrote:

On 2020-06-13 19:51, Darac Marjal wrote:
...
>The full list of commands depends on what's installed, but you can
>retrieve that list by opening a terminal and typing:
>
>    compgen -ac

what are these words that begin with the underscore ?

__load_completion
__ltrim_colon_completions
__parse_options
__reassemble_comp_words_by_ref
_allowed_groups
_allowed_users
_available_interfaces
_cd
_cd_devices
_command


I don't have those. Most probably they are shell functions defined for 
your

session. Just issue the command

  type __load_completion

to shed light on that.

Which package or program defines them is anyone's guess, but you can 
try
to look into your shell initialization files (i.e. /etc/profile, 
~/.bashrc,
all those mentioned in the FILES section of man bash [1]) to learn 
more.


Cheers

[1] or whatever shell is yours.

-- tomás


probably then is to do with sshing in to see what this "compgen" was.

mick

--
Key ID4BFEBB31



Re: Need commands

2020-06-14 Thread tomas
On Sun, Jun 14, 2020 at 12:23:15PM +0100, mick crane wrote:
> On 2020-06-13 19:51, Darac Marjal wrote:
> ...
> >The full list of commands depends on what's installed, but you can
> >retrieve that list by opening a terminal and typing:
> >
> >    compgen -ac
> 
> what are these words that begin with the underscore ?
> 
> __load_completion
> __ltrim_colon_completions
> __parse_options
> __reassemble_comp_words_by_ref
> _allowed_groups
> _allowed_users
> _available_interfaces
> _cd
> _cd_devices
> _command

I don't have those. Most probably they are shell functions defined for your
session. Just issue the command

  type __load_completion

to shed light on that.

Which package or program defines them is anyone's guess, but you can try
to look into your shell initialization files (i.e. /etc/profile, ~/.bashrc,
all those mentioned in the FILES section of man bash [1]) to learn more.

Cheers

[1] or whatever shell is yours.

-- tomás


signature.asc
Description: Digital signature


Re: Need commands

2020-06-14 Thread mick crane

On 2020-06-13 19:51, Darac Marjal wrote:
...

The full list of commands depends on what's installed, but you can
retrieve that list by opening a terminal and typing:

    compgen -ac


what are these words that begin with the underscore ?

__load_completion
__ltrim_colon_completions
__parse_options
__reassemble_comp_words_by_ref
_allowed_groups
_allowed_users
_available_interfaces
_cd
_cd_devices
_command

mick

--
Key ID4BFEBB31



Re: Need commands

2020-06-13 Thread Mike McClain
On Sat, Jun 13, 2020 at 02:01:06PM +0300, Teemu Likonen wrote:
> ROHIT SONI [2020-06-13T10:12:06+05:30] wrote:
>
> > I need full commands for 2020.2 gnu/linux rolling kali tty1
>
> List all commands in a terminal program and Bash shell:
>
> ls -l {/usr,}/{s,}bin/; help
>
> --
> /// Teemu Likonen - .-.. http://www.iki.fi/tlikonen/
> // OpenPGP: 4E1055DC84E9DFF613D78557719D69D324539450

Way to go, Mr. Likonen.
Thumbs up.
Mike

--
Always remember:
It is a mathematical certainty that half the people
in this country are below average in intelligence!



Re: Need commands

2020-06-13 Thread Darac Marjal
On 13/06/2020 05:42, ROHIT SONI wrote:
> Hello sir

To whom are you addressing this message? Which particular "sir"? Would
one of the https://www.debian.org/women/ not be suitable?

> I need full commands for 2020.2 gnu/linux rolling kali tty1

The full list of commands depends on what's installed, but you can
retrieve that list by opening a terminal and typing:

    compgen -ac


Enjoy!




signature.asc
Description: OpenPGP digital signature


Re: Need commands

2020-06-13 Thread Teemu Likonen
ROHIT SONI [2020-06-13T10:12:06+05:30] wrote:

> I need full commands for 2020.2 gnu/linux rolling kali tty1

List all commands in a terminal program and Bash shell:

ls -l {/usr,}/{s,}bin/; help

-- 
/// Teemu Likonen - .-.. http://www.iki.fi/tlikonen/
// OpenPGP: 4E1055DC84E9DFF613D78557719D69D324539450


signature.asc
Description: PGP signature


Re: Need commands

2020-06-13 Thread Richard Owlett

On 06/12/2020 11:42 PM, ROHIT SONI wrote:

Hello sir
I need full commands for 2020.2 gnu/linux rolling kali tty1



 Though Kali is derived from Debian, it is *NOT* Debian.
[q.v. https://en.wikipedia.org/wiki/Kali_Linux ]





Re: Need commands

2020-06-13 Thread deloptes
ROHIT SONI wrote:

> I need full commands for 2020.2 gnu/linux rolling kali tty1

I need 100,- €



Need commands

2020-06-12 Thread ROHIT SONI
Hello sir
I need full commands for 2020.2 gnu/linux rolling kali tty1


Re: Searching for tutorials on ambiguous Debian commands

2020-02-19 Thread David Wright
On Wed 19 Feb 2020 at 07:24:06 (-0600), Richard Owlett wrote:
> I'm looking for a tutorial covering
> "cron(3tcl) cron" [.../tcllib/cron.3tcl.en.html]
> NOT "CRON(8) System Manager's Manual" [.../cron/cron.8.en.html]
> 
> Neither DuckDuckGo nor Google gave acceptable references.
> Many were references to cron(8) *NOT* cron(3tcl).
> 
> A website of interest updates data hourly.
> There is an internal time stamp in the data.
> There is a significant, but a to be determined, delay between the
> time-stamp and when the data is available on the web.
> 
> I want to do data captures at 1 minute intervals from 10 minutes
> before to 10 minutes after the top of the hour.
> 
> Suggestions?
> TIA

cron (8) and wget¹, downloading to a directory whose name is
constructed with $(date some-format), so that you can pick over
your downloads at leisure.

¹ some might suggest curl instead. One day I'll settle down, read
their man pages and compare them. Perhaps write a tutorial :)

Cheers,
David.



Re: Searching for tutorials on ambiguous Debian commands

2020-02-19 Thread Greg Wooledge
On Wed, Feb 19, 2020 at 02:49:13PM +0100, to...@tuxteam.de wrote:
> On Wed, Feb 19, 2020 at 07:24:06AM -0600, Richard Owlett wrote:
> > I'm looking for a tutorial covering
> > "cron(3tcl) cron" [.../tcllib/cron.3tcl.en.html]
> > NOT "CRON(8) System Manager's Manual" [.../cron/cron.8.en.html]
> 
> cron(3tcl) is a Tcl library (or module or what it's ever called),
> not a command. So it's to be used from a Tcl program. It schedules
> actions at given times whithin a running Tcl program and is not
> based on its namesake (just inspired on it).

It's a package within Tcllib, apparently.  Not one that I've used
personally, though.

> That said, "man 3tcl cron" should lead you to the man page. One
> of Tcl's niceties is that its docs are available as man pages).

Yeah, that works if tcllib is installed locally.

Upstream documentation is also at


Debian's man page is also at




Re: Searching for tutorials on ambiguous Debian commands

2020-02-19 Thread John Hasler
Have you looked at   ?
-- 
John Hasler 
jhas...@newsguy.com
Elmwood, WI USA



Re: Searching for tutorials on ambiguous Debian commands

2020-02-19 Thread tomas
On Wed, Feb 19, 2020 at 07:24:06AM -0600, Richard Owlett wrote:
> I'm looking for a tutorial covering
> "cron(3tcl) cron" [.../tcllib/cron.3tcl.en.html]
> NOT "CRON(8) System Manager's Manual" [.../cron/cron.8.en.html]

cron(3tcl) is a Tcl library (or module or what it's ever called),
not a command. So it's to be used from a Tcl program. It schedules
actions at given times whithin a running Tcl program and is not
based on its namesake (just inspired on it).

That said, "man 3tcl cron" should lead you to the man page. One
of Tcl's niceties is that its docs are available as man pages).

I don't know whether there is any tutorial on that around (I
don't even know whether Tcl's cron is what you are after --
guessing from your question it's not clear to me).

A quick search of cron in https://wiki.tcl.tk doesn't yield
good hits -- only two describing how to interact with the
system cron, i.e. the "real thing".

> Neither DuckDuckGo nor Google gave acceptable references.
> Many were references to cron(8) *NOT* cron(3tcl).
> 
> A website of interest updates data hourly.
> There is an internal time stamp in the data.
> There is a significant, but a to be determined, delay between the
> time-stamp and when the data is available on the web.
> 
> I want to do data captures at 1 minute intervals from 10 minutes
> before to 10 minutes after the top of the hour.

And you want to control all of that from a constantly
running Tcl process (so some kind of daemon)?

If your answer is "yes", then cron(3tcl) might be for
you (OTOH it's pretty straightforward to schedule timing
things from Tcl without a special library, so perhaps
understanding cron(3tcl) ends up being more complex than
cooking something up around [after]).

If your answer is "no", then that's not the cron for you.

My Tcl is a bit rusty, but if you're still on the "yes"
branch above, you can show us the code you already
tried and we can try to take it from there.

Cheers
-- tomás


signature.asc
Description: Digital signature


Searching for tutorials on ambiguous Debian commands

2020-02-19 Thread Richard Owlett

I'm looking for a tutorial covering
"cron(3tcl) cron" [.../tcllib/cron.3tcl.en.html]
NOT "CRON(8) System Manager's Manual" [.../cron/cron.8.en.html]

Neither DuckDuckGo nor Google gave acceptable references.
Many were references to cron(8) *NOT* cron(3tcl).

A website of interest updates data hourly.
There is an internal time stamp in the data.
There is a significant, but a to be determined, delay between the 
time-stamp and when the data is available on the web.


I want to do data captures at 1 minute intervals from 10 minutes before 
to 10 minutes after the top of the hour.


Suggestions?
TIA







"/usr/bin/expect" -> check if login is required | speed up commands

2018-09-23 Thread Denny Fuchs
hi,

i have many Proxmox servers with a lot of VMs. I want to use expect to connect 
to the VMs via serial console (qm terminal ), and check if I need to 
login (expect "login: "), or if someone forgotten to logout and I have already 
a  prompt and I need to send an exit before and than try to login again.

My very first expect script looks like:

==
#!/usr/bin/expect -f
### Setting basics

# Show commands and output
log_user 1

# Set variable
set user root
set password testpass
set name [ exec hostname -f]
set prompt ": "

spawn qm terminal 101

#expect_before ": " {
#   send "exit\r"
#}
   expect "login: "
   send "$user\r"
   expect "password:"
   send "$password\r"
   expect $prompt
   puts "-- $name START -"
   expect $prompt
   send "hostname -f\r"
  expect eof
   puts $expect_out(buffer)
  expect $prompt
  send "cat /etc/debian_version\r"
  expect eof
   puts $expect_out(buffer)
  expect $prompt
  expect eof
  send "sed -i 's/root:\ nobody/root:\ sys...@example.com/g' 
/etc/aliases;newaliases\r"
  expect $prompt
  puts "- END ---"
  expect $prompt
  send "exit\r"
  expect "login:"
  send "\x1o\r"


it works, if I need to login first, but if I have a shell, I want to send an 
"exit" before and (re)login again.

The next point is: expect is very slow ... it seems, that there is a default 
delay  every command needs 10 seconds :-) Can I remove the delay or make it 
shorter ?

cu denny


Remote Commands to mplayer Seem to Trigger Multiple Responses.

2018-02-16 Thread Martin McCormick
If I ssh from one jessie system to another, I am noticing that
keyboard commands that should be received by the remote system
seem to live on and cause secondary responses that generally do
nothing but produce odd error messages but something is not quite
normal.

As an example, I use one system as a terminal in to
another via ssh.  I will tell that system to start mplayer and
play a file and it does mostly just fine but if I, for example,
use the { or } to halve or double playback speed, I also see the
following message:

[AO_ALSA] Unable to find simple control 'Master',0.

Obviously, alsa thinks I am trying to do something to
that virtual pot in amixer but the system in question has no
control named 'Master',0 so nothing else happens but many
commands to mplayer cause that same message to appear even though
the desired effect also occurred.

I think this is not necessarily a mplayer or alsa issue
but may have something to do with the way the shell cleans up
after user input.

This is all relatively recent so it has me baffled.

Any ideas as to why or even better, what can one do to
prevent this behavior?

I almost forgot that the terminal type I am using is
Linux on everything.  For many years, I used vt100 or vt102 as
the terminal type but then discovered that it was probably better
to use linux which appears to be rather vt100-like.

Any ideas as to what is happening and best yet, how to fix it are
appreciated as this is not a show stopper but in the category of
kind of odd and not supposed to be happening.

Martin McCormick WB5AGZ



Re: Discovering alternative commands

2017-06-18 Thread Richard Owlett

On 06/17/2017 10:03 AM, Larry Dighera wrote:

On Thu, Jun 01, 2017 at 07:22:36AM -0500, Richard Owlett wrote:

1. what other commands should I look at?

Perhaps you'll find something useful in this little script I wrote:
# show_drives.shDisplay Labels and UUIDs of media
# LGD: Wed May 24 06:35:20 PDT 2017
# Re-write Fri Jun  9 04:31:03 PDT 2017
# Written as an exercise in shell script programming.  ldigh...@att.net


[snip body of script]

Thank you.
Simultaneous perspectives is causing me to think about what questions I 
should be asking about my disk.

The script itself may encourage me to more actively investigate scripting.






Re: Discovering alternative commands

2017-06-17 Thread Larry Dighera
On Thu, Jun 01, 2017 at 07:22:36AM -0500, Richard Owlett wrote:
> 1. what other commands should I look at?
Perhaps you'll find something useful in this little script I wrote:
# show_drives.sh    Display Labels and UUIDs of media
# LGD: Wed May 24 06:35:20 PDT 2017
# Re-write Fri Jun  9 04:31:03 PDT 2017
# Written as an exercise in shell script programming.  ldigh...@att.net 
#

trap "setterm -foreground white;echo;exit 1" ERR INT QUIT EXIT TERM        # 
trap -l will display signals (bash only)

set "lsblk -f" "lsblk -a" "fdisk -l" "findmnt -A" "findmnt -D" "findmnt -D -A" 
"df -Th"    # Put commands in the environment as positional parameters to 
execute

# Prompt user for input
PRMPT="Enter to continue [Q]: "
WAIT(){
  ### ksh 'read' syntax: ksh man page line 2227 (vname?prompt)  
  [[ $(echo $SHELL |grep ksh) ]] && READ="read -n 1 REPLY?\"${PRMPT}\""        
# ksh read syntax
   bash 'read' syntax: bash man page line 4335 (-p prompt)  
  [[ -n $BASH ]] && READ="read -n 1 -r -p \"${PRMPT}\""                # bash 
read syntax (-r, no varname)
  eval ${READ}                                    # Issue prompt for next page
  [[ $REPLY != [Qq]* ]] && setterm -foreground white && return            # 
Return to caller
  [[ $REPLY == [Qq]* ]] && setterm -foreground white                # User 
request to quit received
  echo;exit
}

# Dynamically generate header and footer lines equal to the length of the 
longest line of the output of the current command with the command-name 
centered in the middle of the header line
GENLIN(){
  CMDLEN=$(echo "$1"|wc -m)                            # The length of the 
current command
  LEN=$(eval "$1"|wc -L)                            # The length of the longest 
line generated by the current command passed as an argument to this function
  MIDLIN=$((( ($LEN / 2) - $(echo $1|wc -m)+2 )))                # The 
mid-point of the line at which to place the current command in the header
  [[ $2 != "end" ]] && LEN=$((( $LEN - $CMDLEN )))                # Deduct the 
length of the command line from the header length for footer
  for i in $(seq $LEN) ;do                            # Loop through the 
commands
    echo -e "=\c"                                # Print each line characters
    [[ $i == $MIDLIN && $2 != "end" ]] && echo -e " $1 \c"    # Print the 
command-name in the middle of the header line
  done
  echo
}

CURROW=$(stty -a |grep rows|awk -F \; '/rows/ {print $2}'|tr -d '[a-z A-Z]')    
# Get the number of terminal rows/lines (cursor row position at bottom of 
screen)
[[ -n $BASH ]] && CURROW=$((( $CURROW - 1 )))                    # fucking bash 
:-)
while : ;do
  GENLIN "$1"                                    # Print output header line 
  eval "$1"                                    # Print command output
  GENLIN "$1" "end"                                # Print output footer line
  echo
  shift                                        # Get the next command to run
  [[ -z $1 ]] && { echo;exit ;}                            # Exit when command 
list is exhausted
  setterm -foreground green;WAIT;setterm -foreground white            # Color 
prompt for user input
  tput cup $((($CURROW - 1))) 0                            # Over-write the 
prompt line
done

exit 0



show_drives.sh
Description: application/shellscript


Re: Discovering alternative commands

2017-06-02 Thread David Wright
On Thu 01 Jun 2017 at 17:46:31 (+0200), to...@tuxteam.de wrote:
> On Thu, Jun 01, 2017 at 10:23:58AM -0500, David Wright wrote:
> > On Thu 01 Jun 2017 at 09:20:08 (-0500), Richard Owlett wrote:
> > > On 06/01/2017 08:14 AM, to...@tuxteam.de wrote:
> > > >-BEGIN PGP SIGNED MESSAGE-
> > > >Hash: SHA1
> > > >
> > > >On Thu, Jun 01, 2017 at 07:22:36AM -0500, Richard Owlett wrote:
> > > >>I'm working on a problem that requires as input an association of
> > > >>disk partitions and their "label" (in gparted sense).
> > > >>
> > > >>I already have blkid and lsblk. They are obviously designed for
> > > >>different purposes. They both _can_ supply the desired information.
> > > >>Neither is ideal for me.
> > > >
> > > >You're always so whimsical :)
> > > 
> > > *ROFL* I disagree.
> > 
> > I agree very much.
> > 
> > > My questions may be weird, obtuse, or convoluted. Rarely, if ever,
> > > whimsical ;)
> > > What people have said about my world view for >70 yrs best left ...
> > 
> > The problem with whimsical is that it has two meanings. From the web,
> > for ease of cut and paste,
> > 
> > 1.
> > playfully quaint or fanciful, especially in an appealing and amusing way.
> > "a whimsical sense of humor"
> > 
> > No, not that.
> > 
> > 2.
> > acting or behaving in a capricious manner.
> > "the whimsical arbitrariness of autocracy"
> > 
> > Yes, exactly that. You read people's answers and then pronounce upon
> > them in accordance with your thinking, which we're not party to
> > because you rarely if ever reveal it.
> 
> See? I meant it even slightly differently. From wiktionary:
> 
>   Given to whimsy; capricious; odd; peculiar; playful; light-hearted or 
> amusing.
> 
> For me, it's something between odd, peculiar, playful and amusing.
> I *know* it's some kind of emergent behaviour, and not ill-intentioned
> at all. It makes (for me) interaction more difficult, but more
> enriching at the same time. And somewhat joyful. So there you go.
> 
> > As an example, you wrote above:
> > 
> > > >>I already have blkid and lsblk. They are obviously designed for
> > > >>different purposes. They both _can_ supply the desired information.
> > > >>Neither is ideal for me.
> > 
> > with not a hint of what would be ideal.
> 
> Context. I once had a boss who functioned as Richard does. He had
> a very complicated context in his mind, and when posing a question,
> he offered lots of hints, but with some regularity not those his
> interlocutors needed. Once I got over that I learnt that this kind
> of interaction can be enriching and fun.

There's context here too: we're not meeting face to face,
nor in private, nor is Richard the boss and this list his employees.

> People are quite different, and that is a Good Thing :)
> 
> > Right. So are we meant to spend time looking for different commands
> > which, importantly, must reveal must either reveal more information
> > or the same information in a different way, in order that perchance
> > it might be more ideal for you?
> 
> You always have the choice to throw up your hands (as I did in this
> case).
> 
> [...]
> 
> > Oh, so my question above was wrong. We're expected to find _all_
> > commands, regardless of whether they might be more ideal or not.
> 
> Don't take that personally. I don't think it's meant like that
> (Richard: I'm taking the liberty of second-guessing you. I hope
> you set me straight if I'm too wrong!).

Well, we're probably wasting our time anyway. If you take a look at
https://lists.debian.org/debian-user/2016/11/msg00234.html
there's a productive command there that the OP has already forgotten,
which AIUI reads the files that I mentioned (though I stand to be
corrected; does /run contain the db that udevadm interrogates,
or is there a yet deeper db?).

Cheers,
David.



Re: Discovering alternative commands

2017-06-01 Thread Richard Owlett

On 06/01/2017 11:14 AM, songbird wrote:

Richard Owlett wrote:


I'm working on a problem that requires as input an association of disk
partitions and their "label" (in gparted sense).

I already have blkid and lsblk. They are obviously designed for
different purposes. They both _can_ supply the desired information.
Neither is ideal for me.

Two questions (one asking for fish, the other asking to be taught to fish):
1. what other commands should I look at?
2. is there some reference that groups commands/programs by similarity?

A contrived example of the later, you've come across an unfamiliar word.
Depending on your needs you might consult a thesaurus, encyclopedia, or
dictionary. If a dictionary is indicated, it may be bilingual, idioms,
abridged, or unabridged etc.


  um, for general searching i use either apt-cache or
use synaptic's search function.  that ways you can get
a list of packages which have the word in question
associated with them.  you can specify if you want to
search just the name or include the description.


As I believe I've got the available storage to have full-text of all 
manpages locally and I've complete DVD sets for Squeeze and Jessie from 
which to extract those man pages.




  for more general searching of interesting bits i use
google or other search engines and add words like debian
or linux to make sure i'm entering the right universe.


  :)


  songbird







Re: Discovering alternative commands

2017-06-01 Thread Richard Owlett

On 06/01/2017 10:01 AM, Dan Ritter wrote:

On Thu, Jun 01, 2017 at 07:22:36AM -0500, Richard Owlett wrote:

I'm working on a problem that requires as input an association of disk
partitions and their "label" (in gparted sense).

I already have blkid and lsblk. They are obviously designed for different
purposes. They both _can_ supply the desired information. Neither is ideal
for me.

Two questions (one asking for fish, the other asking to be taught to fish):
1. what other commands should I look at?


Trivially, ls -al on /dev/disks/by* can show you a bunch of
things.


Started experimenting with that. Will require night's sleep and mug of 
coffee [in that order] to appreciate.




You are probably already aware of the contents of
/proc/partitions and /proc/mounts, but I'll mention them anyway.


Hadn't had any contact. I see serious reading in my future.







2. is there some reference that groups commands/programs by similarity?


Not as such, but...

apropos partition
  will tell you about installed commands which have a man page
  prominently mentioning the word "partition".

  In this case you would also want to run apropos against
  "label" and "block".

  running "man -k" is almost the same; apropos takes more
  options.


But reading about "man --global-apropos" gives me germs of ideas. 
Because I have minimal bandwidth, I purchase complete DVD set of each 
release. That means I've all possible man pages so I'm not limited to 
commands currently available on my system. And just happen to have a 
spare 400GB on which to place said man pages.






-dsr-







Re: Discovering alternative commands

2017-06-01 Thread songbird
Richard Owlett wrote:

> I'm working on a problem that requires as input an association of disk 
> partitions and their "label" (in gparted sense).
>
> I already have blkid and lsblk. They are obviously designed for 
> different purposes. They both _can_ supply the desired information. 
> Neither is ideal for me.
>
> Two questions (one asking for fish, the other asking to be taught to fish):
> 1. what other commands should I look at?
> 2. is there some reference that groups commands/programs by similarity?
>
> A contrived example of the later, you've come across an unfamiliar word. 
> Depending on your needs you might consult a thesaurus, encyclopedia, or 
> dictionary. If a dictionary is indicated, it may be bilingual, idioms, 
> abridged, or unabridged etc.

  um, for general searching i use either apt-cache or
use synaptic's search function.  that ways you can get
a list of packages which have the word in question
associated with them.  you can specify if you want to
search just the name or include the description.

  for more general searching of interesting bits i use
google or other search engines and add words like debian
or linux to make sure i'm entering the right universe.


  :)


  songbird



Re: Discovering alternative commands

2017-06-01 Thread tomas
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Thu, Jun 01, 2017 at 10:23:58AM -0500, David Wright wrote:
> On Thu 01 Jun 2017 at 09:20:08 (-0500), Richard Owlett wrote:
> > On 06/01/2017 08:14 AM, to...@tuxteam.de wrote:
> > >-BEGIN PGP SIGNED MESSAGE-
> > >Hash: SHA1
> > >
> > >On Thu, Jun 01, 2017 at 07:22:36AM -0500, Richard Owlett wrote:
> > >>I'm working on a problem that requires as input an association of
> > >>disk partitions and their "label" (in gparted sense).
> > >>
> > >>I already have blkid and lsblk. They are obviously designed for
> > >>different purposes. They both _can_ supply the desired information.
> > >>Neither is ideal for me.
> > >
> > >You're always so whimsical :)
> > 
> > *ROFL* I disagree.
> 
> I agree very much.
> 
> > My questions may be weird, obtuse, or convoluted. Rarely, if ever,
> > whimsical ;)
> > What people have said about my world view for >70 yrs best left ...
> 
> The problem with whimsical is that it has two meanings. From the web,
> for ease of cut and paste,
> 
> 1.
> playfully quaint or fanciful, especially in an appealing and amusing way.
> "a whimsical sense of humor"
> 
> No, not that.
> 
> 2.
> acting or behaving in a capricious manner.
> "the whimsical arbitrariness of autocracy"
> 
> Yes, exactly that. You read people's answers and then pronounce upon
> them in accordance with your thinking, which we're not party to
> because you rarely if ever reveal it.

See? I meant it even slightly differently. From wiktionary:

  Given to whimsy; capricious; odd; peculiar; playful; light-hearted or amusing.

For me, it's something between odd, peculiar, playful and amusing.
I *know* it's some kind of emergent behaviour, and not ill-intentioned
at all. It makes (for me) interaction more difficult, but more
enriching at the same time. And somewhat joyful. So there you go.

> As an example, you wrote above:
> 
> > >>I already have blkid and lsblk. They are obviously designed for
> > >>different purposes. They both _can_ supply the desired information.
> > >>Neither is ideal for me.
> 
> with not a hint of what would be ideal.

Context. I once had a boss who functioned as Richard does. He had
a very complicated context in his mind, and when posing a question,
he offered lots of hints, but with some regularity not those his
interlocutors needed. Once I got over that I learnt that this kind
of interaction can be enriching and fun.

People are quite different, and that is a Good Thing :)

> Right. So are we meant to spend time looking for different commands
> which, importantly, must reveal must either reveal more information
> or the same information in a different way, in order that perchance
> it might be more ideal for you?

You always have the choice to throw up your hands (as I did in this
case).

[...]

> Oh, so my question above was wrong. We're expected to find _all_
> commands, regardless of whether they might be more ideal or not.

Don't take that personally. I don't think it's meant like that
(Richard: I'm taking the liberty of second-guessing you. I hope
you set me straight if I'm too wrong!).

Cheers
- -- t
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.12 (GNU/Linux)

iEYEARECAAYFAlkwNtcACgkQBcgs9XrR2kZd5gCffM53Q9+O8LhbysTX6DwMxJ6+
qKUAn0zBt8EA/xkSBR5L8pGLsh8jze5s
=mNAE
-END PGP SIGNATURE-



Re: Discovering alternative commands

2017-06-01 Thread David Wright
On Thu 01 Jun 2017 at 09:20:08 (-0500), Richard Owlett wrote:
> On 06/01/2017 08:14 AM, to...@tuxteam.de wrote:
> >-BEGIN PGP SIGNED MESSAGE-
> >Hash: SHA1
> >
> >On Thu, Jun 01, 2017 at 07:22:36AM -0500, Richard Owlett wrote:
> >>I'm working on a problem that requires as input an association of
> >>disk partitions and their "label" (in gparted sense).
> >>
> >>I already have blkid and lsblk. They are obviously designed for
> >>different purposes. They both _can_ supply the desired information.
> >>Neither is ideal for me.
> >
> >You're always so whimsical :)
> 
> *ROFL* I disagree.

I agree very much.

> My questions may be weird, obtuse, or convoluted. Rarely, if ever,
> whimsical ;)
> What people have said about my world view for >70 yrs best left ...

The problem with whimsical is that it has two meanings. From the web,
for ease of cut and paste,

1.
playfully quaint or fanciful, especially in an appealing and amusing way.
"a whimsical sense of humor"

No, not that.

2.
acting or behaving in a capricious manner.
"the whimsical arbitrariness of autocracy"

Yes, exactly that. You read people's answers and then pronounce upon
them in accordance with your thinking, which we're not party to
because you rarely if ever reveal it.

As an example, you wrote above:

> >>I already have blkid and lsblk. They are obviously designed for
> >>different purposes. They both _can_ supply the desired information.
> >>Neither is ideal for me.

with not a hint of what would be ideal.

> >Do those commands provide the information you need, albeit in a wrong
> >format, or is anything truly amiss?
> 
> Yes.
> 
> >
> >>Two questions (one asking for fish, the other asking to be taught to fish):
> >>1. what other commands should I look at?
> 
> That is EXPLICITLY the intended question.

Right. So are we meant to spend time looking for different commands
which, importantly, must reveal must either reveal more information
or the same information in a different way, in order that perchance
it might be more ideal for you?

> I've in the past have had teachers who would pick
> grammatical/syntactic nits who would have asserted that "can" would
> would have a better word choice than "should". [P.S. linguistics is
> an semantically fascinating universe of discourse ;]
> 
> I terms of set theory ;}
> Please enumerate those commands which can report all partition ids
> and associated labels.
> That specifies the appropriate necessary and sufficient conditions.
> Literally the best way to interpret my questions is literally.

Oh, so my question above was wrong. We're expected to find _all_
commands, regardless of whether they might be more ideal or not.

> >>2. is there some reference that groups commands/programs by similarity?
> >
> >Your requests for help tend to contain restrictions which sometimes
> >are difficult to grasp for your interlocutors.
> 
> I'll paraphrase a hermeneutics professor "If the plain sense makes
> common sense, seek no other sense."
> 
> >To you, of course, these
> >restrictions seem natural, because they are the result of a thought
> >process you have access to -- but consider that we don't. Sometimes
> >those restrictions seem artificial, without the context, and I'm left
> >left wondering whether it's that I'm not understanding your request
> >or whether it's you excluding a viable possibility.
> >
> >So is it the output's content or their form what isn't up to your
> >needs?
> 
> Neither.
> One, of many, things that prompted me ask if either was preferable
> is one requires root privileges and the other not.

So we were wrong all along, and we're _still_ only allowed to know one
thing that prompted you to ask your question, and we weren't told it
before spending time diligently seeking commands which might,
or might not, be ideal for you because they might require root privilege.

Anyway, rather than suggest a command that may or may not be ideal,
I would ask you to look in two places:

/dev/disk/…
/run/udev/data/b*

Plenty of information there to parse.

Cheers,
David.



Re: Discovering alternative commands

2017-06-01 Thread tomas
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Thu, Jun 01, 2017 at 09:20:08AM -0500, Richard Owlett wrote:
> On 06/01/2017 08:14 AM, to...@tuxteam.de wrote:

[...]

> >You're always so whimsical :)
> 
> *ROFL* I disagree.

Yes, I expected that. It's a perception thing.

> My questions may be weird, obtuse, or convoluted. Rarely, if ever,
> whimsical ;)
> What people have said about my world view for >70 yrs best left ...
> 
> >
> >Do those commands provide the information you need, albeit in a wrong
> >format, or is anything truly amiss?
> 
> Yes.
> 
> >
> >>Two questions (one asking for fish, the other asking to be taught to fish):
> >>1. what other commands should I look at?
> 
> That is EXPLICITLY the intended question.

Then I'll have to throw up my hands: up to now I could make do with
those. But I see Dan has taken over.

Cheers
- -- t
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.12 (GNU/Linux)

iEYEARECAAYFAlkwL6IACgkQBcgs9XrR2kb4XgCeNqSREecvzeVQEOzo6ZZ9YOO5
ElIAn2ks/puXR5aO5ptTHLmbJOSHLPOp
=Tkmm
-END PGP SIGNATURE-



Re: Discovering alternative commands

2017-06-01 Thread Dan Ritter
On Thu, Jun 01, 2017 at 07:22:36AM -0500, Richard Owlett wrote:
> I'm working on a problem that requires as input an association of disk
> partitions and their "label" (in gparted sense).
> 
> I already have blkid and lsblk. They are obviously designed for different
> purposes. They both _can_ supply the desired information. Neither is ideal
> for me.
> 
> Two questions (one asking for fish, the other asking to be taught to fish):
> 1. what other commands should I look at?

Trivially, ls -al on /dev/disks/by* can show you a bunch of
things. You are probably already aware of the contents of
/proc/partitions and /proc/mounts, but I'll mention them anyway.




> 2. is there some reference that groups commands/programs by similarity?

Not as such, but...

apropos partition
  will tell you about installed commands which have a man page
  prominently mentioning the word "partition".

  In this case you would also want to run apropos against
  "label" and "block".

  running "man -k" is almost the same; apropos takes more
  options.


-dsr-



Re: Discovering alternative commands

2017-06-01 Thread Richard Owlett

On 06/01/2017 08:14 AM, to...@tuxteam.de wrote:

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Thu, Jun 01, 2017 at 07:22:36AM -0500, Richard Owlett wrote:

I'm working on a problem that requires as input an association of
disk partitions and their "label" (in gparted sense).

I already have blkid and lsblk. They are obviously designed for
different purposes. They both _can_ supply the desired information.
Neither is ideal for me.


You're always so whimsical :)


*ROFL* I disagree.
My questions may be weird, obtuse, or convoluted. Rarely, if ever, 
whimsical ;)

What people have said about my world view for >70 yrs best left ...



Do those commands provide the information you need, albeit in a wrong
format, or is anything truly amiss?


Yes.




Two questions (one asking for fish, the other asking to be taught to fish):
1. what other commands should I look at?


That is EXPLICITLY the intended question.
I've in the past have had teachers who would pick grammatical/syntactic 
nits who would have asserted that "can" would would have a better word 
choice than "should". [P.S. linguistics is an semantically fascinating 
universe of discourse ;]


I terms of set theory ;}
Please enumerate those commands which can report all partition ids and 
associated labels.

That specifies the appropriate necessary and sufficient conditions.
Literally the best way to interpret my questions is literally.


2. is there some reference that groups commands/programs by similarity?


Your requests for help tend to contain restrictions which sometimes
are difficult to grasp for your interlocutors.


I'll paraphrase a hermeneutics professor "If the plain sense makes 
common sense, seek no other sense."



To you, of course, these
restrictions seem natural, because they are the result of a thought
process you have access to -- but consider that we don't. Sometimes
those restrictions seem artificial, without the context, and I'm left
left wondering whether it's that I'm not understanding your request
or whether it's you excluding a viable possibility.

So is it the output's content or their form what isn't up to your
needs?


Neither.
One, of many, things that prompted me ask if either was preferable is 
one requires root privileges and the other not.







Re: Discovering alternative commands

2017-06-01 Thread tomas
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Thu, Jun 01, 2017 at 07:22:36AM -0500, Richard Owlett wrote:
> I'm working on a problem that requires as input an association of
> disk partitions and their "label" (in gparted sense).
> 
> I already have blkid and lsblk. They are obviously designed for
> different purposes. They both _can_ supply the desired information.
> Neither is ideal for me.

You're always so whimsical :)

Do those commands provide the information you need, albeit in a wrong
format, or is anything truly amiss?

> Two questions (one asking for fish, the other asking to be taught to fish):
> 1. what other commands should I look at?
> 2. is there some reference that groups commands/programs by similarity?

Your requests for help tend to contain restrictions which sometimes
are difficult to grasp for your interlocutors. To you, of course, these
restrictions seem natural, because they are the result of a thought
process you have access to -- but consider that we don't. Sometimes
those restrictions seem artificial, without the context, and I'm left
left wondering whether it's that I'm not understanding your request
or whether it's you excluding a viable possibility.

So is it the output's content or their form what isn't up to your
needs?

Cheers
- -- tomás
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.12 (GNU/Linux)

iEYEARECAAYFAlkwExsACgkQBcgs9XrR2kag1QCdExe5ltDCL6T7Q/m/PS7RPOkh
lckAnR7/M6nKsge1yi/ba0ymLmfw5Ak7
=FTO4
-END PGP SIGNATURE-



Discovering alternative commands

2017-06-01 Thread Richard Owlett
I'm working on a problem that requires as input an association of disk 
partitions and their "label" (in gparted sense).


I already have blkid and lsblk. They are obviously designed for 
different purposes. They both _can_ supply the desired information. 
Neither is ideal for me.


Two questions (one asking for fish, the other asking to be taught to fish):
1. what other commands should I look at?
2. is there some reference that groups commands/programs by similarity?

A contrived example of the later, you've come across an unfamiliar word. 
Depending on your needs you might consult a thesaurus, encyclopedia, or 
dictionary. If a dictionary is indicated, it may be bilingual, idioms, 
abridged, or unabridged etc.


TIA



Re: grub rescue commands not working

2016-05-28 Thread Hans
> Obtain a netinst image. Boot it and choose rescue mode from the menu.
> You will eventually get an option to 'Reinstall the GRUB boot loader'.
You may also try super grub 2 disk.
Google for it. 

Good luck!

Best

Hans



Re: grub rescue commands not working

2016-05-28 Thread Brian
On Fri 27 May 2016 at 21:05:11 -0400, Haines Brown wrote:

> My main system cannot boot. No idea how to reinstall grub2 from Live
> CD, and so look to see what I...

Obtain a netinst image. Boot it and choose rescue mode from the menu.
You will eventually get an option to 'Reinstall the GRUB boot loader'.



grub rescue commands not working

2016-05-27 Thread Haines Brown
My main system cannot boot. No idea how to reinstall grub2 from Live CD, and so 
look to see what I
can do at grub rescue> prompt.

grub rescue> ls

  returns a big list of partitions. The only one I files from is:

grub rescue> ls (hd1,1)/boot

  returns initrd.img, vmlinux, config,  System.map files, but no .mod files

grub rescue> dump

  I run because I've been playing around,  returns initrd.img, vmlinux, config, 
System.map files,
but no .mod files

grub rescue> dump

  I run because I've been playing around, but 'dump' is unknown command

grub rescue> set root=(hd1,1)
grub rescue> set prefix=(hd1,1)/boot/grub

grub rescue> insmod normal
error:  file `boot/grub/i386-pc/normal.mod not found

Haines  Brown



qdbus commands in 64-bit jessie?

2015-09-01 Thread D. R. Evans
In wheezy, the following command worked correctly:



qdbus org.kde.yakuake /yakuake/sessions runCommandInTerminal $SESSION_ID "tmux"



Following my upgrade to jessie, the same command produces:



qdbus: could not exec '/usr/lib/i386-linux-gnu/qt4/bin/qdbus': No such file or
directory



The reference to i386 is a bit puzzling, since this is a 64-bit system.
Anyway, I discovered that all attempts to execute qdbus commands from the
command line produce the same error :-(

What do I need to do to get my qdbus commands working again?

  Doc

-- 
Web:  http://www.sff.net/people/N7DR



signature.asc
Description: OpenPGP digital signature


Some commands is not working in Linux server

2015-02-23 Thread Justinmp
Greetings to all..

Everything was working normally until last day.From today I am not able to 
execute few commands like ls in cent os machine.Interesting part is ls -al is 
working fine.

When ever I issued ls , du -sh *  ,yum update system got stuck and putty 
session  freezes.

Is this because of any hardware issue ?This server is remotely accessed.

Thank you
Justin



Commands not working in Live Server

2015-02-23 Thread Justinmp
Greetings to all...

From today I am not able to execute few commands like ls in linux 
machine.Interesting part is ls -al is working fine.

When ever I issued ls , du -sh *  ,yum update system got stuck and putty 
session  freezes.

Is this because of any hardware issue ?This linux server is remotely accessed.

Thank you
Justin


Re: Some commands is not working in Linux server

2015-02-23 Thread Karl E. Jorgensen
Hi

On Mon, 2015-02-23 at 21:00 +0530, Justinmp wrote:
 Greetings to all..
 
 Everything was working normally until last day.From today I am not
 able to execute few commands like ls in cent os machine.Interesting
 part is ls -al is working fine.
 
 When ever I issued ls , du -sh *  ,yum update system got stuck and
 putty session  freezes.
 
 Is this because of any hardware issue ?This server is remotely
 accessed.

You do not list many symptoms, so the server could be suffering from
anything. Or your network may suffer from anything.  Without more
details, the best we can do is pure speculation.

... yum update ?? You know: this is a debian list...



-- 
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org 
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Archive: https://lists.debian.org/1424708419.11587.2.ca...@jorgensen.org.uk



RE: Some commands is not working in Linux server

2015-02-23 Thread Justinmp
Yes I know , Debian servers are working fine.


Thanks
Justin


-Original Message-
From: Karl E. Jorgensen k...@jorgensen.org.uk
Sent: ‎23/‎02/‎2015 09:50 PM
To: debian-user@lists.debian.org debian-user@lists.debian.org
Subject: Re: Some commands is not working in Linux server

Hi

On Mon, 2015-02-23 at 21:00 +0530, Justinmp wrote:
 Greetings to all..
 
 Everything was working normally until last day.From today I am not
 able to execute few commands like ls in cent os machine.Interesting
 part is ls -al is working fine.
 
 When ever I issued ls , du -sh *  ,yum update system got stuck and
 putty session  freezes.
 
 Is this because of any hardware issue ?This server is remotely
 accessed.

You do not list many symptoms, so the server could be suffering from
anything. Or your network may suffer from anything.  Without more
details, the best we can do is pure speculation.

... yum update ?? You know: this is a debian list...



-- 
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org 
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Archive: https://lists.debian.org/1424708419.11587.2.ca...@jorgensen.org.uk



  1   2   3   4   5   6   7   >