Giter Site home page Giter Site logo

cmakelists_parsing's People

Contributors

hypergraphs avatar ijt avatar jimon avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

cmakelists_parsing's Issues

AttributeError: 'Command' object has no attribute 'comments'

Example run:

import cmakelists_parsing.parsing as cmp
cmp.parse("""include_directories(
  # aa
  include
)""")

Result:

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/user/.local/lib/python3.8/site-packages/cmakelists_parsing/parsing.py", line 50, in parse
    nums_items = list(parse_file(nums_toks))
  File "/home/user/.local/lib/python3.8/site-packages/cmakelists_parsing/parsing.py", line 107, in parse_file
    line_nums, cmd = parse_command(line_num, tok_contents, toks)
  File "/home/user/.local/lib/python3.8/site-packages/cmakelists_parsing/parsing.py", line 142, in parse_command
    cmd.comments.append(c)
AttributeError: 'Command' object has no attribute 'comments'

Parser is misusing its own API: Command-objects have attribute comment not comments.

convert to yaml ast tree

Hi,

Hope you are all well !

I was wondering if it is possible to output the tree into a yaml file ?

I would like to extract find_package options in order to build them form sources for my docker images.

Have a good day !

Cheers,
Richard

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.