Search Results

Search: Posts Made By: stomp
Forum: Shell Programming and Scripting 8 Hours Ago
521
Posted By stomp
My code is tested and works. But don't rely on...
My code is tested and works. But don't rely on that. Think/Learn how to know and test if the code is working correctly.

The error is that the call of your program is somehow wrong or not like the...
521
Posted By stomp
This thread needs way more time and energy than...
This thread needs way more time and energy than I'm willing to give. I'm out.
521
Posted By stomp
Correct Usage of quoting ;-)
Hello Psy,


Please don't full quote forum posts. Please only quote the short passage of text you're relating to. Refrain from full quoting because it adds redundant information and makes the...
521
Posted By stomp
Just use the function with the same var as in...
Just use the function with the same var as in your code:


mk_json... "$var" "${addr_arr[@]}"



That doesn't work. Single quotes do not execute variable substitution. You need double quotes...
521
Posted By stomp
@psysc0rpi0n...
@psysc0rpi0n (https://www.unix.com/member_modal.php?u=302183235&modal=1) Great! You did it! Your code is good.

One of my goal in programming is trying to create code which is readable well. So I...
521
Posted By stomp
Notes: maybe you can spare the escaping...
Notes:

maybe you can spare the escaping of " if you mix ' (single quotes) and " (double quotes).
simple shell scripting will suffice for what you want to achieve, jq seems not necessary(but...
521
Posted By stomp
For simple JSON tasks jq is a versatile tool for...
For simple JSON tasks jq is a versatile tool for querying, manipulating and creating JSON within a Shell script. You'll find a lot of usage examples in the web and of course in the excellent jq...
675
Posted By stomp
Your json is different from mine. As the error...
Your json is different from mine. As the error message states numbers and strings cannot be added. You have to convert the number to a string before concatenating both:


... (number_var|tostring)...
675
Posted By stomp
Hi SDohmen, nice to hear that you worked...
Hi SDohmen,

nice to hear that you worked your way through and thanks for giving feedback.

Some comments:



That's why I pointed out XPath for you twice and presented you links for a good...
464
Posted By stomp
Hi Mohtashims, I'm now sitting on my...
Hi Mohtashims,

I'm now sitting on my notebook and I checked the two different Debug-Outputs of the 2 ssh connections. I clearly see differences.

I assume, you have - as I suggested - to debug...
464
Posted By stomp
Check the log of the ssh server and increase log...
Check the log of the ssh server and increase log level of the ssh server before that to DEBUG/DEBUG2.

I'm sorry I didn't read the ssh debug output. It's difficult to read on my very small mobile...
292
Posted By stomp
Your read statement is out of the loop. So it's...
Your read statement is out of the loop. So it's stuck infinitely, because $url never changes.

One suggestion:


while : ; do
read url
[ "$url" == exit ] && break
wget ...
done
Forum: What is on Your Mind? 1 Week Ago
332
Posted By stomp
Thanks a lot!
Thanks a lot!
675
Posted By stomp
A little help for what you've nearly got...
A little help for what you've nearly got yourself:

xmlstarlet sel -t -m //searchresults/data/products -v "concat(';',idproduct)" -n purchaseorders.xmlThis will give you the ordered products, like...
Forum: What is on Your Mind? 1 Week Ago
332
Posted By stomp
Disable More Discussions You Might Find Interesting in Mobile View
Hi,

for quite a while this feature "xxx More Discussions You Might Find Interesting" is added below a topic here.

For desktop view this is ok. I didn't make use of it so far, but it isn't...
415
Posted By stomp
use "$@" (= all parameters, quoted). There is a...
use "$@" (= all parameters, quoted). There is a lot further interesting to know about parameters. see man bash
298
Posted By stomp
@MohSalNiz This is not connected to the...
@MohSalNiz

This is not connected to the issue in this thread. Please open another thread for your issue.
675
Posted By stomp
What did I do to find the solution? ...
What did I do to find the solution?


Read some Tutorials about XPath
Reached out for xmlstarlet documentation
Used google a lot on the subject, learned from many examples(stackoverflow...
Forum: Programming 1 Week Ago
1,392
Posted By stomp
It is. I'm currently working with cygwin. It's a...
It is. I'm currently working with cygwin. It's a reliable way to get many of the essential tools if you have to use windows. But it's a bit slow. I don't know, if it's fast enough for this program.
675
Posted By stomp
Hi SDohmen, some additional bits of...
Hi SDohmen,

some additional bits of Knowledge about XPath will lead you forward towards your solution. Especially try to get information about how to figure out "parent nodes" of your target...
566
Posted By stomp
If your original scripts are that simple, I would...
If your original scripts are that simple, I would be surprised if there's no possibility to do it.

Those techs (stock windows) will probably enable you to script a solution:

Visual Basic...
532
Posted By stomp
I used lsyncd to migrate(p2v) servers to...
I used lsyncd to migrate(p2v) servers to minimize downtime when migrating. Had lot's of files(1K-1M).

Like plain rsync it's good for a lot of things. It's very bad for syncing big files which...
566
Posted By stomp
I want to have a script that parses another...
I want to have a script that parses another script and does the job in another order.


I would not say this isn't possible, but extremely complex to parse any scripting language or shell. I...
559
Posted By stomp
full=helloworld part=low if [[ $full =~...
full=helloworld
part=low
if [[ $full =~ $part ]] ; then
echo bingo
fi
566
Posted By stomp
It may be not that simple, to reverse a script. ...
It may be not that simple, to reverse a script.

For example, if you have a file consisting of a and b characters. Your normal script replaces a with b. How do you reverse that? It's not possible...
Showing results 1 to 25 of 375

 

Featured Tech Videos

All times are GMT -4. The time now is 02:39 PM.
Unix & Linux Forums Content Copyright 1993-2019. All Rights Reserved.
Privacy Policy