-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Remove custom code used to deal with package metadata and package con…
…tent.
- Loading branch information
Showing
10 changed files
with
67 additions
and
134 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +0,0 @@ | ||
""" | ||
Check `Plugin Writer's Guide`_ for more details. | ||
.. _Plugin Writer's Guide: | ||
http://docs.pulpproject.org/en/3.0/nightly/plugins/plugin-writer/index.html | ||
""" | ||
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1 @@ | ||
from django.conf import settings | ||
from django.urls import path | ||
|
||
from pulp_npm.app.viewsets import PublishedPackageViewSet | ||
|
||
|
||
PACKAGE_API_ROOT = getattr(settings, "PACKAGE_API_ROOT", "pulp_npm/packages/<path:name>/") | ||
|
||
urlpatterns = [path(PACKAGE_API_ROOT, PublishedPackageViewSet.as_view())] | ||
urlpatterns = [] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,17 @@ | ||
from django.conf import settings | ||
def urlpath_sanitize(*args): | ||
""" | ||
Join an arbitrary number of strings into a /-separated path. | ||
Replaces uses of urljoin() that don't want/need urljoin's subtle semantics. | ||
def pulp_npm_content_path(): | ||
"""Get base cotent path from configuration.""" | ||
components = settings.CONTENT_PATH_PREFIX.split("/") | ||
components[1] = "pulp_npm" | ||
return "/".join(components) | ||
Returns: single string provided arguments separated by single-slashes | ||
Args: | ||
Arbitrary list of arguments to be join()ed | ||
""" | ||
segments = [] | ||
for a in args + ("",): | ||
stripped = a.strip("/") | ||
if stripped: | ||
segments.append(stripped) | ||
return "/".join(segments) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters