Merge ~bloodearnest/snapstore-client:rename into snapstore-client:master

Proposed by Simon Davy
Status: Merged
Approved by: Simon Davy
Approved revision: 9a61cdbcb3a365acc781f413e7f4c2d48172a9fc
Merge reported by: Otto Co-Pilot
Merged at revision: not available
Proposed branch: ~bloodearnest/snapstore-client:rename
Merge into: snapstore-client:master
Diff against target: 210 lines (+32/-23)
10 files modified
.gitignore (+3/-0)
Makefile (+1/-1)
docs/en/client.md (+7/-7)
snap/snapcraft.yaml (+9/-5)
snapstore_client/config.py (+1/-1)
snapstore_client/logic/overrides.py (+3/-3)
snapstore_client/logic/tests/test_overrides.py (+3/-3)
snapstore_client/tests/factory.py (+1/-1)
snapstore_client/tests/test_config.py (+2/-1)
snapstore_client/tests/testfixtures.py (+2/-1)
Reviewer Review Type Date Requested Status
Colin Watson (community) Approve
Review via email: mp+349640@code.launchpad.net

Commit message

rename snap to snap-store-proxy-client

To post a comment you must log in.
e41ce07... by Simon Davy

remove state files

893e8e5... by Simon Davy

remove debugging

Revision history for this message
Colin Watson (cjwatson) :
review: Approve
Revision history for this message
Simon Davy (bloodearnest) :
9a61cdb... by Simon Davy

add clarifying comment about py3.5

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1diff --git a/.gitignore b/.gitignore
2index 5d2c033..5d9d1bb 100644
3--- a/.gitignore
4+++ b/.gitignore
5@@ -4,3 +4,6 @@ __pycache__/
6 /.coverage
7 /htmlcov
8 docs/build
9+parts
10+prime
11+stage
12diff --git a/Makefile b/Makefile
13index a3b3b78..d8f1bd4 100644
14--- a/Makefile
15+++ b/Makefile
16@@ -16,7 +16,7 @@ $(SNAPSTORE_DEPENDENCY_DIR):
17 git clone $(DEPENDENCY_REPO) $(SNAPSTORE_DEPENDENCY_DIR)
18
19 $(ENV)/prod: | $(SNAPSTORE_DEPENDENCY_DIR)
20- virtualenv $(ENV) --python=python3
21+ virtualenv $(ENV) --python=python3.5 # pin to 3.5 as that is what core 16 is
22 $(PIP) install -f $(SNAPSTORE_DEPENDENCY_DIR) --no-index -r requirements.txt
23 touch $@
24
25diff --git a/docs/en/client.md b/docs/en/client.md
26index a1cfc9e..6a23103 100644
27--- a/docs/en/client.md
28+++ b/docs/en/client.md
29@@ -7,7 +7,7 @@ Installation
30
31 The snapstore client can be installed from the snap store:
32
33- snap install snapstore-client
34+ snap install snap-store-proxy-client
35
36 Configuration
37 =============
38@@ -18,19 +18,19 @@ the [Ubuntu SSO provider](https://login.ubuntu.com).
39
40 From the command line on the machine that has the Proxy installed, run:
41
42- sudo snapstore add-admin becky@example.com
43+ sudo snap-proxy add-admin becky@example.com
44
45 Once the user has been registered, the client can login:
46
47- snapstore-client login
48+ snap-store-proxy-client login [address of proxy]
49
50 Usage
51 =====
52
53-snapstore-client provides the same command line interface for managing overrides
54+snap-store-proxy-client provides the same command line interface for managing overrides
55 as the CLI client installed with the Proxy. It cannot configure any system
56 settings for the Proxy.
57
58- snapstore-client list-overrides
59- snapstore-client override foo stable=10
60- snapstore-client delete-override foo
61+ snap-store-proxy-client list-overrides
62+ snap-store-proxy-client override foo stable=10
63+ snap-store-proxy-client delete-override foo
64diff --git a/snap/snapcraft.yaml b/snap/snapcraft.yaml
65index ff7c8a6..f234ee1 100644
66--- a/snap/snapcraft.yaml
67+++ b/snap/snapcraft.yaml
68@@ -1,15 +1,15 @@
69-name: snapstore-client
70-version: 1.0beta
71-summary: Canonical snapstore administration client.
72+name: snap-store-proxy-client
73+version: 1.0
74+summary: Canonical snap store proxy administration client.
75 description: |
76- The Canonical snapstore client is used to manage a snapstore.
77+ The Canonical snapstore client is used to manage a snap store proxy.
78
79 # Defaults, but snapcraft prints ugly yellow messages without them.
80 confinement: strict
81 grade: stable
82
83 apps:
84- snapstore-client:
85+ snap-store-proxy-client:
86 command: ./snapstore
87 plugs:
88 - network
89@@ -26,3 +26,7 @@ parts:
90 stage:
91 - ./snapstore
92 - ./snapstore_client/
93+ override-prime: |
94+ snapcraftctl prime
95+ /snap/core/current/usr/bin/python3 -m compileall -q -j0 snapstore_client
96+
97diff --git a/snapstore_client/config.py b/snapstore_client/config.py
98index ca7beb9..a01e975 100644
99--- a/snapstore_client/config.py
100+++ b/snapstore_client/config.py
101@@ -12,7 +12,7 @@ from xdg import BaseDirectory
102
103 class Config:
104
105- xdg_name = 'snapstore-client'
106+ xdg_name = 'snap-store-proxy-client'
107
108 def __init__(self):
109 self.parser = configparser.ConfigParser()
110diff --git a/snapstore_client/logic/overrides.py b/snapstore_client/logic/overrides.py
111index 5749988..667bd0a 100644
112--- a/snapstore_client/logic/overrides.py
113+++ b/snapstore_client/logic/overrides.py
114@@ -20,13 +20,13 @@ logger = logging.getLogger(__name__)
115
116 def _log_credentials_error(e):
117 logger.error('%s', e)
118- logger.error('Try to "snapstore-client login" again.')
119+ logger.error('Try to "snap-store-proxy-client login" again.')
120
121
122 def _log_authorized_error():
123 logger.error(("Perhaps you have not been registered as an "
124 "admin with the proxy."))
125- logger.error("Try 'snapstore add-admin' on the proxy host.")
126+ logger.error("Try 'snap-proxy add-admin' on the proxy host.")
127
128
129 def _check_default_store(cfg):
130@@ -36,7 +36,7 @@ def _check_default_store(cfg):
131 if not store.get('gw_url'):
132 logger.error(
133 'No store configuration found. '
134- 'Have you run "snapstore-client login"?')
135+ 'Have you run "snap-store-proxy-client login"?')
136 return None
137 return store
138
139diff --git a/snapstore_client/logic/tests/test_overrides.py b/snapstore_client/logic/tests/test_overrides.py
140index 08a85af..1f2f2d0 100644
141--- a/snapstore_client/logic/tests/test_overrides.py
142+++ b/snapstore_client/logic/tests/test_overrides.py
143@@ -29,7 +29,7 @@ class OverridesTests(TestCase):
144 self.assertEqual(
145 logger.output,
146 'No store configuration found. '
147- 'Have you run "snapstore-client login"?\n')
148+ 'Have you run "snap-store-proxy-client login"?\n')
149
150 @responses.activate
151 def test_list_overrides(self):
152@@ -68,7 +68,7 @@ class OverridesTests(TestCase):
153 self.assertEqual(
154 logger.output,
155 'No store configuration found. '
156- 'Have you run "snapstore-client login"?\n')
157+ 'Have you run "snap-store-proxy-client login"?\n')
158
159 @responses.activate
160 def test_override(self):
161@@ -123,7 +123,7 @@ class OverridesTests(TestCase):
162 self.assertEqual(
163 logger.output,
164 'No store configuration found. '
165- 'Have you run "snapstore-client login"?\n')
166+ 'Have you run "snap-store-proxy-client login"?\n')
167
168 @responses.activate
169 def test_delete_override(self):
170diff --git a/snapstore_client/tests/factory.py b/snapstore_client/tests/factory.py
171index b7f77c6..f9d4ba5 100644
172--- a/snapstore_client/tests/factory.py
173+++ b/snapstore_client/tests/factory.py
174@@ -2,7 +2,7 @@
175
176 """Test Factory.
177
178-Since snapstore-client does not have any database, its persistence layer
179+Since snap-store-proxy-client does not have any database, its persistence layer
180 consists of making requests to other services in the store.
181
182 The test factory therefore makes it easy to create payloads that are
183diff --git a/snapstore_client/tests/test_config.py b/snapstore_client/tests/test_config.py
184index 2ddbc5c..320b51c 100644
185--- a/snapstore_client/tests/test_config.py
186+++ b/snapstore_client/tests/test_config.py
187@@ -28,7 +28,8 @@ class ConfigTests(TestCase):
188
189 def test_save(self):
190 xdg_path = self.useFixture(XDGConfigDirFixture()).path
191- config_ini = os.path.join(xdg_path, 'snapstore-client', 'config.ini')
192+ config_ini = os.path.join(
193+ xdg_path, 'snap-store-proxy-client', 'config.ini')
194 self.assertFalse(os.path.exists(config_ini))
195
196 cfg = Config()
197diff --git a/snapstore_client/tests/testfixtures.py b/snapstore_client/tests/testfixtures.py
198index 0342388..10f714e 100644
199--- a/snapstore_client/tests/testfixtures.py
200+++ b/snapstore_client/tests/testfixtures.py
201@@ -50,7 +50,8 @@ class ConfigFixture(Fixture):
202
203 def _setUp(self):
204 xdg_config_path = self.useFixture(XDGConfigDirFixture()).path
205- app_config_path = os.path.join(xdg_config_path, 'snapstore-client')
206+ app_config_path = os.path.join(
207+ xdg_config_path, 'snap-store-proxy-client')
208 os.makedirs(app_config_path)
209 if self.empty:
210 return

Subscribers

People subscribed via source and target branches

to all changes: