Groups keyboard shortcuts have been updated
Dismiss
See shortcuts

GitHub Actions - Autobuild

96 views
Skip to first unread message

Jamie

unread,
Jan 1, 2025, 12:28:14 PMJan 1
to Excel-DNA
I've recently chosen to open source a project on GitHub (RadToolz).  I'd like to automate building and assemblying the XLL using GitHub Actions (YAML); however, as much as I've tried, I can't seem to get the XLL to build and save.  Has anyone had any success and might be willing to share the workflow file?

Happy New Year!

Govert van Drimmelen

unread,
Jan 3, 2025, 12:19:53 AMJan 3
to Excel-DNA
Hi Jamie,

Do you see any errors in the log?
Does your project rebuild from a command line using dotnet build?

-Govert 

On Wed, 1 Jan 2025, 19:28 Jamie, <jjpr...@gmail.com> wrote:
I've recently chosen to open source a project on GitHub (RadToolz).  I'd like to automate building and assemblying the XLL using GitHub Actions (YAML); however, as much as I've tried, I can't seem to get the XLL to build and save.  Has anyone had any success and might be willing to share the workflow file?

Happy New Year!

--
You received this message because you are subscribed to the Google Groups "Excel-DNA" group.
To unsubscribe from this group and stop receiving emails from it, send an email to exceldna+u...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/exceldna/c0679029-fbed-452d-85e9-458fc5754185n%40googlegroups.com.

Jamie

unread,
Jan 3, 2025, 3:08:12 PMJan 3
to Excel-DNA
Govert,

Glad to be in contact again.  You likely don't recall this add-in - it's the nuclear physics one from about 9 years ago!  I finally needed to update the internal nuclear data.

Here's the GitHub log from running buildxll.yml.  It looks like it builds correctly but I can't get it to pack.

2025-01-03T20:00:51.5332781Z ExcelDnaBuild: Running CreateExcelAddIn MSBuild Task 2025-01-03T20:00:51.5340534Z ExcelDnaBuild: ----Arguments---- 2025-01-03T20:00:51.5341152Z ExcelDnaBuild: FilesInProject: 7 2025-01-03T20:00:51.5341686Z ExcelDnaBuild: packages.config 2025-01-03T20:00:51.5342224Z ExcelDnaBuild: Properties\ExcelDna.Build.props 2025-01-03T20:00:51.5342832Z ExcelDnaBuild: RadToolz-AddIn.dna 2025-01-03T20:00:51.5343309Z ExcelDnaBuild: app.config 2025-01-03T20:00:51.5343703Z ExcelDnaBuild: My Project\Application.myapp 2025-01-03T20:00:51.5345172Z ExcelDnaBuild: My Project\Settings.settings 2025-01-03T20:00:51.5345642Z ExcelDnaBuild: readme.txt 2025-01-03T20:00:51.5346007Z ExcelDnaBuild: OutDirectory: bin\Release\ 2025-01-03T20:00:51.5346789Z ExcelDnaBuild: Xll32FilePath: D:\a\RadToolz\RadToolz\packages\ExcelDna.AddIn.1.8.0\build\..\tools\\net452\ExcelDna.xll 2025-01-03T20:00:51.5348229Z ExcelDnaBuild: Xll64FilePath: D:\a\RadToolz\RadToolz\packages\ExcelDna.AddIn.1.8.0\build\..\tools\\net452\ExcelDna64.xll 2025-01-03T20:00:51.5349094Z ExcelDnaBuild: Create32BitAddIn: True 2025-01-03T20:00:51.5349506Z ExcelDnaBuild: Create64BitAddIn: True 2025-01-03T20:00:51.5349914Z ExcelDnaBuild: FileSuffix32Bit: 2025-01-03T20:00:51.5350272Z ExcelDnaBuild: FileSuffix64Bit: 64 2025-01-03T20:00:51.5350654Z ExcelDnaBuild: ----------------- 2025-01-03T20:00:51.5351059Z ExcelDnaBuild: Number of files in project: 7 2025-01-03T20:00:51.5493573Z ExcelDnaBuild: RadToolz-AddIn.dna -> bin\Release\RadToolz-AddIn.dna 2025-01-03T20:00:51.5503125Z ExcelDnaBuild: ..\packages\ExcelDna.AddIn.1.8.0\build\..\tools\\net452\ExcelDna.xll -> bin\Release\RadToolz-AddIn.xll 2025-01-03T20:00:51.5515976Z ExcelDnaBuild: App.config -> bin\Release\RadToolz-AddIn.xll.config 2025-01-03T20:00:51.7591243Z ExcelDnaBuild: --- 2025-01-03T20:00:51.7598247Z ExcelDnaBuild: RadToolz-AddIn.dna -> bin\Release\RadToolz-AddIn64.dna 2025-01-03T20:00:51.7600940Z ExcelDnaBuild: ..\packages\ExcelDna.AddIn.1.8.0\build\..\tools\\net452\ExcelDna64.xll -> bin\Release\RadToolz-AddIn64.xll 2025-01-03T20:00:51.7608666Z ExcelDnaBuild: app.config -> bin\Release\RadToolz-AddIn64.xll.config 2025-01-03T20:00:51.7632601Z --- 2025-01-03T20:00:51.7637375Z ExcelDnaPack: 2025-01-03T20:00:51.7638050Z ExcelDnaPack: bin\Release\RadToolz-AddIn.dna -> bin\Release\RadToolz-AddIn-packed.xll 2025-01-03T20:00:51.7650007Z PackExcelAddIn: Running PackExcelAddIn Task 2025-01-03T20:00:51.7664820Z PackExcelAddIn: Using base add-in bin\Release\RadToolz-AddIn.xll 2025-01-03T20:00:51.7950690Z PackExcelAddIn: -> Updating resource: Type: CONFIG, Name: __MAIN__, Length: 1724 2025-01-03T20:00:51.8016720Z PackExcelAddIn: ~~> ExternalLibrary path RadToolz.dll resolved to bin\Release\RadToolz.dll. 2025-01-03T20:00:52.6503429Z PackExcelAddIn: -> Updating resource: Type: ASSEMBLY_LZMA, Name: RADTOOLZ, Length: 25499 2025-01-03T20:00:52.6534189Z PackExcelAddIn: -> Updating resource: Type: DNA, Name: __MAIN__, Length: 567 2025-01-03T20:00:52.6556072Z PackExcelAddIn: Completed Packing bin\Release\RadToolz-AddIn-packed.xll. 2025-01-03T20:00:52.6558955Z ExcelDnaPack: bin\Release\RadToolz-AddIn.xll.config -> bin\Release\RadToolz-AddIn-packed.xll.config 2025-01-03T20:00:52.6564460Z Copying file from "D:\a\RadToolz\RadToolz\RadToolz\bin\Release\RadToolz-AddIn.xll.config" to "D:\a\RadToolz\RadToolz\RadToolz\bin\Release\RadToolz-AddIn-packed.xll.config". 2025-01-03T20:00:52.6568160Z ExcelDnaPack: 2025-01-03T20:00:52.6569054Z ExcelDnaPack: bin\Release\RadToolz-AddIn64.dna -> bin\Release\RadToolz-AddIn64-packed.xll 2025-01-03T20:00:52.6570683Z PackExcelAddIn: Running PackExcelAddIn Task 2025-01-03T20:00:52.6571538Z PackExcelAddIn: Using base add-in bin\Release\RadToolz-AddIn64.xll 2025-01-03T20:00:52.6580347Z PackExcelAddIn: -> Updating resource: Type: CONFIG, Name: __MAIN__, Length: 1724 2025-01-03T20:00:52.6582665Z PackExcelAddIn: ~~> ExternalLibrary path RadToolz.dll resolved to bin\Release\RadToolz.dll. 2025-01-03T20:00:52.6715212Z PackExcelAddIn: -> Updating resource: Type: DNA, Name: __MAIN__, Length: 567 2025-01-03T20:00:52.7578796Z PackExcelAddIn: -> Updating resource: Type: ASSEMBLY_LZMA, Name: RADTOOLZ, Length: 25499 2025-01-03T20:00:52.7598214Z PackExcelAddIn: Completed Packing bin\Release\RadToolz-AddIn64-packed.xll. 2025-01-03T20:00:52.7601473Z ExcelDnaPack: bin\Release\RadToolz-AddIn64.xll.config -> bin\Release\RadToolz-AddIn64-packed.xll.config 2025-01-03T20:00:52.7604810Z Copying file from "D:\a\RadToolz\RadToolz\RadToolz\bin\Release\RadToolz-AddIn64.xll.config" to "D:\a\RadToolz\RadToolz\RadToolz\bin\Release\RadToolz-AddIn64-packed.xll.config". 2025-01-03T20:00:52.7611872Z Done Building Project "D:\a\RadToolz\RadToolz\RadToolz\RadToolz.vbproj" (default targets). 2025-01-03T20:00:52.7627825Z Done Building Project "D:\a\RadToolz\RadToolz\RadToolz.sln" (default targets). 2025-01-03T20:00:52.7649096Z 2025-01-03T20:00:52.7649436Z Build succeeded. 2025-01-03T20:00:52.7649681Z 0 Warning(s) 2025-01-03T20:00:52.7649932Z 0 Error(s) 2025-01-03T20:00:52.7650207Z 2025-01-03T20:00:52.7650881Z Time Elapsed 00:01:21.84 2025-01-03T20:00:52.8836559Z ##[group]Run $excelDnaPack = "D:\a\RadToolz\RadToolz\packages\ExcelDna.AddIn.1.8.0\tools\ExcelDnaPack.exe" 2025-01-03T20:00:52.8837583Z [36;1m$excelDnaPack = "D:\a\RadToolz\RadToolz\packages\ExcelDna.AddIn.1.8.0\tools\ExcelDnaPack.exe" [0m 2025-01-03T20:00:52.8838294Z [36;1m$dnaFile = "D:\a\RadToolz\RadToolz\RadToolz\bin\Release\RadToolz-AddIn.dna" [0m 2025-01-03T20:00:52.8839158Z [36;1m& $excelDnaPack $dnaFile /Y /O /XLL32 [0m 2025-01-03T20:00:52.8870856Z shell: C:\Program Files\PowerShell\7\pwsh.EXE -command ". '{0}'" 2025-01-03T20:00:52.8871172Z ##[endgroup] 2025-01-03T20:00:53.7559247Z [31;1m&: [0mD:\a\_temp\dc91742b-53d3-4f72-8f2e-3c71fb53ce65.ps1:4 [0m 2025-01-03T20:00:53.7560151Z [31;1m [0m [36;1mLine | [0m 2025-01-03T20:00:53.7560966Z [31;1m [0m [36;1m [36;1m 4 | [0m & [36;1m$excelDnaPack [0m $dnaFile /Y /O /XLL32 [0m 2025-01-03T20:00:53.7561682Z [31;1m [0m [36;1m [36;1m [0m [36;1m [0m [36;1m | [31;1m ~~~~~~~~~~~~~ [0m 2025-01-03T20:00:53.7562845Z [31;1m [0m [36;1m [36;1m [0m [36;1m [0m [36;1m [31;1m [31;1m [36;1m | [31;1mThe term 'D:\a\RadToolz\RadToolz\packages\ExcelDna.AddIn.1.8.0\tools\ExcelDnaPack.exe' is not recognized as a [0m 2025-01-03T20:00:53.7564382Z [31;1m [0m [36;1m [36;1m [0m [36;1m [0m [36;1m [31;1m [31;1m [36;1m [31;1m [36;1m | [31;1mname of a cmdlet, function, script file, or executable program. Check the spelling of the name, or if a path was [0m 2025-01-03T20:00:53.7565659Z [31;1m [0m [36;1m [36;1m [0m [36;1m [0m [36;1m [31;1m [31;1m [36;1m [31;1m [36;1m [31;1m [36;1m | [31;1mincluded, verify that the path is correct and try again. [0m 2025-01-03T20:00:53.7986564Z ##[error]Process completed with exit code 1.

Thanks for the assist,

Jamie

Govert van Drimmelen

unread,
Jan 7, 2025, 2:42:35 PMJan 7
to Excel-DNA
Hi Jamie,

I think you have upgraded from an old version of the Excel-DNA NuGet package, and that has left a post-build step that is no longer needed.
Can you check in your project file is there is an "ExcelDnaPack" post-build step, and just delete it?
The packing step is now done as a normal build task.

-Govert

Jamie

unread,
Jan 8, 2025, 8:10:00 PMJan 8
to Excel-DNA
That was it!!!   Thank you.  I would have never found that on my own.  The VS solution now builds on GitHub.  I removed that section from the yml  file.  The only thing I need to figure out is why the Xll's are being flagged by Microsoft Defender as containing a virus.  I had this problem with the local VS2019 build.  I found shutting off the compile optimization eliminated the false positive.  I'll figure out the correct command line syntax on GitHub to see if that resolves it on its builds.

Very best regards,

Jamie

Reply all
Reply to author
Forward
0 new messages