From 52a02a7a4bd6144a8d1089e49957b3e8bfbb57fc Mon Sep 17 00:00:00 2001 From: vilmibm Date: Wed, 27 May 2020 23:23:45 -0500 Subject: [PATCH] todo --- command/alias.go | 2 +- internal/config/alias_config.go | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/command/alias.go b/command/alias.go index 7cec65650..15295c160 100644 --- a/command/alias.go +++ b/command/alias.go @@ -11,7 +11,7 @@ import ( // TODO // - [ ] DEBUG support -// - [ ] blank aliases stanza +// - [x] blank aliases stanza // - [x] give our commands precedence // - [x] prevent overriding existing gh command // - [x] allow overwriting alias diff --git a/internal/config/alias_config.go b/internal/config/alias_config.go index bbeaba75c..23499f229 100644 --- a/internal/config/alias_config.go +++ b/internal/config/alias_config.go @@ -29,7 +29,8 @@ func (a *AliasConfig) Get(alias string) string { func (a *AliasConfig) Add(alias, expansion string) error { if a.Root == nil { - // TODO awful hack bad type conversion i'm sorry + // TODO awful hack bad type conversion i'm sorry. this is to support an empty aliases key and + // ought to be generalized into ConfigMap or fileConfig (via Config interface) itself. entry, err := a.Parent.(*fileConfig).FindEntry("aliases") var notFound *NotFoundError