Skip to content

Commit 7804035

Browse files
authored
Merge pull request #44 from dsccommunity/dev
Merge new CI to Master
2 parents 51fe7f3 + 28bba66 commit 7804035

File tree

62 files changed

+1924
-1087
lines changed

Some content is hidden

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

62 files changed

+1924
-1087
lines changed

.MetaTestOptIn.json

Lines changed: 0 additions & 14 deletions
This file was deleted.

.codecov.yml

Lines changed: 0 additions & 26 deletions
This file was deleted.

.gitattributes

Lines changed: 5 additions & 59 deletions
Original file line numberDiff line numberDiff line change
@@ -3,62 +3,8 @@
33
###############################################################################
44
* text eol=crlf
55

6-
###############################################################################
7-
# Set default behavior for command prompt diff.
8-
#
9-
# This is need for earlier builds of msysgit that does not have it on by
10-
# default for csharp files.
11-
# Note: This is only used by command line
12-
###############################################################################
13-
#*.cs diff=csharp
14-
15-
###############################################################################
16-
# Set the merge driver for project and solution files
17-
#
18-
# Merging from the command prompt will add diff markers to the files if there
19-
# are conflicts (Merging from VS is not affected by the settings below, in VS
20-
# the diff markers are never inserted). Diff markers may cause the following
21-
# file extensions to fail to load in VS. An alternative would be to treat
22-
# these files as binary and thus will always conflict and require user
23-
# intervention with every merge. To do so, just uncomment the entries below
24-
###############################################################################
25-
#*.sln merge=binary
26-
#*.csproj merge=binary
27-
#*.vbproj merge=binary
28-
#*.vcxproj merge=binary
29-
#*.vcproj merge=binary
30-
#*.dbproj merge=binary
31-
#*.fsproj merge=binary
32-
#*.lsproj merge=binary
33-
#*.wixproj merge=binary
34-
#*.modelproj merge=binary
35-
#*.sqlproj merge=binary
36-
#*.wwaproj merge=binary
37-
38-
###############################################################################
39-
# behavior for image files
40-
#
41-
# image files are treated as binary by default.
42-
###############################################################################
43-
*.jpg binary
44-
*.png binary
45-
*.gif binary
46-
*.exe binary
47-
48-
###############################################################################
49-
# diff behavior for common document formats
50-
#
51-
# Convert binary document formats to text before diffing them. This feature
52-
# is only available from the command line. Turn it on by uncommenting the
53-
# entries below.
54-
###############################################################################
55-
#*.doc diff=astextplain
56-
#*.DOC diff=astextplain
57-
#*.docx diff=astextplain
58-
#*.DOCX diff=astextplain
59-
#*.dot diff=astextplain
60-
#*.DOT diff=astextplain
61-
#*.pdf diff=astextplain
62-
#*.PDF diff=astextplain
63-
#*.rtf diff=astextplain
64-
#*.RTF diff=astextplain
6+
# Ensure any exe files are treated as binary
7+
*.exe binary
8+
*.jpg binary
9+
*.xl* binary
10+
*.pfx binary

.gitignore

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,9 @@
22
*.user
33
*.coverage
44
.vs
5+
.vscode
56
.psproj
67
.sln
7-
DscResource.Tests
8-
DscResource.Tests/*
9-
Modules/xNetworking/DscResource.Tests
10-
Modules/xNetworking/DscResource.Tests/*
11-
node_modules
12-
node_modules/*
138
markdownissues.txt
149
TestResults.xml
15-
launch.json
10+
output/

.vscode/analyzersettings.psd1

Lines changed: 3 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,6 @@
11
@{
2-
<#
3-
For the custom rules to work, the DscResource.Tests repo must be
4-
cloned. It is automatically clone as soon as any unit or
5-
integration tests are run.
6-
#>
7-
CustomRulePath = '.\DSCResource.Tests\DscResource.AnalyzerRules'
8-
2+
CustomRulePath = '.\output\RequiredModules\DscResource.AnalyzerRules'
3+
includeDefaultRules = $true
94
IncludeRules = @(
105
# DSC Resource Kit style guideline rules.
116
'PSAvoidDefaultValueForMandatoryParameter',
@@ -43,11 +38,7 @@
4338
'PSUseDeclaredVarsMoreThanAssignments',
4439
'PSUsePSCredentialType',
4540

46-
<#
47-
This is to test all the DSC Resource Kit custom rules.
48-
The name of the function-blocks of each custom rule start
49-
with 'Measure*'.
50-
#>
5141
'Measure-*'
5242
)
43+
5344
}

.vscode/settings.json

Lines changed: 26 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,38 @@
1-
// Place your settings in this file to overwrite default and user settings.
21
{
32
"powershell.codeFormatting.openBraceOnSameLine": false,
4-
"powershell.codeFormatting.newLineAfterOpenBrace": false,
3+
"powershell.codeFormatting.newLineAfterOpenBrace": true,
54
"powershell.codeFormatting.newLineAfterCloseBrace": true,
65
"powershell.codeFormatting.whitespaceBeforeOpenBrace": true,
76
"powershell.codeFormatting.whitespaceBeforeOpenParen": true,
87
"powershell.codeFormatting.whitespaceAroundOperator": true,
98
"powershell.codeFormatting.whitespaceAfterSeparator": true,
109
"powershell.codeFormatting.ignoreOneLineBlock": false,
10+
"powershell.codeFormatting.pipelineIndentationStyle": "IncreaseIndentationAfterEveryPipeline",
1111
"powershell.codeFormatting.preset": "Custom",
12+
"powershell.codeFormatting.alignPropertyValuePairs": true,
1213
"files.trimTrailingWhitespace": true,
1314
"files.insertFinalNewline": true,
14-
"powershell.scriptAnalysis.settingsPath": ".vscode\\analyzersettings.psd1"
15+
"powershell.scriptAnalysis.settingsPath": ".vscode\\analyzersettings.psd1",
16+
"powershell.scriptAnalysis.enable": true,
17+
"files.associations": {
18+
"*.ps1xml": "xml"
19+
},
20+
"cSpell.words": [
21+
"COMPANYNAME",
22+
"ICONURI",
23+
"LICENSEURI",
24+
"PROJECTURI",
25+
"RELEASENOTES",
26+
"buildhelpers",
27+
"endregion",
28+
"gitversion",
29+
"icontains",
30+
"keepachangelog",
31+
"notin",
32+
"pscmdlet",
33+
"steppable"
34+
],
35+
"[markdown]": {
36+
"files.encoding": "utf8"
37+
}
1538
}

CHANGELOG.md

Lines changed: 10 additions & 54 deletions
Original file line numberDiff line numberDiff line change
@@ -1,57 +1,13 @@
1-
# Versions
1+
# Change log for FileContentDsc
22

3-
## 1.3.0.0
3+
The format is based on and uses the types of changes according to [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
4+
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
45

5-
- Opted into Common Tests 'Common Tests - Validate Localization' -
6-
fixes [Issue #31](https://github.com/PlagueHO/FileContentDsc/issues/32).
7-
- Combined all `FileContent.ResourceHelper` module functions into
8-
`FileContent.Common` module - fixes [Issue #32](https://github.com/PlagueHO/FileContentDsc/issues/32).
9-
- Renamed all localization strings so that they are detected by
10-
'Common Tests - Validate Localization'.
11-
- Correct style violations in unit tests:
12-
- Adding `Get`, `Set` and `Test` tags to appropriate `describe` blocks.
13-
- Removing uneccesary `#region` blocks.
14-
- Conversion of double quotes to single quotes where possible.
15-
- Replace variables with string litterals in `describe` block description.
16-
- KeyValuePairFile:
17-
- Improve unit tests to simplify and cover additional test cases.
18-
- Fix error occuring when file is empty or does not exist - fixes [Issue #34](https://github.com/PlagueHO/FileContentDsc/issues/34).
6+
## [Unreleased]
197

20-
## 1.2.0.0
21-
22-
- Added .VSCode settings for applying DSC PSSA rules - fixes [Issue #25](https://github.com/PlagueHO/FileContentDsc/issues/25).
23-
- Added an Encoding parameter to the KeyValuePairFile and ReplaceText
24-
resources - fixes [Issue #5](https://github.com/PlagueHO/FileContentDsc/issues/5).
25-
26-
## 1.1.0.0
27-
28-
- Enabled PSSA rule violations to fail build - Fixes [Issue #6](https://github.com/PlagueHO/FileContentDsc/issues/6).
29-
- Updated tests to meet Pester v4 standard.
30-
- Added Open Code of Conduct.
31-
- Refactored module folder structure to move resource
32-
to root folder of repository and remove test harness - Fixes [Issue #11](https://github.com/PlagueHO/FileContentDsc/issues/11).
33-
- Converted Examples to support format for publishing to PowerShell
34-
Gallery.
35-
- Refactor Test-TargetResource to return $false in all DSC resource - Fixes
36-
[Issue #12](https://github.com/PlagueHO/FileContentDsc/issues/13).
37-
- Correct configuration names in Examples - fixes [Issue #15](https://github.com/PowerShell/FileContentDsc/issues/15).
38-
- Refactor Test/Set-TargetResource in ReplaceText to be able to add a key if it
39-
doesn't exist but should -Fixes
40-
[Issue#20](https://github.com/PlagueHO/FileContentDsc/issues/20).
41-
- Opted into common tests:
42-
- Common Tests - Validate Example Files To Be Published
43-
- Common Tests - Validate Markdown Links
44-
- Common Tests - Relative Path Length
45-
- Common Tests - Relative Path Length
46-
- Correct test context description in IniSettingsFile tests to include 'When'.
47-
- Change IniSettingsFile unit tests to be non-destructive - fixes [Issue #22](https://github.com/PowerShell/FileContentDsc/issues/22).
48-
- Update to new format LICENSE.
49-
50-
## 1.0.0.0
51-
52-
- DSR_ReplaceText:
53-
- Created new resource for replacing text in text files.
54-
- DSR_KeyValuePairFile:
55-
- Created new resource for setting key value pairs in text files.
56-
- DSR_IniSettingsFile:
57-
- Created new resource for setting Windows INI file settings.
8+
- Transferred ownership to DSCCommunity.org -
9+
fixes [Issue #31](https://github.com/dsccommunity/FileContentDsc/issues/39).
10+
- BREAKING CHANGE: Changed resource prefix from MSFT to DSC.
11+
- Updated to use continuous delivery pattern using Azure DevOps - fixes
12+
[Issue #41](https://github.com/dsccommunity/FileContentDsc/issues/41).
13+
- Updated build badges in README.MD.

CODE_OF_CONDUCT.md

Lines changed: 2 additions & 132 deletions
Original file line numberDiff line numberDiff line change
@@ -1,133 +1,3 @@
1-
# Open Source Code of Conduct
1+
# Code of Conduct
22

3-
This code of conduct outlines our expectations for participants within this
4-
DSC Resource Module community, as well as steps to reporting unacceptable behavior.
5-
We are committed to providing a welcoming and inspiring community for all and expect
6-
our code of conduct to be honored. Anyone who violates this code of conduct may be
7-
banned from the community.
8-
9-
Our open source communities strive to:
10-
11-
- **Be friendly and patient.**
12-
- **Be welcoming:** We strive to be a community that welcomes and supports people
13-
of all backgrounds and identities. This includes, but is not limited to members
14-
of any race, ethnicity, culture, national origin, colour, immigration status,
15-
social and economic class, educational level, sex, sexual orientation, gender
16-
identity and expression, age, size, family status, political belief, religion,
17-
and mental and physical ability.
18-
- **Be considerate:** Your work will be used by other people, and you in turn
19-
will depend on the work of others. Any decision you take will affect users and
20-
colleagues, and you should take those consequences into account when making
21-
decisions. Remember that we're a world-wide community, so you might not be
22-
communicating in someone else's primary language.
23-
- **Be respectful:** Not all of us will agree all the time, but disagreement is
24-
no excuse for poor behavior and poor manners. We might all experience some
25-
frustration now and then, but we cannot allow that frustration to turn into a
26-
personal attack. It's important to remember that a community where people feel
27-
uncomfortable or threatened is not a productive one.
28-
- **Be careful in the words that we choose:** we are a community of professionals,
29-
and we conduct ourselves professionally. Be kind to others. Do not insult or
30-
put down other participants. Harassment and other exclusionary behavior aren't
31-
acceptable.
32-
- **Try to understand why we disagree:** Disagreements, both social and technical,
33-
happen all the time. It is important that we resolve disagreements and differing
34-
views constructively. Remember that we're different. The strength of our community
35-
comes from its diversity, people from a wide range of backgrounds. Different people
36-
have different perspectives on issues. Being unable to understand why someone holds
37-
a viewpoint doesn't mean that they're wrong. Don't forget that it is human to err
38-
and blaming each other doesn't get us anywhere. Instead, focus on helping to resolve
39-
issues and learning from mistakes.
40-
41-
## Definitions
42-
43-
Harassment includes, but is not limited to:
44-
45-
- Offensive comments related to gender, gender identity and expression, sexual
46-
orientation, disability, mental illness, neuro(a)typicality, physical appearance,
47-
body size, race, age, regional discrimination, political or religious affiliation
48-
- Unwelcome comments regarding a person's lifestyle choices and practices,
49-
including those related to food, health, parenting, drugs, and employment
50-
- Deliberate misgendering. This includes deadnaming or persistently using a
51-
pronoun that does not correctly reflect a person's gender identity. You must
52-
address people by the name they give you when not addressing them by their username
53-
or handle
54-
- Physical contact and simulated physical contact (eg, textual descriptions like
55-
"hug" or "backrub") without consent or after a request to stop
56-
- Threats of violence, both physical and psychological
57-
- Incitement of violence towards any individual, including encouraging a person
58-
to commit suicide or to engage in self-harm
59-
- Deliberate intimidation
60-
- Stalking or following
61-
- Harassing photography or recording, including logging online activity for
62-
harassment purposes
63-
- Sustained disruption of discussion
64-
- Unwelcome sexual attention, including gratuitous or off-topic sexual images or
65-
behaviour
66-
- Pattern of inappropriate social contact, such as requesting/assuming inappropriate
67-
levels of intimacy with others
68-
- Continued one-on-one communication after requests to cease
69-
- Deliberate "outing" of any aspect of a person's identity without their consent
70-
except as necessary to protect others from intentional abuse
71-
- Publication of non-harassing private communication
72-
73-
Our open source community prioritizes marginalized people's safety over privileged
74-
people's comfort. We will not act on complaints regarding:
75-
76-
- 'Reverse' -isms, including 'reverse racism,' 'reverse sexism,' and 'cisphobia'
77-
- Reasonable communication of boundaries, such as "leave me alone," "go away," or
78-
"I'm not discussing this with you"
79-
- Refusal to explain or debate social justice concepts
80-
- Communicating in a 'tone' you don't find congenial
81-
- Criticizing racist, sexist, cissexist, or otherwise oppressive behavior or assumptions
82-
83-
## Diversity Statement
84-
85-
We encourage everyone to participate and are committed to building a community
86-
for all. Although we will fail at times, we seek to treat everyone both as fairly
87-
and equally as possible. Whenever a participant has made a mistake, we expect them
88-
to take responsibility for it. If someone has been harmed or offended, it is our
89-
responsibility to listen carefully and respectfully, and do our best to right the
90-
wrong.
91-
92-
Although this list cannot be exhaustive, we explicitly honor diversity in age,
93-
gender, gender identity or expression, culture, ethnicity, language, national
94-
origin, political beliefs, profession, race, religion, sexual orientation, socioeconomic
95-
status, and technical ability. We will not tolerate discrimination based on any
96-
of the protected characteristics above, including participants with disabilities.
97-
98-
## Reporting Code of Conduct Issues
99-
100-
If you experience or witness unacceptable behavior—or have any other concerns,
101-
please report it by contacting us via [[email protected]](mailto:[email protected]).
102-
All reports will be handled with discretion.
103-
104-
In your report please include:
105-
106-
- Your contact information.
107-
- Names (real, usernames or pseudonyms) of any individuals involved. If there
108-
are additional witnesses, please include them as well.
109-
- Your account of what occurred, and if you believe the incident is ongoing.
110-
- If there is a publicly available record (e.g. a mailing list archive or a
111-
public chat log), please include a link or attachment.
112-
- Any additional information that may be helpful.
113-
114-
After filing a report, a representative will contact you personally, review the
115-
incident, follow up with any additional questions, and make a decision as to how
116-
to respond. If the person who is harassing you is part of the response team, they
117-
will recuse themselves from handling your incident. If the complaint originates
118-
from a member of the response team, it will be handled by a different member of
119-
the response team. We will respect confidentiality requests for the purpose of
120-
protecting victims of abuse.
121-
122-
## Attribution & Acknowledgements
123-
124-
We all stand on the shoulders of giants across many open source communities.
125-
We’d like to thank the communities and projects that established code of conducts
126-
and diversity statements as our inspiration:
127-
128-
- [Django](https://www.djangoproject.com/conduct/reporting/)
129-
- [Python](https://www.python.org/community/diversity/)
130-
- [Ubuntu](http://www.ubuntu.com/about/about-ubuntu/conduct)
131-
- [Contributor Covenant](http://contributor-covenant.org/)
132-
- [Geek Feminism](http://geekfeminism.org/about/code-of-conduct/)
133-
- [Citizen Code of Conduct](http://citizencodeofconduct.org/)
3+
This project has adopted the [DSC Community Code of Conduct](https://dsccommunity.org/code_of_conduct).

0 commit comments

Comments
 (0)