You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mynewt.apache.org by cc...@apache.org on 2017/03/09 23:29:32 UTC

[1/2] incubator-mynewt-newt git commit: Remove trailing slash using pkg commands in the shell

Repository: incubator-mynewt-newt
Updated Branches:
  refs/heads/develop 04972811d -> 0f9e3f78d


Remove trailing slash using pkg commands in the shell


Project: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-newt/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-newt/commit/008834c5
Tree: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-newt/tree/008834c5
Diff: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-newt/diff/008834c5

Branch: refs/heads/develop
Commit: 008834c57cdedf0b2117fcc4f440f01b2f162feb
Parents: 7ecee8b
Author: Fabio Utzig <ut...@utzig.org>
Authored: Mon Mar 6 15:54:18 2017 -0300
Committer: Fabio Utzig <ut...@utzig.org>
Committed: Mon Mar 6 15:54:18 2017 -0300

----------------------------------------------------------------------
 newt/cli/pkg_cmds.go      | 2 +-
 newt/newtutil/newtutil.go | 3 +++
 2 files changed, 4 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-mynewt-newt/blob/008834c5/newt/cli/pkg_cmds.go
----------------------------------------------------------------------
diff --git a/newt/cli/pkg_cmds.go b/newt/cli/pkg_cmds.go
index 315ae89..472369b 100644
--- a/newt/cli/pkg_cmds.go
+++ b/newt/cli/pkg_cmds.go
@@ -60,7 +60,7 @@ func pkgNewCmd(cmd *cobra.Command, args []string) {
 type dirOperation func(string, string) error
 
 func pkgCopyCmd(cmd *cobra.Command, args []string) {
-	pkgCloneOrMoveCmd(cmd, args, util.CopyDir, "Cloning")
+	pkgCloneOrMoveCmd(cmd, args, util.CopyDir, "Copying")
 }
 
 func pkgMoveCmd(cmd *cobra.Command, args []string) {

http://git-wip-us.apache.org/repos/asf/incubator-mynewt-newt/blob/008834c5/newt/newtutil/newtutil.go
----------------------------------------------------------------------
diff --git a/newt/newtutil/newtutil.go b/newt/newtutil/newtutil.go
index 48ef4a0..83e0179 100644
--- a/newt/newtutil/newtutil.go
+++ b/newt/newtutil/newtutil.go
@@ -213,6 +213,9 @@ func GetStringSliceFeatures(v *viper.Viper, features map[string]bool,
 //         string               package name
 //         error                if invalid package string
 func ParsePackageString(pkgStr string) (string, string, error) {
+	// remove possible trailing '/'
+	pkgStr = strings.TrimSuffix(pkgStr, "/")
+
 	if strings.HasPrefix(pkgStr, "@") {
 		nameParts := strings.SplitN(pkgStr[1:], "/", 2)
 		if len(nameParts) == 1 {


[2/2] incubator-mynewt-newt git commit: This closes #51.

Posted by cc...@apache.org.
This closes #51.

Merge remote-tracking branch 'utzig/fix-trailing-slash' into develop

* utzig/fix-trailing-slash:
  Remove trailing slash using pkg commands in the shell


Project: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-newt/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-newt/commit/0f9e3f78
Tree: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-newt/tree/0f9e3f78
Diff: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-newt/diff/0f9e3f78

Branch: refs/heads/develop
Commit: 0f9e3f78d731e9364264f664350ff6c7eb8b94f2
Parents: 0497281 008834c
Author: Christopher Collins <cc...@apache.org>
Authored: Thu Mar 9 15:28:23 2017 -0800
Committer: Christopher Collins <cc...@apache.org>
Committed: Thu Mar 9 15:28:23 2017 -0800

----------------------------------------------------------------------
 newt/cli/pkg_cmds.go      | 2 +-
 newt/newtutil/newtutil.go | 3 +++
 2 files changed, 4 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-mynewt-newt/blob/0f9e3f78/newt/newtutil/newtutil.go
----------------------------------------------------------------------