init.ps1 1.1 KB

1234567891011121314151617181920212223242526272829
  1. $project_name = "Lynar Studios - Standard Library"
  2. $script_directory=$PWD
  3. $root_directory=(Split-Path -Parent (Split-Path -Parent $script_directory))
  4. $test_directory="$root_directory\test"
  5. $test_resources_directory="$test_directory\resources"
  6. $test_file_name="no-writable-windows.txt"
  7. $test_file_path="$test_resources_directory\$test_file_name"
  8. $indentation=" -->"
  9. ########################################
  10. # script execution
  11. ########################################
  12. Write-Host "Setting up project '$project_name' for development on Windows environment ...
  13. "
  14. # list variables
  15. Write-Host "$indentation script directory identified as '$script_directory' ..."
  16. Write-Host "$indentation root directory identified as '$root_directory' ..."
  17. Write-Host "$indentation test directory identified as '$test_directory' ..."
  18. Write-Host "$indentation test resources directory identified as '$test_resources_directory' ..."
  19. # prepare test files
  20. Write-Host "$indentation changing permissions for '$test_file_path' file ..."
  21. Set-ItemProperty -Path $test_file_path -Name Attributes -Value ([System.IO.FileAttributes]::ReadOnly)