Skip to content

LICENSE ? #31

Description

@mankoff

I'm interested in using this function:

def parse_hdfeos_metadata(string):
out = {}
lines0 = [i.replace('\t','') for i in string.split('\n')]
lines = []
for line in lines0:
if "=" in line:
key = line.split('=')[0]
value = '='.join(line.split('=')[1:])
lines.append(key.strip()+'='+value.strip())
else:
lines.append(line)
i = -1
while i < (len(lines))-1:
i += 1
line = lines[i]
if "=" in line:
key = line.split('=')[0]
value = '='.join(line.split('=')[1:])#.join('=')
if key in ['GROUP', 'OBJECT']:
endIdx = lines[i+1:].index('END_{}={}'.format(key, value))
endIdx += i+1
out[value] = parse_hdfeos_metadata("\n".join(lines[i+1:endIdx]))
i = endIdx
elif ('END_GROUP' not in key) and ('END_OBJECT' not in key):
out[key] = str(value)
return out

Does your project have a license so I know if I can incorporate some of your code into mine?

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions