MCPcopy
hub / github.com/InstaPy/InstaPy / get_workspace

Function get_workspace

instapy/file_manager.py:30–46  ·  view source on GitHub ↗

Make a workspace ready for user

()

Source from the content-addressed store, hash-verified

28
29
30def get_workspace():
31 """Make a workspace ready for user"""
32
33 if WORKSPACE["path"]:
34 workspace = verify_workspace_name(WORKSPACE["path"])
35
36 else:
37 home_dir = get_home_path()
38 workspace = "{}/{}".format(home_dir, WORKSPACE["name"])
39
40 message = 'Workspace in use: "{}"'.format(workspace)
41 highlight_print(
42 Settings.profile["name"], message, "workspace", "info", Settings.logger
43 )
44 update_workspace(workspace)
45 update_locations()
46 return WORKSPACE
47
48
49def set_workspace(path=None):

Callers 1

__init__Method · 0.85

Calls 5

verify_workspace_nameFunction · 0.85
get_home_pathFunction · 0.85
highlight_printFunction · 0.85
update_workspaceFunction · 0.85
update_locationsFunction · 0.85

Tested by

no test coverage detected