materials_commons.cli.subcommands.ls module

materials_commons.cli.subcommands.ls.change_dataset_file_selection(proj, dataset_id, mcpaths, files_data, dirs_data, include=False, exclude=False, clear=False, out=<_io.TextIOWrapper name='<stdout>' mode='w' encoding='utf-8'>)[source]

Update the file selection dict

Parameters
  • proj (mcapi.Project) – Current project

  • dataset_id (str) – ID of dataset to be updated

  • mcpaths (list of str) – Materials Commons format file and directory paths

  • files_data – File comparisons from the treecompare function

  • dirs_data – Directory comparisons from the treecompare function

  • include (bool) – If True, include files and directories in “mcpaths” to the file selection

  • exclude (bool) – If True, exclude files and directories in “mcpaths” to the file selection

  • clear (bool) – If True, remove files and directories in “mcpaths” from the file selection so they are not included or excluded

  • out – Output stream

Returns

The file selection dict, updated.

materials_commons.cli.subcommands.ls.ls_subcommand(argv, working_dir)[source]

‘ls’ a project directory to see local and remote files and directories.

mc ls [<pathspec> …]

materials_commons.cli.subcommands.ls.make_parser()[source]

Make argparse.ArgumentParser for mc ls