Skip to content

alexandriagroup/soup

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

soup

soup picture

Extract the values requested from XML files using BeautifulSoup.

Usage

  • Print the text for all the nodes ASIN

      soup 'ASIN' <file1> [<file2> ...]
    
  • Print the text for multiple nodes

      soup 'ASIN','created_at' <file1> [<file2> ...]
    
  • Print all the children in a given tag

      soup --children ItemAttributes <file> [<file2> ...]
    
  • Print all the children and their values

      soup --children --values ItemAttributes <file> [<file2> ...]
    

Installation

  • With poetry:

      poetry install
    
  • Manually:

      pip install beautifulsoup4
      cp soup/core.py <somepath>/soup
    

Acknowledgement

Photo by Charles Koh on Unsplash.

About

Extract values from XML with BeautifulSoup

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages