Skip to content

Commit

Permalink
Add missing build instructions
Browse files Browse the repository at this point in the history
  • Loading branch information
lovettchris committed Apr 19, 2024
1 parent 50d55cd commit 1af5301
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 4 deletions.
24 changes: 22 additions & 2 deletions docs/dev/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,11 +29,27 @@ First clone the repo:
```
git clone https://github.com/microsoft/XmlNotepad.git
```
Then:

From the command line initialize your ApiKey.cs file:
```shell
echo namespace XmlNotepad { public partial class AppAnalytics { private const string ApiKey="%XMLNOTEPAD_ANALYTICSKEY%"; } } > src\model\ApiKey.cs
```
Then restore all the nuget packages
```
nuget restore xmlnotepad.sln
```
Then you can build it:
```
msbuild xmlnotepad.sln
```
Using Visual Studio:
- Load `src/XmlNotepad.sln` into Visual Studio.
- Select Debug or Release and target "Any CPU".
- Run Build Solution.
- Run Rebuild Solution (rebuild also installs any missing nuget packages)
### Debug the app
Expand All @@ -54,6 +70,10 @@ The tests all pass on Windows 10, but currently some tests fail on Windows 11, t
some breaking changes in the Windows Automation layer that XML notepad tests are using. This is
being investigated.
Note: [bug 10244](https://github.com/dotnet/winforms/issues/10244) is still open
in in .net 4.8 System.Windows.Automation of menu items that blocks the tests, so
checkout the branch `clovett/net472` to run the unit tests.
### UpdateVersions
The `UpdateVersions` project synchronizes the `Version.props` information
Expand Down
4 changes: 2 additions & 2 deletions src/UnitTests/window.cs
Original file line number Diff line number Diff line change
Expand Up @@ -406,7 +406,7 @@ void LoadMenuItems(AutomationElement menuItem, List<string> names)
_menuItems[childId] = new AutomationWrapper(subMenuItem);
LoadMenuItems(subMenuItem, names);
}
if (pattern != null) {
if (pattern != null) {
pattern.Collapse();
}
}
Expand Down Expand Up @@ -627,7 +627,7 @@ public void InvokeAsyncMenuItem(string menuItemName)

this.WaitForIdle(1000);
Sleep(1000);
// BUFBUG: This blocks on .NET 4.8 but works fine on .NET 4.7.2
// BUGBUG: This blocks on .NET 4.8 but works fine on .NET 4.7.2
// See https://github.com/dotnet/winforms/issues/10244.
item.Invoke();
this.WaitForIdle(1000);
Expand Down

0 comments on commit 1af5301

Please sign in to comment.