is it possible to create a folder in Source Controller Explorer using scripts?
I need to move the updated files to a folder.
Thank you,
Yes, you can create a script using the TF.exe command line or using PowerShell (there are Cmdlets that can be installed with the TFS Power Tools). If you want to create a folder, check out the Add command. If you want to move files around, then check out the Rename command.
Related
i'm trying to make a bash script that basically creates a new directory and opens it directly through visual studio code
i've managed to do that, however, now i want to make it automatically add a 'README.md' file, and open it WITH the new folder
thank you
i couldn't find anything on the internet, nor with the code help command.
solved - run:
code /path/to/folder/ /path/to/file/
documentation for vsc cli
Visual Studio keeps pops up this error when opening my solution (which includes a project that has that file). How I can solve this error?
I know that its not quite recommended but for me was one of the options to remove the files from TFS (version folder: local & remote).
Since I wasn't using the type script at all in was only within the source folders from bower repo (angular-ui-router).
I am looking for a way to execute a script when a nuget-Package is installed, but not in a VS solution or project.
I tried to include a install.ps1 in the tools folder, but it does not execute.
I thought it might be because I do not have any files in lib or content. So I included some dummy file into /content but it still does not execute.
So i changed it to an init.ps1 just to check but it still does not execute.
Now my guess is: the *.ps1 scripts only execute if I install the package into a VS solution/project. Is this correct? I did not find anything in regard in the documentation.
I am trying to install my package in a plain folder. No projects, no solutions, no VS.
Is there a way to make nuget execute any script in my case?
If you read the documentation here (Automatically Running PowerShell Scripts ) it mentions that those scripts are run in the context of a project or solution.
Most often install/uninstall action is add/remove references or files to/from the target project, so it actually makes no sence to run those without project context.
I have created an installer using visual studio 2010 installer project. The program installs correctly and works fine for all the features.
But the problem is in uninstallation, when I uninstall the program it does not delete the application directory from file system but deletes the contents of it.
Suppose I am installing the program in C:\Program Files\MyApp, it deletes the contents of MyApp folder but doesn't delete the folder it self.
Any way to do this? If there is a way then how to do this?
Does your application create files in this directory after it's been installed? If so, you might want your app to move that user-data to a more user-data-centric location like %PROGRAMDATA% so that application files and user-data are separated.
It also helps to make sure uninstall cleans up everything, and it's easier to persist user-data across upgrades.
Relevant thread - http://www.itninja.com/question/delete-folders-after-uninstall
I have written a NSIS script for my project, and I would like to automatically create the setup file when I build the project. How can I do this with Visual Studio? Is there a way to pass parameters to the script?
I mean, I would like VS to pass the Assembly Version to the script. Right now, I have to manually edit a line in the script
VIProductVersion 1.5.0.1
and I sometime forget to update it. Is there a way to automate the process?
You can create defines and/or execute script instructions by using the /D and /X makensis parameters
NSIS can also read files with !searchparse
There are two questions here.
Q1. Launch NSIS when building with Visual Studio?
A1. Make a Post-build event that runs makensis on the .nsi file:
"C:\Program Files (x86)\NSIS\makensis.exe" "$(ProjectDir)\NSISInstaller\Installer.nsi"
Q2. Pass the Assembly Version to the post build event?
A2. Answered here: Determine assembly version during a post-build event
Combined solution should be:
"C:\Program Files (x86)\NSIS\makensis.exe" "$(ProjectDir)\NSISInstaller\Installer.nsi" /DPRODUCT_VERSION=$(AssemblyVersion)