Hello,
Please, give me an advice,
how to set the / for my script, to it accidentally no to "bound out" the borders of my "program" that consist of a lot of a sh scripts.
Should I choose the "chroot" for this?
Peace
Hello,
I've entered man read from sh shell
and saw pushd and popd inside
but there is no such builtin in sh, it's bash' builtin,
Which command should I use for referencing sh builtins?
Hello, I'm trying to understand the process of starting scripts and understand shell itself.
I would like to ask:
what is $rc_fast_and_loose?
in
if [ -n "$rc_fast_and_loose" ]; then
set $_arg; . $_file
what is -n here? is it
True if the length of "STRING" is non-zero. ?
and what...
I did a find / -name 'XXX' and the output is insane. It lists every file and the list never ends (I had to Ctrl-C to stop it).
How can I view the results meaningfully? For example, I'd like to limit to the result to appear only for, say the top-level (or top 2nd or 3rd level) directories only...
I think I asked this question sometime ago, but I can't find the answer when searching for it. Anyway...
First, I think I know the difference for startup shell scripts located in /etc/rc.d and /usr/local/etc/rc.d. The former is for system scripts while the latter is for user-installed scripts...
I'm using FreeBSD version: 11.3-RELEASE-p14, Shell version: tcsh 6.20.00 (Astron) 2016-11-24 (x86_64-amd-FreeBSD) options wide, nls, dl,al, kan, sm, rh, color, filec and trying to use cut to harvest fields in a string variable, with no success.
#! /bin/sh
.
# Variables
filelength=0
start=0...
Hi!
Why does sed exaust "sed: rename(): Not a directory" called
sed -i ~ 's/^\#\+\(PermitRootLogin\) .*$/\1 yes/g' /etc/ssh/sshd_config
The manual states:
-i extension
Edit files in-place similarly to -I, but treat each file
independently from other files. In...
I would like one of my hosts to broadcast occasional periodic signals to a shell script running on other host(s) on the same LAN.
I'm currently reading about various IoT protocols, but I'm wondering what the more traditional approaches were for this kind of messaging.
Ideally, I'd want some...
I'd liked to use the 'a' function of sed to append something after a given line in a file.
For instance, I want to add "ListenAddress xx.xx.xxx.xxx" after the line that begins with "#ListenAddress" in a copy of sshd_config:
Using sh I do:
# IP=xx.xx.xxx.xxx
# sed -E -i ""...
If I execute the command:
setenv PATH "/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/sbin:/usr/local/bin:/root/bin:/root/.cargo/bin"
after going into the jail by "jexec 1", it would work. However, I'd like to make it sticky. I tried many ways but nothing works.
Further, preferably, I'd like to do...
How would I change the text color in shells/ion shell?
The color for some texts is too similar to the background on my display.
From the directory, /usr/local/share/doc/ion/:
migrating.md
variables/07-namespaces.md has a lot of information on color schemes for Ion.
When I switch to a...
I'm trying to extract from a tarball. (I don’t need help with that.)
But I get this nonsense:
Pathname can’t be converted from UTF-8 to current locale
When I enter the command locale the LANG= line is empty.
Hoo boy
Yup! everything that's easy in any version of linux is like being...
What is everyone using as there default shell. I currently use zsh, but I wonder if anyone is just using /bin/sh or if tcsh is good enough for daily usage? Just looking for others opinions on the matter.
Looks like /bin/sh is Bourne Shell? Hows this differ from Bash?
FreeBSD 12.1 - Updated System & "su" root user no longer shows root@domain.tld; blank #
I am not sure what happened or how to revert the changes that a system "pkg upgrade" did to my installation.
I used to ssh in and get user@domain.tld ... then issue "su" and get "root@domain.tld" ; now it's...
Hi
I have written some shell scripts (bourne shell not bash)
for basic video and audio editing tasks with ffmpeg
A lot of the open source video editors dont really compare to Final Cut Pro or Davinci Resolve,
and can be difficult to get hardware encoding working
Thats why i decided to write...
so this script can alter the url to data64 encoding by matching in css file background-image: url(afdsf.png).
some contribute this:
echo 'background-image: url("../images/doesntmatter/imgDoesNotMatter.png");' | sed -r 's,background-image\s*:\s*url\("(.+)"\);,\1,'...
I am looking to parse a file for specific content that is on a line that always has a specific beginning,
for example:
"Program: code"
I want to extract code on the line that starts with Program.
I then want to add that extracted string into an already created file.
Can anyone provide some...
I would like to share HOWTO in Ghost in the Shell series about efficient working in the UNIX shell environment.
Ghost in the Shell - Part 4
https://vermaden.wordpress.com/2019/03/15/ghost-in-the-shell-part-4/
Regards,
vermaden
Hi!
/bin/sh (Almquist shell) with vi mode (set -o vi) starts every new line at insert mode.
So I must press Esc every new prompt if I want to go through history.
Is it possible to start shell prompts with "vi command (normal) mode"?
I would like to share HOWTO in Ghost in the Shell series about efficient working in the UNIX shell environment.
Ghost in the Shell - Part 3
https://vermaden.wordpress.com/2018/09/15/ghost-in-the-shell-part-3/
Regards,
vermaden
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.