Search Results

Search: Posts Made By: Ste_Moore01
6,087
Posted By Ste_Moore01
Thanks for the help. Unfortunately,...
Thanks for the help.



Unfortunately, this isn't exaclty what I meant.

What I wanted was to be able to use VB6 to open a command prompt (which I've managed) and then telnet onto a server...
6,087
Posted By Ste_Moore01
DOS Equivalent of UNIX Command
Hi,

The title of this post is a little vague but I couldn't think of what to call it.

In Unix you can perform the following command
ftp -v IPADDRESS <<END
put FILE
END

In a DOS...
6,202
Posted By Ste_Moore01
Oh dear! I've just figured out what's...
Oh dear!

I've just figured out what's happened.

The file was created in Windows and I've not performed a dos2unix on it.

It must've been struggling with the control characters.

Thank...
6,202
Posted By Ste_Moore01
That doesn't work correctly. It removes...
That doesn't work correctly.

It removes sections of the file

<FUNCTION>
<PRODUCTS>
</PRODUCT>> DATA="1354298820"/> ACTION="amend" CODE="WESTCOAXX">
</PRODUCT>>...
1,038
Posted By Ste_Moore01
I appreciate the help, but putting the awk script...
I appreciate the help, but putting the awk script in a file provides the same error and using nawk doesn't bring back the data I want.

It looks to have stripped most of the data out.
...
1,038
Posted By Ste_Moore01
Thanks for the response, but I get the folowing...
Thanks for the response, but I get the folowing errors
awk: syntax error near line 1
awk: illegal statement near line 1
awk: syntax error near line 1
awk: illegal statement near line 1

All I...
1,038
Posted By Ste_Moore01
Problem With Replace Script
Hi,

I posted a topic requesting help with a script to replace certain things in an XML file

https://www.unix.com/shell-programming-scripting/202943-replace-string-newline-2.html

The...
6,202
Posted By Ste_Moore01
Sorry to bump this old thread, but I'm having...
Sorry to bump this old thread, but I'm having issues with this again.

I'm using the following
printf '%s\n' '1,$s/^ *//' '1,$s/ *$//' 'g/^<PRODUCT / .,/^<\/PRODUCT>/j' w | ed -s file

But...
6,229
Posted By Ste_Moore01
Thanks Don. I realised what Peasant meant...
Thanks Don.

I realised what Peasant meant with his post and it worked perfectly.

Thanks for the info on touch -m though.
6,229
Posted By Ste_Moore01
Thanks very much, Peasant. I looked through...
Thanks very much, Peasant.

I looked through the man page for touch and must've missed it.

Thanks!
6,229
Posted By Ste_Moore01
Amend File Without Changing Timestamp
Hi,

Is it possible to amend a file without changing the last modified date?

If it is, how do you do it?

If it's not, is there a way to create an empty file with the same timestamp as...
2,311
Posted By Ste_Moore01
Thanks that works perfectly!
Thanks that works perfectly!
2,311
Posted By Ste_Moore01
Bash Case Issues..
Hi,

I'm having some trouble with using "case...esac" in Bash.

I've googled it and am stuggling to understand the syntax and how to do certain things.

Firstly, I want to be able to choose...
6,202
Posted By Ste_Moore01
Sorry Lem, I must have been replying at the same...
Sorry Lem, I must have been replying at the same time as you.

I've just tried yours and it says
sed: command garbled

---------- Post updated at 04:30 PM ---------- Previous update was at...
6,202
Posted By Ste_Moore01
I realised that, but even when I do so it doesn't...
I realised that, but even when I do so it doesn't appear to be any different to the original file.
6,202
Posted By Ste_Moore01
I've just tried with nawk and I no longer get the...
I've just tried with nawk and I no longer get the errors but nothing appears to change.

Any suggestions?
6,202
Posted By Ste_Moore01
Thanks for the quick reply Unfortunately,...
Thanks for the quick reply

Unfortunately, this doesn't seem to work for me.

When I run it, it says
awk: syntax error near line 1
awk: illegal statement near line 1
awk: syntax error near...
6,202
Posted By Ste_Moore01
Replace String With Newline
Hi,

I'm struggling with a string replacement.

I have an XML file which is in the following layout
<FUNCTION>
<PRODUCTS>
<PRODUCT CODE="PRODUCE" ACTION="amend" VALIDATE="no">
...
3,019
Posted By Ste_Moore01
Deleting Files and Clearing Diskspace
Hi,

On our servers I have been removing files to clear up some diskspace.

If I do an ls -ltr command I can see a folder with quite a lot of data in it.

When I've gone into this folder and...
27,246
Posted By Ste_Moore01
Thanks Funksen, raw works for me too! ...
Thanks Funksen, raw works for me too!

---------- Post updated at 01:31 PM ---------- Previous update was at 12:54 PM ----------

Sorry to bother you again.

When I tried this previously, I...
27,246
Posted By Ste_Moore01
Thanks for the quick replies Franklin52 ...
Thanks for the quick replies

Franklin52
When I try your method I get the following errors
./test.sh: read: illegal option: -d
read: usage: read [-r] [-p prompt] [-a array] [-e] [name ...]...
27,246
Posted By Ste_Moore01
Bash KeyPress (or Read Single Character)
Hi,

I'm sorry if this has already been posted somewhere but I can't seem to find it on the forums (or anywhere on google :( )

I am writing a script where a user must enter a single character...
12,897
Posted By Ste_Moore01
Thanks for the quick replies. radoulov - I...
Thanks for the quick replies.

radoulov - I tired your method and didn't bring back any results. I'm not sure what I did wrong.

I tried
sed 's/></>\n</g' COMPGEAR.txt2010-07-01T083239.xml
...
12,897
Posted By Ste_Moore01
Replace 2 Character With One Using tr
Hi,

I have an XML file which is all on one line.

<?xml version="1.0" encoding="utf-8"?><FUNCTION><PRODUCTS><PRODUCT CODE="PROD1" ACTION="amend" VALIDATE="no"><SUPPLIER PRODUCT="SUPPPROD1"...
Showing results 1 to 24 of 24

 
All times are GMT -4. The time now is 08:11 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy