MCPcopy Index your code
hub / github.com/jeffkaufman/icdiff / format_label

Function format_label

icdiff.py:895–902  ·  view source on GitHub ↗

Format a label using a file's path and basename. Example: For file `/foo/bar.py` and label "Yours: {basename}" - The output is "Yours: bar.py"

(path, label="{path}")

Source from the content-addressed store, hash-verified

893
894
895def format_label(path, label="{path}"):
896 """Format a label using a file's path and basename.
897
898 Example:
899 For file `/foo/bar.py` and label "Yours: {basename}" -
900 The output is "Yours: bar.py"
901 """
902 return label.format(path=path, basename=os.path.basename(path))
903
904
905def diff_files(options, a, b):

Callers 1

diff_filesFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected