MCPcopy
hub / github.com/catppuccin/catppuccin / get_working_dir

Method get_working_dir

samples/python1.py:680–690  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

678 return bool(self.get_working_dir())
679
680 def get_working_dir(self):
681 if self._active_file_name():
682 working_dir = super(UncommittedFilesCommand, self).get_working_dir()
683 if working_dir and get_vcs(working_dir):
684 return working_dir
685
686 # If the user has opened a vcs folder, use it.
687 folders = self.window.folders()
688 for folder in folders:
689 if folder and os.path.exists(folder) and get_vcs(folder):
690 return folder
691
692 def run(self):
693 self.vcs = get_vcs(self.get_working_dir())

Callers 2

is_enabledMethod · 0.95
runMethod · 0.95

Calls 3

get_vcsFunction · 0.85
_active_file_nameMethod · 0.80
get_working_dirMethod · 0.45

Tested by

no test coverage detected