Skip to content

Commit b0bc0df

Browse files
JustBecause42davidflowers
authored andcommitted
Pull request #10: Release of Microchip University Bootloader16 Labs
Merge in MCU16CE/bootloader16-microchip-university-labs from develop to master * commit '96dd3167b789403be6133e2b803db75f5766e35a': (42 commits) Updated change log Updated keywords based on feedback Removed the items from the peripherals list Removed Invalid Keyword Added more keywords and added UBHA to Jenkins Override list. Used keywords from different list. https://confluence.microchip.com/display/DTS/Discover+Metadata+Tag+Visualizer+-+Table Updated keywords Updated .json file Update .jason file Fixed typo Fixed keywords Updated periph names Update .json file Removed debug code. Updated file Added hex file so the app will build Revert "Added hex file to fix build order issue" Revert "Removed debug statements from sh file" Removed debug statements from sh file Added hex file to fix build order issue ...
2 parents 4ead6e7 + 96dd316 commit b0bc0df

File tree

726 files changed

+264958
-5
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

726 files changed

+264958
-5
lines changed

.citd/Jenkinsfilek8s

+272
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,272 @@
1+
/*
2+
Jenkins Shared Library:
3+
----------------------
4+
shared-library-mcu16ce - https://bitbucket.microchip.com/scm/citd/shared-library-mcu16ce.git
5+
shared-library-common - https://bitbucket.microchip.com/scm/citd/shared-library-common.git
6+
*/
7+
@Library(['shared-library-mcu16ce@master', 'shared-library-common@master']) _
8+
9+
pipeline {
10+
agent {
11+
kubernetes {
12+
inheritFrom 'bootloader16-microchip-university-labs-github-deployment'
13+
defaultContainer 'xc16-mplabx-sonar-fmpp-python'
14+
yamlFile '.citd/cloudprovider.yml'
15+
}
16+
}
17+
18+
environment {
19+
/*
20+
Common Information
21+
*/
22+
NOTIFICATION_EMAIL = '[email protected]'
23+
// GitHub production organization name
24+
GITHUB_PRODUCTION_ORGANIZATION = "microchip-pic-avr-examples"
25+
26+
/*
27+
GitHub Deploy Stage Information
28+
*/
29+
//This is the BitBucket source repo URL to be deployed
30+
BITBUCKET_SOURCE_URL = 'https://bitbucket.microchip.com/scm/mcu16ce/bootloader16-microchip-university-labs.git'
31+
//Files or folders to be excluded from deployment, if multiple files or folders use comma separator
32+
DEPLOY_EXCLUDE_FOLDER_FILE_LIST = 'mchp_private,.mchp_private,sandbox,.sandbox'
33+
//Branch(s) to be deployed, if multiple branches use comma separator. DEPLOY_BRANCH_LIST is the target branch of the PR.
34+
DEPLOY_BRANCH_LIST = "master"
35+
/*When using the main.json schema version 1.3.0 or higher, the PORTAL will first reject registration attempt when an unapproved keyword is found, but can be forced to accept.
36+
This argument is used to provide the list of unapproved keywords (also listed in main.json) which the deployment script will force the PORTAL to accept.*/
37+
UNAPPROVED_KEYWORDS_OVERRIDE_LIST="UBHA"
38+
39+
/*
40+
GitHub Page Stage Information
41+
List of GitHub Page Options:
42+
----------------------------
43+
1. GITHUB_PAGES_NONE ( Branch: None, index file path: None )
44+
2. GITHUB_PAGES_MASTER_ROOT ( Branch: Master, index file path: /root )
45+
3. GITHUB_PAGES_MASTER_DOCS ( Branch: Master, index file path: /Docs )
46+
4. GITHUB_PAGES_DEVELOP_ROOT ( Branch: Develop, index file path: /root )
47+
5. GITHUB_PAGES_DEVELOP_DOCS ( Branch: Develop, index file path: /Docs )
48+
*/
49+
GITHUB_PAGES = 'GITHUB_PAGES_NONE'
50+
51+
/*
52+
Project Build Stage Information
53+
*/
54+
MPLABX_PROJECT_SOURCE = "../"
55+
}
56+
57+
options {
58+
timestamps()
59+
timeout(time: 20, unit: 'MINUTES')
60+
}
61+
62+
stages {
63+
stage('Checkout') {
64+
steps {
65+
checkout scm
66+
}
67+
}
68+
69+
stage('project config update') {
70+
steps {
71+
script {
72+
mplabxProjectConfigUpdate(
73+
sourceFilePath: "${env.MPLABX_PROJECT_SOURCE}"
74+
)
75+
}
76+
}
77+
}
78+
79+
stage('Build') {
80+
steps {
81+
script {
82+
mplabxProjectBuild(
83+
sourceFilePath: "${env.MPLABX_PROJECT_SOURCE}"
84+
)
85+
}
86+
}
87+
}
88+
89+
90+
//MisraCheck code analysis
91+
stage('MISRA Check') {
92+
steps {
93+
script {
94+
misraCheck(
95+
sourceProjectPath: "${env.MPLABX_PROJECT_SOURCE}"
96+
)
97+
}
98+
}
99+
}
100+
101+
// Validate main.json file
102+
stage('Validate main.json') {
103+
steps {
104+
script {
105+
validateMetaData(
106+
unapprovedKeywordsOverrideList: "${UNAPPROVED_KEYWORDS_OVERRIDE_LIST}"
107+
)
108+
}
109+
}
110+
}
111+
112+
// Creating tag in Bitbucket repo
113+
stage('Bitbucket Tag Creation') {
114+
when {
115+
anyOf {
116+
allOf {
117+
not { changeRequest() }
118+
anyOf {branch 'master';}
119+
}
120+
}
121+
}
122+
123+
steps {
124+
script {
125+
bitbucketTagCreation()
126+
}
127+
}
128+
}
129+
130+
stage('Doxygen files generation') {
131+
when {
132+
anyOf {
133+
allOf {
134+
not { changeRequest() }
135+
}
136+
}
137+
}
138+
steps {
139+
container('buildtools') {
140+
script {
141+
doxygen()
142+
}
143+
}
144+
}
145+
}
146+
147+
// GitHub repo creation
148+
stage('GitHub Repo Creation') {
149+
when {
150+
anyOf {
151+
allOf {
152+
not { changeRequest() }
153+
anyOf {branch 'master'; branch 'test_deploy';}
154+
}
155+
}
156+
}
157+
158+
steps {
159+
script {
160+
githubRepoCreate(
161+
githubOrgName: "${env.GITHUB_PRODUCTION_ORGANIZATION}",
162+
deployBranchList: "${DEPLOY_BRANCH_LIST}"
163+
)
164+
}
165+
}
166+
}
167+
168+
// Deploying the code to GitHub
169+
stage('GitHub Deploy Source') {
170+
when {
171+
anyOf {
172+
allOf {
173+
not { changeRequest() }
174+
anyOf {branch 'master'; branch 'test_deploy';}
175+
}
176+
}
177+
}
178+
179+
steps {
180+
script {
181+
githubDeploySource(
182+
bitbucketUrl: "${env.BITBUCKET_SOURCE_URL}",
183+
deployBranchList: "${env.DEPLOY_BRANCH_LIST}",
184+
deployExcludeFileList: "${env.DEPLOY_EXCLUDE_FOLDER_FILE_LIST}",
185+
githubOrgName: "${env.GITHUB_PRODUCTION_ORGANIZATION}"
186+
)
187+
}
188+
}
189+
}
190+
191+
// Creating GitHub release
192+
stage('GitHub release') {
193+
when {
194+
anyOf {
195+
allOf {
196+
not { changeRequest() }
197+
anyOf {branch 'master'; branch 'test_deploy';}
198+
}
199+
}
200+
}
201+
202+
steps {
203+
script {
204+
githubReleaseCreate(
205+
githubOrgName: "${env.GITHUB_PRODUCTION_ORGANIZATION}",
206+
deployBranchList: "${DEPLOY_BRANCH_LIST}"
207+
)
208+
}
209+
}
210+
}
211+
212+
// Creating GitHub Page
213+
stage('GitHub Page Create') {
214+
when {
215+
anyOf {
216+
allOf {
217+
not { changeRequest() }
218+
anyOf {branch 'master';}
219+
}
220+
}
221+
}
222+
223+
steps {
224+
script {
225+
githubPageCreate(
226+
githubPage: "${env.GITHUB_PAGES}",
227+
githubOrgName: "${env.GITHUB_PRODUCTION_ORGANIZATION}"
228+
)
229+
}
230+
}
231+
}
232+
233+
//Deploying the Github content to portal
234+
stage('Portal-Deploy') {
235+
when {
236+
allOf {
237+
not { changeRequest() }
238+
anyOf {branch 'master';}
239+
}
240+
}
241+
steps {
242+
script {
243+
portalDeploy(
244+
githubOrgName: "${env.GITHUB_PRODUCTION_ORGANIZATION}",
245+
unapprovedKeywordsOverrideList: "${UNAPPROVED_KEYWORDS_OVERRIDE_LIST}"
246+
)
247+
}
248+
}
249+
}
250+
}
251+
252+
post {
253+
success{
254+
script {
255+
sendMail(
256+
mailId: "${env.NOTIFICATION_EMAIL}",
257+
subject: "Successful Pipeline: ${currentBuild.fullDisplayName}",
258+
body: "Something is right with ${env.BUILD_URL}"
259+
)
260+
}
261+
}
262+
failure {
263+
script {
264+
sendMail(
265+
mailId: "${env.NOTIFICATION_EMAIL}",
266+
subject: "Failure Pipeline: ${currentBuild.fullDisplayName}",
267+
body: "Something is right with ${env.BUILD_URL}"
268+
)
269+
}
270+
}
271+
}
272+
}

.citd/cloudprovider.yml

+30
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
apiVersion: v1
2+
kind: Pod
3+
metadata:
4+
name: xc16-mplabx-sonar-fmpp-python
5+
spec:
6+
containers:
7+
- name: xc16-mplabx-sonar-fmpp-python
8+
image: artifacts.microchip.com:7999/microchip/citd/bundles/xc16-mplabx-sonar-fmpp-python-yarn-node:latest
9+
imagePullPolicy: Always
10+
command: ['cat']
11+
tty: true
12+
resources:
13+
requests:
14+
cpu: 500m
15+
memory: 1500Mi
16+
limits:
17+
cpu: 1
18+
memory: 2Gi
19+
- name: buildtools
20+
image: artifacts.microchip.com:7999/microchip/buildtools/doxygen:1.8.15-r0
21+
imagePullPolicy: Always
22+
command: ['cat']
23+
tty: true
24+
resources:
25+
requests:
26+
cpu: 500m
27+
memory: 750Mi
28+
limits:
29+
cpu: 1
30+
memory: 1Gi

.gitignore

+54
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
# .gitignore file
2+
#
3+
# Set up for Microchip/MPLAB X® development
4+
#
5+
# Default gitignore files for code examples, only removing/ignoring usual MPLAB X® clutter
6+
7+
# Excluding object files
8+
*.d
9+
*.o
10+
*.ko
11+
*.obj
12+
*.elf
13+
14+
# Excluding documentation output directories
15+
#docs/
16+
17+
# Excluding any executables
18+
*.exe
19+
20+
#Excluding Files/Folders Auto-Generated by Test Harness
21+
.generated_files/
22+
23+
# Excluding Netbeans specific build directories and file types
24+
~*.*
25+
.generated_files/
26+
nbproject/build/
27+
nbproject/dist/
28+
nbproject/private/
29+
nbproject/disassembly/
30+
build/
31+
dist/
32+
private/
33+
disassembly/
34+
*.zip
35+
!code-templates.zip
36+
*.mk
37+
*.dump
38+
Makefile-genesis.properties
39+
40+
# Excluding MPLAB X® Trace files
41+
*.log
42+
*.inx
43+
44+
# KDE specific
45+
.directory
46+
47+
# Misc
48+
.svn
49+
*.bak
50+
*.doc
51+
*.docx
52+
53+
54+

0 commit comments

Comments
 (0)