unix -https url download content and the same move another location [closed] - linux

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 9 months ago.
Improve this question
i have URL https://my.waves.com/:r:/documents%20-/csv%20upload that loaded the screen then show edc_data.csv
above file edc_data.csv file move unix Location(/equ/str/loaded)
can you please how to write shellscripts

Assuming your URL https://my.waves.com/:r:/documents%20-/csv%20upload is correct and links to a CSV file, you can use this script:
#!/bin/sh
curl -L 'https://my.waves.com/:r:/documents%20-/csv%20upload' > /equ/str/loaded/edc_data.csv
exit 0
This will download the file edc_data.csv and put it directly in /equ/str/loaded/.

Related

Delete the particular line in files using bash script [closed]

Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 3 days ago.
Improve this question
Write a program to open the file and delete a specific line from a text file. The line number of the line to be replaced is asked as input. A new file is opened in write mode named output.txt. The input file name should be input.txt and output file name should be output.txt.
someone please help me through it

How to convert a temp folder( .tmp ) to a binary file ( .bin) in Linux [closed]

Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 2 years ago.
Improve this question
enter image description here
enter image description herei.stack.imgur.com/emphasized text8kFIB.png
I want to convert the folder into a binary file(.bin),I tried to write a shell file, but it not generate the correct binary file,I do not know how to solve it,maybe my solution is wrong.Someone tells me that I can use the command zip,I can not agree....C
From your remark about zip, it seems you are trying to make an archive. One simple way to create an archive of a directory is with tar:
tar -zcf foo.tgz /path/to/foo
Note that this will create a file named foo.tgz rather than *.bin, but .... you don't really want to use the bin suffix for a tarball.

Replace URL in markdown files in python [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 2 years ago.
Improve this question
I have big markdown file. Is there any way to change /foo in my url by /bla. That is, I want to replace
[text](/foo/some-long-url/a.html)
for
[text](/bla/some-long-url/a.html)
(all ocurrences).
I know I could compile markdown file to html and use html parsers (like BeautifulSoup) to do that. But I want to do that, on the source file.
Prefered python or shell solutions.
I mean you can always replace "/foo" to "/bla" directly in the source using sed?
sed 's/\/foo/\/bla/' source.md >> destination.md
If it catches anything unwanted, you can just tweak the regular expression a bit to be more specific.

I need a linux script to report all error lines from a log file, and export the results of error lines into a .csv file? [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 4 years ago.
Improve this question
I have log file for checking transactions, and I have error lines, so I need those error lines to be exported to a .csv file? is there any code using linux bash shell script can do this?
suppose your error lines consists ERROR.
then
grep "ERROR" errorfile.txt | tr -s '[:blank:]' ',' >> errorfile.csv
csv conversion is based on blank spaces to each cell.you can replace blank filter with anything

Convert xlsx to text CSV via command line only on Linux [closed]

Closed. This question is off-topic. It is not currently accepting answers.
Want to improve this question? Update the question so it's on-topic for Stack Overflow.
Closed 9 years ago.
Improve this question
Simple question:
Is it currently possible to invoke LibreOffice from a command line to open a *.xlsx and convert/save it as a *.csv?
Alternatively, if this is not possible what is the current best method for doing this via command line (needs to be invokable via script)?
Thanks,
Here is the command:
localc --headless --convert-to csv:"Text - txt - csv (StarCalc)" *.xlsx
The above will save all converted files in current directory(directory from where you'll run the command). All converted files will have their filename extensions changed to csv.
Alternative, method is the use of unoconv which i've not used.

Resources