Skip to content

Instantly share code, notes, and snippets.

@Roald87
Created April 18, 2020 09:23
Show Gist options
  • Star 4 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Roald87/c68ea920607ec8f32d977d32f3f82712 to your computer and use it in GitHub Desktop.
Save Roald87/c68ea920607ec8f32d977d32f3f82712 to your computer and use it in GitHub Desktop.
Batch script to make hardlinks from a TwinCAT plc project to a Unit test project.
@echo off
title Make hard links from project to test project
echo This script will make hard links of the project files in the POUs folder to the test project folder.
echo Before running this script make sure you already created the neccesarry folder structure in your Plc or TwinCAT project.
for %%i in (.\path\to\project\POUs\*.TcPOU) do (
mklink /H .\path\to\testproject\POUs\%%~nxi %%i
)
pause
@Roald87
Copy link
Author

Roald87 commented Jul 1, 2021

Yes that is correct. You only have to link a file once.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment