Solved

Get value without quotes using curl and sed

Posted on 2013-11-08
1
236 Views
Last Modified: 2013-11-08
This does what I want except I do not want the quotations at the beginning and end:
curl -sk 'https://zuhqtr5.couchappy.com/site/www/' | sed -e 's/[{}]/''/g' | awk -v RS=',"' -F: '/^_rev/ {print $2}'

Open in new window

How can I get the same results without the quotes?
0
Comment
Question by:hankknight
1 Comment
 
LVL 19

Accepted Solution

by:
simon3270 earned 500 total points
Comment Utility
If you want all quotes removed from the string, add:
    | tr -d "'"'"'
to the end of the command - that deletes all double and single quotes
(it's double single double single double single)
0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

I am a long time windows user and for me it is normal to have spaces in directory and file names. Changing to Linux I found myself frustrated when I moved my windows data over to my new Linux computer. The problem occurs when at the command line.…
Introduction We as admins face situation where we need to redirect websites to another. This may be required as a part of an upgrade keeping the old URL but website should be served from new URL. This document would brief you on different ways ca…
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now