Unix & Linux Stack Exchange
Q&A for users of Linux, FreeBSD and other Unix-like operating systems
Latest Questions
0
votes
2
answers
129
views
Use 'fold' to wrap lines at 72 column
Test file: ``` Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmo tempor incididunt ut labore et dolore magna aliqua. Ut enim minim veniam quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit...
Test file:
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmo tempor incididunt ut labore et dolore magna aliqua. Ut enim minim veniam quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
If using
script.sh input.txt output.txt
sed 's/ - /--/g
s/ \{0,1\}[—–] \{0,1\}/--/g
s/…/.../g
s/\\\*/†/g
s/*/\//g
s/\\\././g' $1 |
fold -sw 72 |
sed 's/ *$//g' > $2
the output is
```
------------------------------------------------------------------------ -s: Fold line after the last blank character within the first width column positions (or bytes).
I use fold
supplied with macOS, but if using GNU fold
, the output file is the same.
jsx97
(1347 rep)
Aug 30, 2024, 06:24 PM
• Last activity: Sep 3, 2024, 11:17 PM
0
votes
0
answers
24
views
how do you enable word wrap in dolphin when naming files
I would like to configure dolphin to wrap the file name text, instead of putting it on a new line. I have tried to do it through dolphins preferences, but had no success. I find that being able to wrap the text for files, to be more aesthetically pleasing and it also, for me, works better in the bro...
I would like to configure dolphin to wrap the file name text, instead of putting it on a new line. I have tried to do it through dolphins preferences, but had no success.
I find that being able to wrap the text for files, to be more aesthetically pleasing and it also, for me, works better in the browser window.
I can't seem to be able to enable this feature though. So I would like to know how to enable text wrap for my labels, and filenames.
daniel hoggan
(1 rep)
Sep 2, 2024, 08:36 AM
0
votes
2
answers
438
views
Bash: how to wrap a command to measure its elapsed time?
How to wrap a command to measure its elapsed time? Currently I do it using `eval`: ``` do_cmd_named() { local name=$1 local cmd=$2 echo "$name" local start_time=$(date +%s) eval "$cmd 2>&1" local exit_status=$? local end_time=$(date +%s) local elapsed_time_sec=$((end_time-start_time)) local elapsed_...
How to wrap a command to measure its elapsed time?
Currently I do it using
eval
:
do_cmd_named()
{
local name=$1
local cmd=$2
echo "$name"
local start_time=$(date +%s)
eval "$cmd 2>&1"
local exit_status=$?
local end_time=$(date +%s)
local elapsed_time_sec=$((end_time-start_time))
local elapsed_time_min_sec=$(date -ud "@$elapsed_time_sec" +'%M:%S')
if [[ $exit_status -ne 0 ]]
then
echo "$name failed with exit status $exit_status (elapsed time $elapsed_time_min_sec)"
return $exit_status
else
echo "$name done (elapsed time $elapsed_time_min_sec)"
fi
}
job()
{
sleep 1
}
do_cmd_named "do job" "job"
which leads to:
do job
do job done (elapsed time 00:01)
For my cases this approach _almost _ works. However, this approach is considered bad because it violates some rules from BashFAQ . For example, "don't put code inside variables" from [BashFAQ #50](https://mywiki.wooledge.org/BashFAQ/050) (see also [BashFAQ #48](https://mywiki.wooledge.org/BashFAQ/048)).
So, the question is: how to do it correctly?
pmor
(665 rep)
Nov 21, 2022, 09:22 AM
• Last activity: Nov 23, 2022, 04:28 PM
1
votes
0
answers
252
views
set custom wrap column
OS: SLES12, terminal emulator: mate 1.22.1, shell: tcsh $TERM: xterm-256color I want to set the line wrapping in the terminal so that any text that appears on the terminal (stdout or otherwise) wraps a few columns left to the edge. I always work with full-screen terminal (which I think is defined as...
OS: SLES12,
terminal emulator: mate 1.22.1,
shell: tcsh
$TERM: xterm-256color
I want to set the line wrapping in the terminal so that any text that appears on the terminal (stdout or otherwise) wraps a few columns left to the edge.
I always work with full-screen terminal (which I think is defined as width = 80) so I don't mind if that behavior breaks when the terminal is not in full screen.
I know of the command "fold" but I don't know how to apply it to the entirety of the terminal.
If there's a way to apply it to only stdout then I can take it as a compromise.
Thanks
Shoeman
(23 rep)
May 16, 2022, 12:13 PM
• Last activity: May 16, 2022, 06:03 PM
2
votes
3
answers
297
views
Find path of original command when overriding it with a shell script?
I'm writing a wrapper script to wrap around the execution of another command; in this case the Chef `kitchen` command. My script will also be called `kitchen` and put earlier in `$PATH` so that running `kitchen` from bash will run my wrapper script instead. The question is: how do I call the origina...
I'm writing a wrapper script to wrap around the execution of another command; in this case the Chef
kitchen
command. My script will also be called kitchen
and put earlier in $PATH
so that running kitchen
from bash will run my wrapper script instead.
The question is: how do I call the original version of kitchen
? The obvious way, of course, is just to give the full path — just put /usr/bin/kitchen
in the script, but someone else may have it installed at a different path. And of course that precludes any other wrapper scripts—it'd be nice if the solution were stackable.
Two approaches come to mind, both variants on the same theme:
1. In the script, go through $PATH
. Compare each entry to $(dirname "$0")
using stat
using device number & inode number to see if its the same directory. If so, remove it from $PATH
. Then can just call kitchen
, because it shouldn't re-call the wrapper script.
2. Similar to #1, but do the $PATH
lookup by hand in the script, and use stat
on each result vs. $0
. Keep skipping until we find ourself, then use the next one found. If we never find ourself, then just exec it normally (to handle the case the wrapper isn't in $PATH
but was executed by providing a path to it)
Is there a better way? Or does code to do this already exist somewhere on a typical Debian or Ubuntu Linux system?
derobert
(112989 rep)
Sep 22, 2021, 06:30 PM
• Last activity: Sep 23, 2021, 09:36 AM
0
votes
1
answers
69
views
What is electron-wrapped process?
I found this process today but I don't recognize it. Searching i found that is a [tool][1] but I haven't installed it.(directly) Can it be a problem to consider? Thank you! [![enter image description here][2]][2] [1]: https://www.npmjs.com/package/electron-wrapper [2]: https://i.sstatic.net/urU6e.pn...
I found this process today but I don't recognize it.
Searching i found that is a tool but I haven't installed it.(directly)
Can it be a problem to consider?
Thank you!

xilen0x
(1 rep)
Jun 4, 2021, 10:42 AM
• Last activity: Jun 4, 2021, 11:21 AM
0
votes
1
answers
246
views
Current/working directory issue from wrapper
A common packaging issue I encounter is when a tool is looking for relative resources in its root directory (install directory). Eg. pkg-name (`/usr/share/pkg-name/pkg-name`) is looking for resourceA (`/usr/share/pkg-name/resourceA`) so you can't call `/usr/share/pkg-name/pkg-name` directly unless y...
A common packaging issue I encounter is when a tool is looking for relative resources in its root directory (install directory).
Eg. pkg-name (
/usr/share/pkg-name/pkg-name
) is looking for resourceA (/usr/share/pkg-name/resourceA
) so you can't call /usr/share/pkg-name/pkg-name
directly unless your $PWD = /usr/share/pkg-name/
, because if you're elsewhere (eg. /home/user
) that tool will look for /home/user/resourceA
and raise an error. So your are forced to create a wrapper like the following one: /usr/bin/pkg-wrapper
#!/bin/sh
cd /usr/share/pkg-name
exec pkg-name "\$@"
Now you can call /usr/bin/pkg-wrapper
from whatever you want but a new issue is facing you!
By adding cd /usr/share/pkg-name
in your wrapper, $PWD = /usr/share/pkg-name
in the context of the script. So imagine that pkg-wrapper -o file
can write a file, now pkg-wrapper -o file
will try to save the file file
at /usr/share/pkg-name/file
(current/working directory in the script context) and not at /home/user/file
(current/working directory from where you are calling the wrapper). So files are now saved not in the folder you would like and if /usr/share/pkg-name/
is write protected you will get a permission error anyway.
So you can't use relative file path anymore and are forced to either specify absolute path eg. pkg-wrapper -o /home/user/file
or a little trick like pkg-wrapper -o "$(pwd)/file"
or pkg-wrapper -o "$PWD/file"
.
Is there an agnostic way to solve this common issue? If not a way to patch ruby & python to use the "user current directory" rather than the script/process current directory?
I already looked bash set options, bundle exec options.
For example a wrapper for a ruby script could be like the following if the --magicoption
option existed to specify the the root directory where to look Gemfile
, vendor/
and .bundle/
from.
#!/bin/sh
exec bundle exec /usr/share/pkg-name/pkg-name.rb --magicoption /usr/share/pkg-name/ "\$@"
This is just an example for a ruby package but it's the same issue for any script / binary from any language.
noraj
(425 rep)
Sep 21, 2020, 07:03 PM
• Last activity: Sep 24, 2020, 03:18 PM
0
votes
2
answers
255
views
How to use bash cat * to wrap?
``` ls /proc/ 1 10984 11246 131 144 167 2099 31788 4805 5375 6762 7594 8111 8722 consoles 10 10993 11247 1314 14400 168 21 32 4807 5379 6771 76 8112 8738 cpuinfo 100 10998 11248 13163 14403 169 210 32408 4818 5386 6788 7601 8113 8752 crypto 101 11 11249 132 14404 17 211 33 4831 5388 68 7619 8114 876...
ls /proc/
1 10984 11246 131 144 167 2099 31788 4805 5375 6762 7594 8111 8722 consoles
10 10993 11247 1314 14400 168 21 32 4807 5379 6771 76 8112 8738 cpuinfo
100 10998 11248 13163 14403 169 210 32408 4818 5386 6788 7601 8113 8752 crypto
101 11 11249 132 14404 17 211 33 4831 5388 68 7619 8114 8768 devices
102 110 11251 133 14405 170 2111 34 4833 54 6808 7625 8115 8789 diskstats
10202 11012 11252 134 14406 1726 2115 3489 4846 5417 6827 7626 8116 88 dma
cat /proc/10993/root/run_command
/usr/sbin/libvirtd --listen(nova-libvirt)
and I want to get all PID run_command
cd /proc
cat */root/run_command
/etc/barbican/vassals --logto /var/log/kolla/barbican/barbican-api.loguwsgi --master --emperor /etc/barbican/vassals --logto /var/log/kolla/barbican/barbican-api.loguwsgi --master --emperor /etc/barbican/vassals --logto /var/log/kolla/barbican/barbican-api.log/opt/kibana/bin/kibanabarbican-keystone-listenerbarbican-keystone-listenerheat-api-cfnheat-api-cfnneutron-dhcp-agent --config-file /etc/neutron/neutron.conf --config-file /etc/neutron/dhcp_agent.inimistral-server --server executor --config-file /etc/mistral/mistral.confneutron-dhcp-agent --config-file /etc/neutron/neutron.conf --config-file /etc/neutron/dhcp_agent.inimistral-server --server executor --config-file /etc/mistral/mistral.conf/usr/sbin/sshd -Dtacker-server --config-file /etc/tacker/tacker.conf/usr/sbin/sshd -Dtacker-server --config-file /etc/tacker/tacker.conf/usr/sbin/apache2/usr/sbin/td-agent/usr/bin/mysqld_safeglance-registry/usr/sbin/apache2start-ovsdb-server 127.0.0.1/usr/bin/mysqld_safeglance-registrynova-apistart-ovsdb-server 127.0.0.1nova-consoleauthnova-api/usr/sbin/libvirtd --listennova-consoleauth/usr/bin/memcached -v -l 10.60.6.174 -p 11211 -c 5000 -U 0/usr/bin/memcached -v -l 10.60.6.174 -p 11211 -c 5000 -U 0/usr/sbin/libvirtd --listenneutron-metadata-agent --config-file /etc/neutron/neutron.conf --config-file /etc/neutron/metadata_agent.ini/usr/sbin/libvirtd --listenmistral-server --server engine --config-file /etc/mistral/mistral.confneutron-metadata-agent --config-file /etc/neutron/neutron.conf --config-file /etc/neutron/metadata_agent.inimistral-server --server engine --config-file /etc/mistral/mistral.confstart-ovsdb-server 127.0.0.1/usr/share/elasticsearch/bin/elasticsearchsleep infinity/usr/share/elasticsearch/bin/elasticsearchbarbican-workersleep infinitynova-conductorbarbican-worker/opt/kafka/bin/kafka-server-start.sh /etc/kafka/kafka.server.propertiesnova-compute/usr/sbin/libvirtd --listen/usr/sbin/apache2/usr/sbin/apache2/usr/sbin/apache2/usr/sbin/apache2/usr/sbin/apache2/usr/sbin/apache2/usr/sbin/apache2/usr/sbin/apache2/usr/sbin/apache2/usr/sbin/apache2/usr/sbin/apache2/usr/sbin/apache2no ...
but it's too messy to read.
**How do I put each record (content of each file) on a separate line?**
run_comand_content1
run_comand_content2
run_comand_content3
or
run_comand_content1
run_comand_content2
run_comand_content3
bohan Chen
(1 rep)
Jan 22, 2019, 02:12 AM
• Last activity: Jan 22, 2019, 09:41 AM
2
votes
1
answers
538
views
Bash prompt wrap broken when path has unicode (Greek) characters
When a path is too long to fit on the terminal and it wraps, the following prompt is broken and you can't see properly what is typed. See screenshot below: [![enter image description here][1]][1] These are the contents of `.bashrc` that set the `PS1`, which is the default provided by Ubuntu. if [ "$...
When a path is too long to fit on the terminal and it wraps, the following prompt is broken and you can't see properly what is typed. See screenshot below:
These are the contents of

.bashrc
that set the PS1
, which is the default provided by Ubuntu.
if [ "$color_prompt" = yes ]; then
PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ '
else
PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ '
fi
unset color_prompt force_color_prompt
# If this is an xterm set the title to user@host:dir
case "$TERM" in
xterm*|rxvt*)
PS1="\[\e]0;${debian_chroot:+($debian_chroot)}\u@\h: \w\a\]$PS1"
;;
*)
;;
esac
The value of $PS1
is
echo "$PS1"
\[\e]0;\u@\h: \w\a\]${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$
Is there any way to fix it?
I have seen several other similar questions, and the proposed solution is to enclose the offending part in \[ \]
, or to set checkwinsize
, but neither worked in my case.
If anyone wants to test with the path, it is the folowing:
/home/dimitriv/Dropbox/personal/kastoria/2018-2019/προγραμματισμός στο διαδίκτυο/newslides
user000001
(3795 rep)
Nov 4, 2018, 01:33 PM
• Last activity: Nov 4, 2018, 02:42 PM
0
votes
1
answers
254
views
Rip-off (an ncurses term) single bottom line out of /dev/tty terminal, is it possible?
`Ncurses` allows to separate a single line from screen, at level of physical screen (`curscr`), to devote it to e.g. a title bar, thus also creating a logical screen (`stdscr`), devoted to application's viewport. It's the `ncurses` call `ripoffline()` that's responsible for this. This serves as a ba...
Ncurses
allows to separate a single line from screen, at level of physical screen (curscr
), to devote it to e.g. a title bar, thus also creating a logical screen (stdscr
), devoted to application's viewport. It's the ncurses
call ripoffline()
that's responsible for this.
This serves as a basic explanation of my problem – I need to do the same with /dev/tty
. The best for me would be to create a dummy e.g. /tmp/tty.LCRiAotf
, which would wrap /dev/tty
and somehow rip-off the single top or bottom line.
My master-script would use /dev/tty
and provide the top-or-bottom menu bar I want to create, while say a slave-script would use /tmp/tty.LCRiAotf
which is a logical tty 1-row less in height, not interfering with the menu bar.
The best would be to do this in shell script, in general in Zshell. I know it might be hard to create a wrapper tty device with command-line tools, but maybe it's possible? Other solutions are also welcomed. Is this possible?
Digger
(23 rep)
Oct 18, 2018, 01:29 PM
• Last activity: Oct 18, 2018, 08:50 PM
8
votes
1
answers
3439
views
Turning off word-wrap with less during paging?
I can get the effect that I want from running `less -S` but it seems fishy to me that there is no way to render the input without word-wrap after the file is opened. Is there anyway to less /tmp/longtext And then after you have it up to disable wordwrap without exiting and restarting.
I can get the effect that I want from running
less -S
but it seems fishy to me that there is no way to render the input without word-wrap after the file is opened.
Is there anyway to
less /tmp/longtext
And then after you have it up to disable wordwrap without exiting and restarting.
Evan Carroll
(34663 rep)
Oct 12, 2018, 09:15 AM
• Last activity: Oct 12, 2018, 09:26 AM
1
votes
2
answers
83
views
Hard wrap hard refill
Given this file: $ cat file alfa bravo charlie delta echo foxtrot golf hotel india juliet kilo lima mike november oscar papa quebec romeo sierra tango uniform_victor_whiskey_xray yankee zulu I would like to hard break at 70, but I would also like to hard refill. I tried "fold", but it did not refill...
Given this file:
$ cat file
alfa bravo charlie delta echo foxtrot golf hotel india juliet kilo lima mike
november oscar papa quebec romeo sierra tango
uniform_victor_whiskey_xray yankee zulu
I would like to hard break at 70, but I would also like to hard refill. I tried
"fold", but it did not refill:
$ fold -w 70 file
alfa bravo charlie delta echo foxtrot golf hotel india juliet kilo lim
a mike
november oscar papa quebec romeo sierra tango
uniform_victor_whiskey_xray yankee zulu
"fmt" will refill, but I could only get it to break on spaces so no guarantee to
wrap on exactly 70:
$ fmt file
alfa bravo charlie delta echo foxtrot golf hotel india juliet
kilo lima mike november oscar papa quebec romeo sierra tango
uniform_victor_whiskey_xray yankee zulu
I tried "pr" but it seems to just truncate the line without wrapping:
$ pr -t -W 70 file
alfa bravo charlie delta echo foxtrot golf hotel india juliet kilo lim
november oscar papa quebec romeo sierra tango
uniform_victor_whiskey_xray yankee zulu
Maybe these commands have some option I am missing, or maybe Awk or Sed
solution. I would prefer to avoid heavier solutions (Perl PHP Ruby).
Zombo
(1 rep)
Mar 3, 2018, 05:02 AM
• Last activity: Oct 10, 2018, 11:10 PM
0
votes
3
answers
379
views
Script error message in a single line
I am executing the command mv /prod/new/outputlog/error.log /prod/hist/new/outputlog/error.log.32423423424 using shell script. Since the `error.log` file is not available the command writing an error message in to the log file automatically. The error message `mv: cannot rename /prod/new/outputlog/e...
I am executing the command
mv /prod/new/outputlog/error.log /prod/hist/new/outputlog/error.log.32423423424
using shell script.
Since the
error.log
file is not available the command writing an error message in to the log file automatically. The error message mv: cannot rename /prod/new/outputlog/error.log /prod/hist/new/outputlog/error.log.32423423424
Not wrap in to two lines.
Since it is a system-generated error message I am unable to control the length of the error message for each line. I want the system to wrap the message after it reaches length 80.
Murali
(1 rep)
Sep 12, 2017, 08:14 PM
• Last activity: May 6, 2018, 07:18 AM
9
votes
1
answers
518
views
Wrap text accounting for non-printing characters
[This question][1] asks about wrapping text at a certain column, and people suggest using `fold` or `fmt` but as far as I can see, these simply count characters and don't allow for non-printing characters. For example: fold -w 20 -s <<<`seq 1 25` as one might expect, produces: 1 2 3 4 5 6 7 8 9 10 1...
This question asks about wrapping text at a certain column, and people suggest using
fold
or fmt
but as far as I can see, these simply count characters and don't allow for non-printing characters. For example:
fold -w 20 -s <<<seq 1 25
as one might expect, produces:
1 2 3 4 5 6 7 8 9
10 11 12 13 14 15
16 17 18 19 20 21
22 23 24 25
but:
fold -w 20 -s <<<^[32mseq 1 25
^[[m
(where ^[
is the escape character) intuitively ought to produce the same thing in green text, but instead produces:
1 2 3 4 5 6 7
8 9 10 11 12 13 14
15 16 17 18 19 20
21 22 23 24 25
in green text.
I can't see any switches that say to account for non-printing characters, and the [PS1 approach to flagging non-printing characters doesn't seem to work with fold
or fmt
.
Is there something (ideally something standard) that can wrap text whilst accounting for non-printable characters?
----------
EDIT:
The example above is really to simplify and demonstrate the problem but I may have over-simplified. To clarify my real-world example, I've got text where some words are in colour (using ANSI escape sequences) and I'd like that to wrap neatly. For example:
Here is some example text that contains ^[[31mred^[[m and ^[[32mgreen^[[m words that I would like to wrap neatly.
where ^[
is the escape character.
If I wanted this to wrap to 20 columns, I would expect:
Here is some
example text that
contains red and
green words that
I would like to
wrap neatly.
(with "red" and "green" in colour) but because of the ANSI escape codes, it wraps thus:
Here is some
example text
that contains
red and
green words
that I would like
to wrap neatly.
IpsRich
(817 rep)
Feb 14, 2018, 09:11 AM
• Last activity: Feb 14, 2018, 10:40 AM
1
votes
1
answers
305
views
Text wrapping in Terminology
I just installed Enlightenment in OpenSuse Tumbleweed via YasT. I'm using E as the WM and entrance as the DM, if it matters. While checking its terminal emulator Terminology, I noticed that output lines larger than the width of the window get clipped i.e. if my window is 120 chars wide and the comma...
I just installed Enlightenment in OpenSuse Tumbleweed via YasT. I'm using E as the WM and entrance as the DM, if it matters.
While checking its terminal emulator Terminology, I noticed that output lines larger than the width of the window get clipped i.e. if my window is 120 chars wide and the command output 150 chars,only the first 120 chars of the output are printed - the rest is neither wrapped nor hidden "beyond the window border". If I resize the window to 150+ chars and rerun the command, I can see the full output.
I looked in Terminology's settings but didn't find a relevant attribute. The choice of names for both the WM and the emulator doesn't help when searching online and I've had no luck.
Thanks.
Gyan
(1065 rep)
Jun 12, 2017, 01:22 PM
• Last activity: Jun 14, 2017, 05:24 PM
5
votes
2
answers
1523
views
How to remove line wrapping from DNF & YUM commands?
When using `dnf` and `yum` on rpm based Linux distros (RHEL/Red Hat, Fedora, CentOS, etc) the utility will automatically wrap lines to make it more friendly for the user to read. This is problematic as it makes it extremely annoying to work with the data through pipelining. For example: $ dnf search...
When using
dnf
and yum
on rpm based Linux distros (RHEL/Red Hat, Fedora, CentOS, etc) the utility will automatically wrap lines to make it more friendly for the user to read. This is problematic as it makes it extremely annoying to work with the data through pipelining.
For example:
$ dnf search jenkins-ssh-credentials-plugin-javadoc
Last metadata expiration check: 6 days, 15:30:08 ago on Thu Sep 1 21:09:10 2016.
============= N/S Matched: jenkins-ssh-credentials-plugin-javadoc =============
jenkins-ssh-credentials-plugin-javadoc.noarch : Javadoc for jenkins-ssh-credentials-plugin
$ dnf search jenkins-ssh-credentials-plugin-javadoc | grep ssh
====== N/S Matched: jenkins-ssh-credentials-plugin-javadoc =======
jenkins-ssh-credentials-plugin-javadoc.noarch : Javadoc for
: jenkins-ssh-credentials-plugin
You can see that once the output for DNF is put through grep
it decides to wrap the data in a completely different way then when normally displayed to the user.
Multiple issues have been filed about this behavior ( [#584525](https://bugzilla.redhat.com/show_bug.cgi?id=584525) , [#986740](https://bugzilla.redhat.com/show_bug.cgi?id=986740) ) and consistently the issues are closed as CLOSED NOTABUG
because "Yum is an interactive text-based ui which is not suited, nor intended for piping.". The solution as per the Red Hat developers is to "use a different tool for the job."
It seems unreasonable to have to do this, especially when the methods supplied (install repoquery
for example) don't even _exist_ within the dnf
utilities and require installing a dozen more packages just to parse the output of this data.
Ideally a user would be able to just use the data in pipelining. In lieu of that, it would be nice to have a simple one-liner which could be used to make the data usable.
Brian Redbeard
(3168 rep)
Sep 8, 2016, 08:07 PM
• Last activity: Sep 8, 2016, 08:46 PM
Showing page 1 of 16 total questions