Skip to content

Commit

Permalink
v3.22 Detect queries within sequential expressions or statements (fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
Zaid-Ajaj committed Dec 8, 2020
1 parent ad927a4 commit 9ab30a3
Show file tree
Hide file tree
Showing 16 changed files with 92 additions and 63 deletions.
4 changes: 2 additions & 2 deletions .config/dotnet-tools.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
]
},
"fake-cli": {
"version": "5.19.0",
"version": "5.20.3",
"commands": [
"fake"
]
Expand All @@ -27,7 +27,7 @@
]
},
"paket": {
"version": "5.247.4",
"version": "5.257.0",
"commands": [
"paket"
]
Expand Down
3 changes: 3 additions & 0 deletions RELEASE_NOTES.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
### 3.22.0 - 2020-12-08
* Detect queries within sequential expressions or statements

### 3.21.0 - 2020-12-08
* Detect queries within lambda expressions wrapped in single case unions

Expand Down
3 changes: 2 additions & 1 deletion paket.dependencies
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
source https://www.nuget.org/api/v2
source https://api.nuget.org/v3/index.json
storage: none
lowest_matching: true
clitool dotnet-mono 0.5.2
nuget FSharp.Core
nuget FSharp.Core ~> 4.7.2
nuget Microsoft.SourceLink.GitHub prerelease copy_local: true
nuget Microsoft.NETFramework.ReferenceAssemblies copy_local: true
nuget Expecto 8.13.1
Expand Down
1 change: 1 addition & 0 deletions paket.lock
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
STORAGE: NONE
LOWEST_MATCHING: TRUE
NUGET
remote: https://www.nuget.org/api/v2
altcover (6.7.750)
Expand Down
16 changes: 8 additions & 8 deletions src/FParsec/AssemblyInfo.fs
Original file line number Diff line number Diff line change
Expand Up @@ -4,20 +4,20 @@ open System.Reflection

[<assembly: AssemblyTitleAttribute("FParsec")>]
[<assembly: AssemblyProductAttribute("NpgsqlFSharpAnalyzer")>]
[<assembly: AssemblyVersionAttribute("3.21.0")>]
[<assembly: AssemblyVersionAttribute("3.22.0")>]
[<assembly: AssemblyMetadataAttribute("ReleaseDate","2020-12-08T00:00:00.0000000")>]
[<assembly: AssemblyFileVersionAttribute("3.21.0")>]
[<assembly: AssemblyInformationalVersionAttribute("3.21.0")>]
[<assembly: AssemblyFileVersionAttribute("3.22.0")>]
[<assembly: AssemblyInformationalVersionAttribute("3.22.0")>]
[<assembly: AssemblyMetadataAttribute("ReleaseChannel","release")>]
[<assembly: AssemblyMetadataAttribute("GitHash","2d384f746febd40976d8f3f2cc4314f4d0c05681")>]
[<assembly: AssemblyMetadataAttribute("GitHash","ad927a4fc51c240225e8bec9af7799527f392652")>]
do ()

module internal AssemblyVersionInformation =
let [<Literal>] AssemblyTitle = "FParsec"
let [<Literal>] AssemblyProduct = "NpgsqlFSharpAnalyzer"
let [<Literal>] AssemblyVersion = "3.21.0"
let [<Literal>] AssemblyVersion = "3.22.0"
let [<Literal>] AssemblyMetadata_ReleaseDate = "2020-12-08T00:00:00.0000000"
let [<Literal>] AssemblyFileVersion = "3.21.0"
let [<Literal>] AssemblyInformationalVersion = "3.21.0"
let [<Literal>] AssemblyFileVersion = "3.22.0"
let [<Literal>] AssemblyInformationalVersion = "3.22.0"
let [<Literal>] AssemblyMetadata_ReleaseChannel = "release"
let [<Literal>] AssemblyMetadata_GitHash = "2d384f746febd40976d8f3f2cc4314f4d0c05681"
let [<Literal>] AssemblyMetadata_GitHash = "ad927a4fc51c240225e8bec9af7799527f392652"
16 changes: 8 additions & 8 deletions src/NpgsqlFSharpAnalyzer.Core/AssemblyInfo.fs
Original file line number Diff line number Diff line change
Expand Up @@ -4,20 +4,20 @@ open System.Reflection

[<assembly: AssemblyTitleAttribute("NpgsqlFSharpAnalyzer.Core")>]
[<assembly: AssemblyProductAttribute("NpgsqlFSharpAnalyzer")>]
[<assembly: AssemblyVersionAttribute("3.21.0")>]
[<assembly: AssemblyVersionAttribute("3.22.0")>]
[<assembly: AssemblyMetadataAttribute("ReleaseDate","2020-12-08T00:00:00.0000000")>]
[<assembly: AssemblyFileVersionAttribute("3.21.0")>]
[<assembly: AssemblyInformationalVersionAttribute("3.21.0")>]
[<assembly: AssemblyFileVersionAttribute("3.22.0")>]
[<assembly: AssemblyInformationalVersionAttribute("3.22.0")>]
[<assembly: AssemblyMetadataAttribute("ReleaseChannel","release")>]
[<assembly: AssemblyMetadataAttribute("GitHash","2d384f746febd40976d8f3f2cc4314f4d0c05681")>]
[<assembly: AssemblyMetadataAttribute("GitHash","ad927a4fc51c240225e8bec9af7799527f392652")>]
do ()

module internal AssemblyVersionInformation =
let [<Literal>] AssemblyTitle = "NpgsqlFSharpAnalyzer.Core"
let [<Literal>] AssemblyProduct = "NpgsqlFSharpAnalyzer"
let [<Literal>] AssemblyVersion = "3.21.0"
let [<Literal>] AssemblyVersion = "3.22.0"
let [<Literal>] AssemblyMetadata_ReleaseDate = "2020-12-08T00:00:00.0000000"
let [<Literal>] AssemblyFileVersion = "3.21.0"
let [<Literal>] AssemblyInformationalVersion = "3.21.0"
let [<Literal>] AssemblyFileVersion = "3.22.0"
let [<Literal>] AssemblyInformationalVersion = "3.22.0"
let [<Literal>] AssemblyMetadata_ReleaseChannel = "release"
let [<Literal>] AssemblyMetadata_GitHash = "2d384f746febd40976d8f3f2cc4314f4d0c05681"
let [<Literal>] AssemblyMetadata_GitHash = "ad927a4fc51c240225e8bec9af7799527f392652"
16 changes: 8 additions & 8 deletions src/NpgsqlFSharpAnalyzer/AssemblyInfo.fs
Original file line number Diff line number Diff line change
Expand Up @@ -4,20 +4,20 @@ open System.Reflection

[<assembly: AssemblyTitleAttribute("NpgsqlFSharpAnalyzer")>]
[<assembly: AssemblyProductAttribute("NpgsqlFSharpAnalyzer")>]
[<assembly: AssemblyVersionAttribute("3.21.0")>]
[<assembly: AssemblyVersionAttribute("3.22.0")>]
[<assembly: AssemblyMetadataAttribute("ReleaseDate","2020-12-08T00:00:00.0000000")>]
[<assembly: AssemblyFileVersionAttribute("3.21.0")>]
[<assembly: AssemblyInformationalVersionAttribute("3.21.0")>]
[<assembly: AssemblyFileVersionAttribute("3.22.0")>]
[<assembly: AssemblyInformationalVersionAttribute("3.22.0")>]
[<assembly: AssemblyMetadataAttribute("ReleaseChannel","release")>]
[<assembly: AssemblyMetadataAttribute("GitHash","2d384f746febd40976d8f3f2cc4314f4d0c05681")>]
[<assembly: AssemblyMetadataAttribute("GitHash","ad927a4fc51c240225e8bec9af7799527f392652")>]
do ()

module internal AssemblyVersionInformation =
let [<Literal>] AssemblyTitle = "NpgsqlFSharpAnalyzer"
let [<Literal>] AssemblyProduct = "NpgsqlFSharpAnalyzer"
let [<Literal>] AssemblyVersion = "3.21.0"
let [<Literal>] AssemblyVersion = "3.22.0"
let [<Literal>] AssemblyMetadata_ReleaseDate = "2020-12-08T00:00:00.0000000"
let [<Literal>] AssemblyFileVersion = "3.21.0"
let [<Literal>] AssemblyInformationalVersion = "3.21.0"
let [<Literal>] AssemblyFileVersion = "3.22.0"
let [<Literal>] AssemblyInformationalVersion = "3.22.0"
let [<Literal>] AssemblyMetadata_ReleaseChannel = "release"
let [<Literal>] AssemblyMetadata_GitHash = "2d384f746febd40976d8f3f2cc4314f4d0c05681"
let [<Literal>] AssemblyMetadata_GitHash = "ad927a4fc51c240225e8bec9af7799527f392652"
4 changes: 4 additions & 0 deletions src/NpgsqlFSharpAnalyzer/NpgsqlFSharpAnalyzer.fsproj
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
<Name>NpgsqlFSharpAnalyzer</Name>
<TargetFramework>netcoreapp2.0</TargetFramework>
<GenerateDocumentationFile>true</GenerateDocumentationFile>
<DisableImplicitFSharpCoreReference>true</DisableImplicitFSharpCoreReference>
<Description>Advanced embedded static analysis and type-checking for SQL code from F#</Description>
<CopyLocalLockFileAssemblies>true</CopyLocalLockFileAssemblies>
</PropertyGroup>
Expand All @@ -14,6 +15,9 @@
<ItemGroup>
<Compile Include="SqlAnalyzer.fs" />
</ItemGroup>
<ItemGroup>
<None Include="paket.references" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\..\src\NpgsqlFSharpAnalyzer.Core\NpgsqlFSharpAnalyzer.Core.fsproj" />
</ItemGroup>
Expand Down
16 changes: 8 additions & 8 deletions src/NpgsqlFSharpParser/AssemblyInfo.fs
Original file line number Diff line number Diff line change
Expand Up @@ -4,20 +4,20 @@ open System.Reflection

[<assembly: AssemblyTitleAttribute("NpgsqlFSharpParser")>]
[<assembly: AssemblyProductAttribute("NpgsqlFSharpAnalyzer")>]
[<assembly: AssemblyVersionAttribute("3.21.0")>]
[<assembly: AssemblyVersionAttribute("3.22.0")>]
[<assembly: AssemblyMetadataAttribute("ReleaseDate","2020-12-08T00:00:00.0000000")>]
[<assembly: AssemblyFileVersionAttribute("3.21.0")>]
[<assembly: AssemblyInformationalVersionAttribute("3.21.0")>]
[<assembly: AssemblyFileVersionAttribute("3.22.0")>]
[<assembly: AssemblyInformationalVersionAttribute("3.22.0")>]
[<assembly: AssemblyMetadataAttribute("ReleaseChannel","release")>]
[<assembly: AssemblyMetadataAttribute("GitHash","2d384f746febd40976d8f3f2cc4314f4d0c05681")>]
[<assembly: AssemblyMetadataAttribute("GitHash","ad927a4fc51c240225e8bec9af7799527f392652")>]
do ()

module internal AssemblyVersionInformation =
let [<Literal>] AssemblyTitle = "NpgsqlFSharpParser"
let [<Literal>] AssemblyProduct = "NpgsqlFSharpAnalyzer"
let [<Literal>] AssemblyVersion = "3.21.0"
let [<Literal>] AssemblyVersion = "3.22.0"
let [<Literal>] AssemblyMetadata_ReleaseDate = "2020-12-08T00:00:00.0000000"
let [<Literal>] AssemblyFileVersion = "3.21.0"
let [<Literal>] AssemblyInformationalVersion = "3.21.0"
let [<Literal>] AssemblyFileVersion = "3.22.0"
let [<Literal>] AssemblyInformationalVersion = "3.22.0"
let [<Literal>] AssemblyMetadata_ReleaseChannel = "release"
let [<Literal>] AssemblyMetadata_GitHash = "2d384f746febd40976d8f3f2cc4314f4d0c05681"
let [<Literal>] AssemblyMetadata_GitHash = "ad927a4fc51c240225e8bec9af7799527f392652"
20 changes: 20 additions & 0 deletions src/NpgsqlFSharpVs/NpgsqlFSharpVs.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -159,4 +159,24 @@
<PostBuildEvent>
</PostBuildEvent>
</PropertyGroup>
<Choose>
<When Condition="$(TargetFrameworkIdentifier) == '.NETFramework' And ($(TargetFrameworkVersion) == 'v4.5' Or $(TargetFrameworkVersion) == 'v4.5.1' Or $(TargetFrameworkVersion) == 'v4.5.2' Or $(TargetFrameworkVersion) == 'v4.5.3' Or $(TargetFrameworkVersion) == 'v4.6' Or $(TargetFrameworkVersion) == 'v4.6.1' Or $(TargetFrameworkVersion) == 'v4.6.2' Or $(TargetFrameworkVersion) == 'v4.6.3' Or $(TargetFrameworkVersion) == 'v4.7' Or $(TargetFrameworkVersion) == 'v4.7.1' Or $(TargetFrameworkVersion) == 'v4.7.2' Or $(TargetFrameworkVersion) == 'v4.8')">
<ItemGroup>
<Reference Include="FSharp.Core">
<HintPath>..\..\..\..\Users\zaidn\.nuget\packages\fsharp.core\4.7.2\lib\net45\FSharp.Core.dll</HintPath>
<Private>True</Private>
<Paket>True</Paket>
</Reference>
</ItemGroup>
</When>
<When Condition="($(TargetFrameworkIdentifier) == 'MonoAndroid' And ($(TargetFrameworkVersion) == 'v10.0' Or $(TargetFrameworkVersion) == 'v8.0' Or $(TargetFrameworkVersion) == 'v8.1' Or $(TargetFrameworkVersion) == 'v9.0')) Or ($(TargetFrameworkIdentifier) == '.NETCoreApp' And ($(TargetFrameworkVersion) == 'v2.0' Or $(TargetFrameworkVersion) == 'v2.1' Or $(TargetFrameworkVersion) == 'v2.2' Or $(TargetFrameworkVersion) == 'v3.0' Or $(TargetFrameworkVersion) == 'v3.1' Or $(TargetFrameworkVersion) == 'v5.0')) Or ($(TargetFrameworkIdentifier) == '.NETStandard' And ($(TargetFrameworkVersion) == 'v2.0' Or $(TargetFrameworkVersion) == 'v2.1')) Or ($(TargetFrameworkIdentifier) == '.NETCore' And $(TargetFrameworkVersion) == 'v5.0') Or ($(TargetFrameworkIdentifier) == 'Xamarin.iOS') Or ($(TargetFrameworkIdentifier) == 'Xamarin.Mac')">
<ItemGroup>
<Reference Include="FSharp.Core">
<HintPath>..\..\..\..\Users\zaidn\.nuget\packages\fsharp.core\4.7.2\lib\netstandard2.0\FSharp.Core.dll</HintPath>
<Private>True</Private>
<Paket>True</Paket>
</Reference>
</ItemGroup>
</When>
</Choose>
</Project>
2 changes: 1 addition & 1 deletion src/NpgsqlFSharpVs/source.extension.vsixmanifest
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
xmlns="http://schemas.microsoft.com/developer/vsx-schema/2011"
xmlns:d="http://schemas.microsoft.com/developer/vsx-schema-design/2011">
<Metadata>
<Identity Id="FSharpLintVs.ef00bfc3-a899-45fc-aae8-afecf8673aaf" Version="3.21.0" Language="en-US" Publisher="Zaid Ajaj" />
<Identity Id="FSharpLintVs.ef00bfc3-a899-45fc-aae8-afecf8673aaf" Version="3.22.0" Language="en-US" Publisher="Zaid Ajaj" />
<DisplayName>NpgsqlFSharpVs</DisplayName>
<Description xml:space="preserve">F# Analyzer for embedded SQL syntax analysis, type-checking for parameters and result sets and nullable column detection when writing queries using Npgsql.FSharp.</Description>
<MoreInfo>https://github.com/Zaid-Ajaj/Npgsql.FSharp.Analyzer</MoreInfo>
Expand Down
16 changes: 8 additions & 8 deletions src/Ubik/AssemblyInfo.fs
Original file line number Diff line number Diff line change
Expand Up @@ -4,20 +4,20 @@ open System.Reflection

[<assembly: AssemblyTitleAttribute("Ubik")>]
[<assembly: AssemblyProductAttribute("NpgsqlFSharpAnalyzer")>]
[<assembly: AssemblyVersionAttribute("3.21.0")>]
[<assembly: AssemblyVersionAttribute("3.22.0")>]
[<assembly: AssemblyMetadataAttribute("ReleaseDate","2020-12-08T00:00:00.0000000")>]
[<assembly: AssemblyFileVersionAttribute("3.21.0")>]
[<assembly: AssemblyInformationalVersionAttribute("3.21.0")>]
[<assembly: AssemblyFileVersionAttribute("3.22.0")>]
[<assembly: AssemblyInformationalVersionAttribute("3.22.0")>]
[<assembly: AssemblyMetadataAttribute("ReleaseChannel","release")>]
[<assembly: AssemblyMetadataAttribute("GitHash","2d384f746febd40976d8f3f2cc4314f4d0c05681")>]
[<assembly: AssemblyMetadataAttribute("GitHash","ad927a4fc51c240225e8bec9af7799527f392652")>]
do ()

module internal AssemblyVersionInformation =
let [<Literal>] AssemblyTitle = "Ubik"
let [<Literal>] AssemblyProduct = "NpgsqlFSharpAnalyzer"
let [<Literal>] AssemblyVersion = "3.21.0"
let [<Literal>] AssemblyVersion = "3.22.0"
let [<Literal>] AssemblyMetadata_ReleaseDate = "2020-12-08T00:00:00.0000000"
let [<Literal>] AssemblyFileVersion = "3.21.0"
let [<Literal>] AssemblyInformationalVersion = "3.21.0"
let [<Literal>] AssemblyFileVersion = "3.22.0"
let [<Literal>] AssemblyInformationalVersion = "3.22.0"
let [<Literal>] AssemblyMetadata_ReleaseChannel = "release"
let [<Literal>] AssemblyMetadata_GitHash = "2d384f746febd40976d8f3f2cc4314f4d0c05681"
let [<Literal>] AssemblyMetadata_GitHash = "ad927a4fc51c240225e8bec9af7799527f392652"
4 changes: 2 additions & 2 deletions src/Ubik/Ubik.fsproj
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@
<PackAsTool>true</PackAsTool>
<IsPackable>true</IsPackable>
<RollForward>Major</RollForward>
<Version>3.21.0</Version>
<PackageReleaseNotes>Detect queries within lambda expressions wrapped in single case unions</PackageReleaseNotes>
<Version>3.22.0</Version>
<PackageReleaseNotes>Detect queries within sequential expressions or statements</PackageReleaseNotes>
</PropertyGroup>

<ItemGroup>
Expand Down
16 changes: 8 additions & 8 deletions tests/NpgsqlFSharpAnalyzer.Tests/AssemblyInfo.fs
Original file line number Diff line number Diff line change
Expand Up @@ -4,20 +4,20 @@ open System.Reflection

[<assembly: AssemblyTitleAttribute("NpgsqlFSharpAnalyzer.Tests")>]
[<assembly: AssemblyProductAttribute("NpgsqlFSharpAnalyzer")>]
[<assembly: AssemblyVersionAttribute("3.21.0")>]
[<assembly: AssemblyVersionAttribute("3.22.0")>]
[<assembly: AssemblyMetadataAttribute("ReleaseDate","2020-12-08T00:00:00.0000000")>]
[<assembly: AssemblyFileVersionAttribute("3.21.0")>]
[<assembly: AssemblyInformationalVersionAttribute("3.21.0")>]
[<assembly: AssemblyFileVersionAttribute("3.22.0")>]
[<assembly: AssemblyInformationalVersionAttribute("3.22.0")>]
[<assembly: AssemblyMetadataAttribute("ReleaseChannel","release")>]
[<assembly: AssemblyMetadataAttribute("GitHash","2d384f746febd40976d8f3f2cc4314f4d0c05681")>]
[<assembly: AssemblyMetadataAttribute("GitHash","ad927a4fc51c240225e8bec9af7799527f392652")>]
do ()

module internal AssemblyVersionInformation =
let [<Literal>] AssemblyTitle = "NpgsqlFSharpAnalyzer.Tests"
let [<Literal>] AssemblyProduct = "NpgsqlFSharpAnalyzer"
let [<Literal>] AssemblyVersion = "3.21.0"
let [<Literal>] AssemblyVersion = "3.22.0"
let [<Literal>] AssemblyMetadata_ReleaseDate = "2020-12-08T00:00:00.0000000"
let [<Literal>] AssemblyFileVersion = "3.21.0"
let [<Literal>] AssemblyInformationalVersion = "3.21.0"
let [<Literal>] AssemblyFileVersion = "3.22.0"
let [<Literal>] AssemblyInformationalVersion = "3.22.0"
let [<Literal>] AssemblyMetadata_ReleaseChannel = "release"
let [<Literal>] AssemblyMetadata_GitHash = "2d384f746febd40976d8f3f2cc4314f4d0c05681"
let [<Literal>] AssemblyMetadata_GitHash = "ad927a4fc51c240225e8bec9af7799527f392652"
2 changes: 1 addition & 1 deletion tests/NpgsqlFSharpAnalyzer.Tests/Tests.fs
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ let tests =
| None -> failwith "Could not crack project"
| Some context ->
let operationBlocks = SyntacticAnalysis.findSqlOperations context
Expect.equal 11 (List.length operationBlocks) "Found ten operation blocks"
Expect.equal 11 (List.length operationBlocks) "Found 11 operation blocks"
}

test "Syntactic analysis: no SQL blocks should be found using sprintf" {
Expand Down
16 changes: 8 additions & 8 deletions tests/examples/hashing/AssemblyInfo.fs
Original file line number Diff line number Diff line change
Expand Up @@ -4,20 +4,20 @@ open System.Reflection

[<assembly: AssemblyTitleAttribute("examples")>]
[<assembly: AssemblyProductAttribute("NpgsqlFSharpAnalyzer")>]
[<assembly: AssemblyVersionAttribute("3.21.0")>]
[<assembly: AssemblyVersionAttribute("3.22.0")>]
[<assembly: AssemblyMetadataAttribute("ReleaseDate","2020-12-08T00:00:00.0000000")>]
[<assembly: AssemblyFileVersionAttribute("3.21.0")>]
[<assembly: AssemblyInformationalVersionAttribute("3.21.0")>]
[<assembly: AssemblyFileVersionAttribute("3.22.0")>]
[<assembly: AssemblyInformationalVersionAttribute("3.22.0")>]
[<assembly: AssemblyMetadataAttribute("ReleaseChannel","release")>]
[<assembly: AssemblyMetadataAttribute("GitHash","2d384f746febd40976d8f3f2cc4314f4d0c05681")>]
[<assembly: AssemblyMetadataAttribute("GitHash","ad927a4fc51c240225e8bec9af7799527f392652")>]
do ()

module internal AssemblyVersionInformation =
let [<Literal>] AssemblyTitle = "examples"
let [<Literal>] AssemblyProduct = "NpgsqlFSharpAnalyzer"
let [<Literal>] AssemblyVersion = "3.21.0"
let [<Literal>] AssemblyVersion = "3.22.0"
let [<Literal>] AssemblyMetadata_ReleaseDate = "2020-12-08T00:00:00.0000000"
let [<Literal>] AssemblyFileVersion = "3.21.0"
let [<Literal>] AssemblyInformationalVersion = "3.21.0"
let [<Literal>] AssemblyFileVersion = "3.22.0"
let [<Literal>] AssemblyInformationalVersion = "3.22.0"
let [<Literal>] AssemblyMetadata_ReleaseChannel = "release"
let [<Literal>] AssemblyMetadata_GitHash = "2d384f746febd40976d8f3f2cc4314f4d0c05681"
let [<Literal>] AssemblyMetadata_GitHash = "ad927a4fc51c240225e8bec9af7799527f392652"

0 comments on commit 9ab30a3

Please sign in to comment.