summaryrefslogtreecommitdiff
path: root/templates/system/package/repository/node.def
diff options
context:
space:
mode:
Diffstat (limited to 'templates/system/package/repository/node.def')
-rw-r--r--templates/system/package/repository/node.def17
1 files changed, 7 insertions, 10 deletions
diff --git a/templates/system/package/repository/node.def b/templates/system/package/repository/node.def
index 4fd6d587..75a61e55 100644
--- a/templates/system/package/repository/node.def
+++ b/templates/system/package/repository/node.def
@@ -1,14 +1,11 @@
tag:
type: txt
-help: "Repository name"
-# bug 1847: remove the previous repo line before adding new line.
-# need to prohibit '!' in repo name (sed delimiter)
-syntax: pattern $(@) "^[^!]+$" ; "Do not use '!' in repository name"
-create: "sudo sh -c \"touch /etc/apt/sources.list && \
-sed -i '\\!/ $(@) !d' /etc/apt/sources.list && \
-echo \\\"deb $(url/@)/ $(@) $(component/@)\\\" >> /etc/apt/sources.list\" "
+help: "Name describing the repository"
+commit: $(./url/) != ""; "Must configure the repository URL"
+commit: $(./distribution/) != ""; "Must configure the repository distribution"
+commit: $(./component/) != ""; "Must configure the repository component"
update: "sudo sh -c \"touch /etc/apt/sources.list && \
-sed -i '\\!/ $(@) !d' /etc/apt/sources.list && \
-echo \\\"deb $(url/@)/ $(@) $(component/@)\\\" >> /etc/apt/sources.list\" "
+sed -i '\\!# $(@) #!d' /etc/apt/sources.list && \
+echo \\\"deb $(url/@)/ $(distribution/@) $(component/@) # $(@) #\\\" >> /etc/apt/sources.list\" "
delete: "sudo sh -c \"touch /etc/apt/sources.list && \
-sed -i '\\! $(@) $(component/@)!d' /etc/apt/sources.list\" "
+sed -i '\\!# $(@) #!d' /etc/apt/sources.list\" "