From 3fad56d26627c3e19561c319ddf124d22639c801 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Fran=C3=A7ois=20Conil?= Date: Mon, 19 May 2014 15:12:36 +1000 Subject: [PATCH] adding notice on top of sourceslist files Useful to figure out what is managed by puppet and what isn't when not setting up the option to purge sourceslist files --- spec/defines/source_spec.rb | 2 +- templates/source.list.erb | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/spec/defines/source_spec.rb b/spec/defines/source_spec.rb index 34b3942..bf5e50e 100644 --- a/spec/defines/source_spec.rb +++ b/spec/defines/source_spec.rb @@ -74,7 +74,7 @@ describe 'apt::source', :type => :define do end let :content do - content = "# #{title}" + content = "#file generated by puppet\n# #{title}" if param_hash[:architecture] arch = "[arch=#{param_hash[:architecture]}] " end diff --git a/templates/source.list.erb b/templates/source.list.erb index 9946966..541534e 100644 --- a/templates/source.list.erb +++ b/templates/source.list.erb @@ -1,3 +1,4 @@ +#file generated by puppet # <%= @name %> deb <% if @architecture %>[arch=<%= @architecture %>] <% end %><%= @location %> <%= @release_real %> <%= @repos %> <%- if @include_src then -%> -- 2.45.2