Skip to content

Commit

Permalink
Bump up version number and update readme (#289)
Browse files Browse the repository at this point in the history
* Bump up version number and update readme

* Cleaning up some unneeded code

* Fixing typo
  • Loading branch information
belav authored Jun 12, 2021
1 parent cd6e079 commit 8d0cdc8
Show file tree
Hide file tree
Showing 7 changed files with 51 additions and 12 deletions.
16 changes: 16 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,19 @@
# 0.9.6

[diff](https://github.com/belav/csharpier/compare/0.9.5...0.9.6)

- Add options to write the formatted file to stdout and accept a file from stdin [#282](https://github.com/belav/csharpier/issues/282)
- Implement ConditionalGroup doc type [#278](https://github.com/belav/csharpier/issues/278)
- Optimize some hot paths to speed up formatting. [#277](https://github.com/belav/csharpier/issues/277)
- Implement Align Doc Type [#276](https://github.com/belav/csharpier/issues/276)
- Improve formatting of ClassDeclaration with BaseList + Constraints [#275](https://github.com/belav/csharpier/issues/275)
- Switch tests to width 100 so they line up with default option [#256](https://github.com/belav/csharpier/issues/256)
- Improving formatting of generics + variable declarations. [#240](https://github.com/belav/csharpier/pull/240)
- Improve Forrmatting of Field with lambda and generics [#236](https://github.com/belav/csharpier/issues/236)
- Improve Formatting of object initialiser syntax [#234](https://github.com/belav/csharpier/issues/234)
- Improve formatting of generic methods and constructors [#94](https://github.com/belav/csharpier/issues/94)
- Improve formatting of field with generics [#47](https://github.com/belav/csharpier/issues/47)
______
# 0.9.5

[diff](https://github.com/belav/csharpier/compare/0.9.4...0.9.5)
Expand Down
2 changes: 1 addition & 1 deletion CSharpier.Build.props
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<Project>
<PropertyGroup>
<Version>0.9.5</Version>
<Version>0.9.6</Version>
<PackageLicenseExpression>MIT</PackageLicenseExpression>
<RepositoryUrl>https://github.com/belav/csharpier</RepositoryUrl>
<RepositoryType>git</RepositoryType>
Expand Down
22 changes: 22 additions & 0 deletions Docs/CLI.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ Options:
--check Check that files are formatted. Will not write any changes.
--fast Skip comparing syntax tree of formatted file to original file to validate changes.
--skip-write Skip writing changes. Generally used for testing to ensure csharpier doesn't throw any errors or cause syntax tree validation failures.
--write-stdout Write the results of formatting any files to stdout.
--version Show version information
-?, -h, --help Show help and usage information

Expand Down Expand Up @@ -54,4 +55,25 @@ An example of CSharpier finding a file that failed validation.
}
if (prefix.Span[^1] is not ':')
```

### --write-stdout
By default CSharpier will format files in place. This option allows you to write the formatting results to stdout.

If you pipe input to CSharpier it will also write the formatting results to stdout.

*TestFile.cs*
```c#
public class ClassName
{
public string Field;
}
```
*shell*
```bash
$ cat TestFile.cs | dotnet csharpier
public class ClassName
{
public string Field;
}
```
11 changes: 9 additions & 2 deletions Scripts/ChangeLog.ps1
Original file line number Diff line number Diff line change
@@ -1,8 +1,15 @@
# this uses https://github.com/microsoft/PowerShellForGitHub
# you'll need to Set-GitHubAuthentication first

$versionNumber = "0.9.5"
$previousVersionNumber = "0.9.4"
param (
[string]$previousVersionNumber,
[string]$versionNumber
)

if ($versionNumber -eq "" -or $previousVersionNumber -eq "") {
Write-Output "Supply version numbers"
exit 1;
}

$repository = "https://github.com/belav/csharpier"

Expand Down
2 changes: 2 additions & 0 deletions Scripts/CreateReviewCodePRs.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ param (
[string]$version
)

# TODO this could format from the root folder, so that it is easy to see if anything failed, but do all the git stuff in the repo specific folders.

# aspnetcore
# AspNetWebStack
# AutoMapper
Expand Down
2 changes: 1 addition & 1 deletion Src/CSharpier.Playground/ClientApp/src/Header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ export const Header = () => {
</Left>
<Right>
<RightButtons>
<SmallButton title="Shift-Ctrl-X" onClick={copyLeft}>Copy Left</SmallButton>
<SmallButton title="Shift-Ctrl-S" onClick={copyLeft}>Copy Left</SmallButton>
</RightButtons>
<label>
<input
Expand Down
8 changes: 0 additions & 8 deletions Src/CSharpier/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -54,14 +54,6 @@ CancellationToken cancellationToken
}
else
{
if (standardInFileContents != null)
{
Console.WriteLine(
"directoryOrFile may not be supplied when piping standard input"
);
return 1;
}

directoryOrFile = directoryOrFile!.Select(
o => Path.Combine(Directory.GetCurrentDirectory(), o)
)
Expand Down

0 comments on commit 8d0cdc8

Please sign in to comment.