Compare commits

..

3 Commits
rls ... main

Author SHA1 Message Date
code liturgy be2366eb83 Nuget copy native Linux targeted library 2022-11-30 15:57:44 +00:00
code liturgy 1f7bbff842 Merge remote 2022-11-25 22:37:06 +00:00
code liturgy 61be6b226d Copy lib contents 2022-11-25 22:36:40 +00:00
11 changed files with 26 additions and 26 deletions

Binary file not shown.

View File

@ -15,6 +15,7 @@
<PackageReference Include="NUnit3TestAdapter" Version="4.2.1" /> <PackageReference Include="NUnit3TestAdapter" Version="4.2.1" />
<PackageReference Include="NUnit.Analyzers" Version="3.3.0" /> <PackageReference Include="NUnit.Analyzers" Version="3.3.0" />
<PackageReference Include="coverlet.collector" Version="3.1.2" /> <PackageReference Include="coverlet.collector" Version="3.1.2" />
<PackageReference Include="Sharp.Augeas" Version="1.1.0-g34c7ba4d4d" />
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ContentWithTargetPath Include="root\**"> <ContentWithTargetPath Include="root\**">
@ -28,7 +29,4 @@
<TargetPath>lens\%(RecursiveDir)\%(Filename)%(Extension)</TargetPath> <TargetPath>lens\%(RecursiveDir)\%(Filename)%(Extension)</TargetPath>
</ContentWithTargetPath> </ContentWithTargetPath>
</ItemGroup> </ItemGroup>
<ItemGroup>
<ProjectReference Include="..\Sharp.Augeas\Sharp.Augeas.csproj" />
</ItemGroup>
</Project> </Project>

View File

@ -1,12 +1,12 @@
using System.Runtime.InteropServices; using System.Runtime.InteropServices;
namespace Sharp.Augeas namespace Sharp.Augeas.Test
{ {
[StructLayout(LayoutKind.Sequential)] [StructLayout(LayoutKind.Sequential)]
public unsafe partial struct AugSettings { public unsafe partial struct AugSettings {
[MarshalAs(UnmanagedType.LPStr)] public string root; [MarshalAs(UnmanagedType.LPStr)] internal string root;
[MarshalAs(UnmanagedType.LPStr)] public string loadPath; [MarshalAs(UnmanagedType.LPStr)] internal string loadPath;
public AugSettings(string _root, string _loadPath ) public AugSettings(string _root, string _loadPath )
{ {
@ -19,7 +19,7 @@ namespace Sharp.Augeas
root = "NIL"; root = "NIL";
loadPath = "NIL"; loadPath = "NIL";
} }
} };
} }

View File

@ -1,5 +1,6 @@
using System.Runtime.InteropServices; using System.Runtime.InteropServices;
using System.Text; using System.Text;
using Sharp.Augeas.Test;
using static Sharp.Augeas.AugeasExtern; using static Sharp.Augeas.AugeasExtern;
namespace Sharp.Augeas namespace Sharp.Augeas

View File

@ -2,6 +2,7 @@ using System.Numerics;
using System.Runtime.InteropServices; using System.Runtime.InteropServices;
using System.Security; using System.Security;
using System.Text; using System.Text;
using Sharp.Augeas.Test;
namespace Sharp.Augeas namespace Sharp.Augeas
{ {

View File

@ -19,15 +19,14 @@
</PackageReference> </PackageReference>
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<None Include="libclAugeas.so"> <PackageReference Update="Nerdbank.GitVersioning">
<Pack>true</Pack> <Version>3.5.109</Version>
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory> </PackageReference>
</None>
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<None Include="libclAugeas.dylib"> <Content Include="libclAugeas.so">
<Pack>true</Pack> <Pack>true</Pack>
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory> <CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None> </Content>
</ItemGroup> </ItemGroup>
</Project> </Project>

View File

@ -3,7 +3,7 @@ namespace Sharp.Augeas;
public class Argument : Node public class Argument : Node
{ {
public string Value { get; set; } public string Value;
public bool SetValue(string newValue) public bool SetValue(string newValue)
{ {

View File

@ -4,14 +4,14 @@ namespace Sharp.Augeas;
public class Directive : Node public class Directive : Node
{ {
public string Value { get; set; } public string Value;
public List<Argument> Arguments { get; set; } public List<Argument> Arguments;
public bool HasArguments => Arguments.Count != 0; public bool HasArguments => Arguments.Count != 0;
/// <summary> /// <summary>
/// Sets a new value for the directive. /// Sets a new value for the directive using string literals
/// The first word is the directive value, /// The values are separated by spaces, the first value is the directive value,
/// the following words correspond to the arguments. /// the other values are values corresponding to the arguments.
/// </summary> /// </summary>
/// <param name="newValue"></param> /// <param name="newValue"></param>
public void Set(string newValue) public void Set(string newValue)
@ -31,7 +31,8 @@ public class Directive : Node
} }
/// <summary> /// <summary>
/// Set the value of this directivew without writing changes to the disk. /// Set the value of this directive.
/// Note: This doesn't write any changes to disk.
/// </summary> /// </summary>
/// <param name="newValue">New value.</param> /// <param name="newValue">New value.</param>
/// <returns></returns> /// <returns></returns>

View File

@ -4,9 +4,9 @@ namespace Sharp.Augeas
{ {
public class SuperNode : Node public class SuperNode : Node
{ {
public List<Directive> Directives { get; set; } public List<Directive> Directives;
public List<Argument> Arguments { get; set; } public List<Argument> Arguments;
public List<SuperNode> SuperNodes { get; set; } public List<SuperNode> SuperNodes;
public SuperNode(Augeas augeas, string path, string id) : base(augeas, path) public SuperNode(Augeas augeas, string path, string id) : base(augeas, path)
{ {

Binary file not shown.

View File

@ -1,6 +1,6 @@
{ {
"$schema": "https://raw.githubusercontent.com/dotnet/Nerdbank.GitVersioning/master/src/NerdBank.GitVersioning/version.schema.json", "$schema": "https://raw.githubusercontent.com/dotnet/Nerdbank.GitVersioning/master/src/NerdBank.GitVersioning/version.schema.json",
"version": "1.3", "version": "1.1",
"semVer1NumericIdentifierPadding": 1, "semVer1NumericIdentifierPadding": 1,
"publicReleaseRefSpec": [ "publicReleaseRefSpec": [
"^refs/heads/master$", "^refs/heads/master$",