File: export.py

package info (click to toggle)
fpga-icestorm 0~20160913git266e758-3
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 3,628 kB
  • ctags: 1,871
  • sloc: python: 15,333; cpp: 3,356; sh: 1,598; ansic: 531; makefile: 417
file content (10 lines) | stat: -rw-r--r-- 382 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
#!/usr/bin/env python3

with open("../icebox/iceboxdb.py", "w") as f:
    for i in [ "database_io", "database_logic", "database_ramb", "database_ramt", "database_ramb_8k", "database_ramt_8k" ]:
        print('%s_txt = """' % i, file=f)
        with open("%s.txt" % i, "r") as fi:
            for line in fi:
                print(line, end="", file=f)
        print('"""', file=f)