View xml files like a pro
Viewing XML files can be daunting with tracking mentally where the tag starts and where it ends. So, I ended up with the following alias to help me view xml files
xmllint --format - | pygmentize -f 16m -O style=native -g
Viewing XML files can be daunting with tracking mentally where the tag starts and where it ends. So, I ended up with the following alias to help me view xml files
xmllint --format - | pygmentize -f 16m -O style=native -g
There is a small nifty utility called xmlwf that can check your xml documents to see if they are well formed.
sudo yum install expat
Once installed, simply use :
xmlwf
Need more details, just check the man page 🙂
Continuing from where we left, here is a script that can do all this for you 🙂
curl http://ubuntuforums.org/showthread.php?t=281865\&page=$i | sed -n '/\\/pr/ p'| sed '// d'| sed 's##\n-----------------------------------\n\n\n#' >conkyrc dos2unix conkyrc cp conkyrc .test while [ $(wc -l .test|sed 's/[^0-9]//g') != 0 ] do sed -n '1,/------------------------/ p' .test|sed '$d' >conkyrc.$count diff .test conkyrc.$count |sed 's/^<.//'|sed '1, /---------------------/ d;2d'>.test ((count++)) done
This will create couple of conkyrc.files in the current directory. Each of these is one from the web-page that I mentioned earlier. So, enjoy….
Continue readingFirst install afraid-dyndns with the command:
1
|
Now open the configuration file /etc/afraid-dyndns.cfg and we need to change the following:
Notify = root@localhost # leave empty to suppress notifications
CacheFile = /var/cache/afraid-dyndns/IP
AccountHash =
For the Account hash, head over to http://freedns.afraid.org/api/ login and then click one of the XML or the ASCII links there. Once the page has loaded, look at the URL which is of form:
Continue readingSince I updated to the <a class="zem_slink freebase/en/fedora" title="Fedora" rel="homepage" href="http://fedoraproject.org/">Fedora 13, I was getting error from the <a class="zem_slink freebase/en/dynamic_dns" title="Dynamic DNS" rel="wikipedia" href="http://en.wikipedia.org/wiki/Dynamic_DNS">Dynamic DNS client for afraid. I was not getting enough time to fix this, so finally I decided to fix this in the night itself 🙂
Problem:
On running
afraid-dyndns
I was getting the error:
Entity: line 100: <a class="zem_slink freebase/en/parsing" title="Parsing" rel="wikipedia" href="http://en.wikipedia.org/wiki/Parsing">parser error : Opening and ending tag mismatch: br line 99 and div
Continue reading