Browse Source

Completed README1st.markdown

Aaron Hicks 7 years ago
parent
commit
b4c1bd471a
1 changed files with 57 additions and 4 deletions
  1. 57
    4
      README1st.markdown

+ 57
- 4
README1st.markdown View File

@@ -21,7 +21,6 @@ git clone -o puppet-blank -b master git://github.com/Aethylred/puppet-blank.git
21 21
 git remote add origin git@a.git.repo:reponame.git
22 22
 ```
23 23
 
24
-
25 24
 ## Windows scripts
26 25
 
27 26
 Provided are some Powershell scripts that can be used to manage the blank puppet module template.
@@ -49,8 +48,58 @@ This updates the author and module name using the `.orig` templates. This script
49 48
 2. Run the `unblank.ps1` script:
50 49
 
51 50
 ```
52
-./unblank.ps1 newauthor newmodule
51
+.\unblank.ps1 newauthor newmodule
52
+```
53
+3. Add the newly created files to the git version control:
54
+```
55
+git add Modulefile manifests\init.pp tests\init.pp
56
+```
57
+4. Commit these changes to git:
58
+```
59
+git commit -am "Unblanked module with newauthor and newmodule"
60
+```
61
+5. Add new remote repository:
62
+```
63
+git remote add origin git@git.repo.server:repository.git
64
+```
65
+6. Push changes to origin:
66
+```
67
+git push origin master
68
+```
69
+7. The new module is ready for further development
70
+
71
+## There's been an update to puppet-blank
72
+
73
+Just merge from the puppet-blank remote, though conflicts will be expected:
74
+```
75
+git pull puppet-blank master
53 76
 ```
77
+
78
+## Cleaning up the puppet-blank files
79
+1. Start Powershell in the blank module directory
80
+2. Run the cleanup script:
81
+`.\cleanup.ps1`
82
+3. Commit the changes to git:
83
+```
84
+git commit -am "Cleaned up with the puppet-blank cleanup script"
85
+```
86
+4. Push changes to remote:
87
+```
88
+git push origin master
89
+```
90
+**NOTE:** The cleanup script is *destructive* and will delete several files, including itself.
91
+**NOTE:** The puppet-blank remote is read-only, it should not be possible to push to it.
92
+
93
+## Prepare a module for submission to Puppet Forge
94
+
95
+1. To perform this step, the module will need to be cloned to a Linux server where puppet has been installed, and that the `UNKNOWN` entries in the `Modulefile` have been corrected.
96
+2. in the parent directory to the module, build the module metadata where the module is in the directory `puppet-module`:
97
+```
98
+puppet module build puppet-module
99
+```
100
+3. Submit the resulting tarball to Puppet Forge as per:
101
+http://docs.puppetlabs.com/puppet/2.7/reference/modules_publishing.html
102
+
54 103
 # Frequently Asked Questions
55 104
 
56 105
 More like questions that should be asked.
@@ -66,6 +115,10 @@ puppet module generate author blank
66 115
 
67 116
 This module is intended for:
68 117
 
69
-1. Writing a module where puppet is not or can not be installed
118
+1. Writing a module in an environment where puppet is not or can not be installed
119
+
120
+2. Use as a starting point for a collection of modules and prepopulated with things like licensing, boiler plate, pictures of cats, etc. etc.
121
+
122
+## Why Windows powershell scripts?
70 123
 
71
-2. Use as a starting point for a collection of modules and prepopulated with things like licensing, boiler plate, pictures of cats, etc. etc.
124
+My $work environment is restricted to using Windows 7, so I required scripts that run under Windows 7. I used Powershell because it has regular expressions, which made this much easier than `.bat` batch files.

Loading…
Cancel
Save