diff --git a/src/west/commands/project.py b/src/west/commands/project.py index 5d47c2c..3f60049 100644 --- a/src/west/commands/project.py +++ b/src/west/commands/project.py @@ -479,7 +479,7 @@ def _fetch(project): if not exists: _inf(project, 'Creating repository for (name-and-path)') _git_base(project, 'init (abspath)') - _git(project, 'remote add origin -- (url)') + _git(project, 'remote add -- (remote-name) (url)') # Fetch the revision specified in the manifest into the manifest-rev branch @@ -495,7 +495,7 @@ def _fetch(project): # when the revision is an annotated tag. ^{commit} type peeling isn't # supported for the in a : refspec, so we have to do it # separately. - _git(project, fetch_cmd + ' origin -- (revision)') + _git(project, fetch_cmd + ' -- (remote-name) (revision)') _git(project, 'update-ref (qual-manifest-rev-branch) FETCH_HEAD^{commit}') if not _ref_ok(project, 'HEAD'): @@ -753,6 +753,7 @@ def _expand_shorthands(project, s): .replace('(name-and-path)', '{} ({})'.format( project.name, os.path.join(project.path, ""))) \ + .replace('(remote-name)', project.remote.name) \ .replace('(url)', project.url) \ .replace('(path)', project.path) \ .replace('(abspath)', project.abspath) \