Reviving a deleted file for use in my workspace - perforce

Greetings
We run perforce with several users. Each user has their own development website that shows files in their workspace. This is great for making and viewing changes to webpages before submitting them.
Sometime ago, we deleted a few pages in Perforce. I would like to revive these pages, but not to make them visible on our live site. I want to view them in my workspace and on my dev site, but I do want to push them out to our live server.
In the "depot" tab of my P4 client, I can see the deleted files. I cannot see them in the "Workspace" tab of my client.
How can I revive them for use in my Workspace, but not make them live to the world?
I'm not a P4 admin so I could use a little guidance.
Thanks for any help,

Found my answer.
A colleague suggested I Google on "Get Revision..."
http://kb.perforce.com/UserTasks/ManagingFile..Changelists/RecoveringDeletedFiles
I used all but the last two steps and it worked.
In the P4V GUI:
Ensure that the deleted files are shown in the Depot View pane (go to the View menu, select the Filter Depot menu and click on Show Deleted Depot Files. In newer versions of P4V this will be in the 'Search' menu instead)
Locate the file in the Depot View pane
Context-click on the file and select "Get Revision"
In the "Get Revision" dialog box, click on the radio button for "Specify revision using:" and leave "Revision" in the drop down box
In the empty box to the right of the "Revision" drop down item, type in the number of the last good revision of the file
Click "Get Revision"
In the Depot View pane, context-click on the file and select "Mark for Add"
In the Depot View pane, context-click on the file and select "Submit"
Fill in the changelist description and click "Submit"

With Perforce until you commit most commands don't do anything other than affect your local view of the repository.
So you can check out older versions of the file and have them in your client and as long as you don't check them in no one else (including your live site) will see them.

In both p4win and p4v there is an option to 'show deleted files'. In p4win and p4v, you can right click a file and select 'recover deleted file'. This does what you're doing manually, and the file will be open for add.

Am I missing something? They won't be live unless you put them on your live site.

Thanks for all the replies. I'm not a Perforce Guru so forgive me if I state this incorrectly.
Our system is set up so that we have our Live production site. Files submitted in perforce show on this Live site, as is normal. The general public sees this site. Each developer also has his/her own development site that only we can see. It mirrors our Live site. Our changes to a checked-out file in Perforce can be viewed in our development site, but not the Live site - until we submit the change(s). As expected, this allows us to view our changes before making them live.
When we delete files in Perforce, they are removed from our Workspace. I can still see them in my Depot tab, but they are not visible in either my Development site or in the Live site. What I wanted to do was to get the deleted files back into my Workspace so I could view them in my Development site, but not have them be visible (checked in) on our Live site.
The last post I made with instructions on doing this worked for my purpose. The files are back in my workspace but only visible in my Development site.
I was afraid of doing some Perforce restore of the files that might automatically make them live on our Live site again. This thinking was due to my inexperience with Perforce. With all your help, I now know how to do this.
Thanks again,

Related

IBM Domino Designer stuck on 'Sync with ODP...'

I am using GitLab in combination with Sourcetree. Every time I want to commit something, I would go to my Domino Designer and right click the database, click Team Development and use 'Sync with ODP...'.
Most of the time everything works perfectly fine but sometimes the synchronization dialog pops up and just wont go away. In my Sourcetree I can see that some files are waiting to be commited but those files are not all.
So the dialog shows up, wont go away and says "Progress information" "Exporting..." and thats it.
There is no "use in background" button there and the 'cancel' button is disabled.
At this point the only thing I can do is to shut down the Designer using the task manager but the problem still wont go away even after restarting my computer and VirtualBox which I am working on (The designer runs on the VM). The only thing that changes: It sometimes gets stuck "later" in the progress.
I have read the designer hangs often due to automatic synchronization. In my case this feature is disabled.
Is there someone who can tell me what causes this problem and how I can fix it?
- Thank you in advance
(The synchronization is in progress for roughly four hours now, with no change)
Are you able to track it down to a specific design element? If there is a corruption in the DXL, the export to the ODP will probably fail. In Package Explorer you can use the "Open With..." right-click menu option to open as XML. Similarly, using the menu options to export as DXL might also highlight any corruption in DXL. Also, is the NSF local or on a server. If it's on a remote server, that may impact the performance of syncing to an ODP (which will be local).
We are using Domino Designer and Sourcetree in combination with Mercurial and Bitbucket for about a year now.
We suffered a lot of difficulties: "hanging" sync, corrupted custom controls, missing files, lot of stress etc.
What I did find out: most of the syncing problems have something to do with the file IconNote in the resources.
Sometimes the associated source contains another version of this resource, so it creates an IconNote.orig. Whenever this file exists, the syncing will go wrong. I guess that IconNote.orig isn't allowed in Resources and so the syncing stops without any warning(!) and often corrupted files.
It took me a very long time find out, but now I know: If IconNote exist in the Git, I delete it instantly! Syncing goes well aftwerwards.

Visual Studio 2012 TFS Checked out by someone else or in another place

TFS 2012 Checked out by someone else or in another place.
Is there a way to see by who this change is checkout?
I know, because the source code has not been published to the server yet, there's no way to fetch the changes made by that person. Aldo is there no way to get to know who is working on it?
Yes, i can ask arround in the team who is, but we have several teams in different offices.
So its not that obvious...
Yes, there are multiple ways to see who has a file checked out. The mentioned TFS Power tools are one way. Another is to use the commandline tools:
tf status $/TeamProject/Path/To/File.ext
You can use TFS Power Tools (Visual Studio Add-in) and do a search "by Status"
That will show you which items are checked-out, by who and in which workspace.
I found a work-around to get this information, though this procedure may not always be possible. The check-out log shows the list of users who have the file/files checked out.
Right-click on a file/folder and choose Check Out for Edit. In the Output window (if not visible, go to View > Output), you should see something like this:
$/Dev/SharePoint/Finance.Sandbox/Resources/GlobalResources.resx:
opened for edit in TGTRAPP22155;Nigel.Hewitt
opened for edit in SRCGAPP21921;Bob.Carlo
opened for edit in ARSYAPP22182;RDP-ADMN-Jane.Pierre
This should tell you the name of the user and the machine on which the file has been checked out.
(To undo your own check out operation that you just did to get the above information, right-click on the same file/folder and choose Undo Pending Changes. If prompted if you want to "Undo check-out and discard changes?", choose "No to All" to preserve your existing changes and only roll-back check-out on files that don't have changes.)

How to lock down a branch, but still allow certain users to check-in?

What I intend to do is lock the whole release branch down so nobody can do check-in.
But there's one developer that does a lot of installer changes, so he has to be able to submit changes.
Is there a way to do it?
Assuming you are an admin for the project: right-click a folder (in your case, your branch root) in source control explorer, click "Advanced/Security" in the menu, and then choose your settings. You may wish to create a new user group, or just add the user individually.
As a side note, it's often more user-friendly if you deny lock and check-in rights (rather than denying check out): if a developer is browsing the code, VS will often try to check out various files, and the error dialogs this shows when security-blocked can be quite intrusive.

How to permanently exclude web site's App_Data folder contents from TFS?

I'm finding that I need an App_Code folder in my web site, and I also need to permanently exclude it from TFS. I'm using VS2012 and TFS2012.
I've discovered some offered solutions, but they generally lead back to clicking on the "Detected Changes" link in the Team Explorer pane in order to open the "Promote Candidate Changes" window.
I can find "Included Changes". I can find "Excluded Changes". Neither contains the link to "Promote Candidate Changes".
I can't find anything marked "Detected Changes", link or otherwise. I haven't found anything that looks like a "Promote Candidate Changes" window.
Any clues as to why or to an entirely different solution that has nothing to do with those options would be greatly appreciated.

Dreamweaver - template not recognising child files until they are opened

I've got a new section for a website which I have generated for a data source and it has markup for using a Dreamweaver template.
When I add the new files and folders to the site , then update my template , it doesn't find the new files to update.
If I open one of the new files , make a change in the template , then it recognises the new file is using the template. So it's almost like I have to touch all the files with Dreamweaver first.
I've tried to open all the new files which need to use the template but then Dreamweaver CS4 crashes, I presume because of the number of files it's opening.
Anyway, does anyone know if there is a way to make Dreamweaver recognise that a block of new files belong to the template , it doesn't seem to just work automatically
Thanks
Chris
You can force Dreamweaver to recreate it's site cache, which should cause it to recognize the newly added files. You can do this by going to:
Site -> Advanced -> Recreate Site Cache
Or on the Files panel, click the Options menu on the upper right of the panel, select Site -> Recreate Site Cache.
If Recreate Site Cache is disabled in the Site menu or on the Files panel options menu, then the site cache has been disabled in the site definition. Go to: Site -> Manage Sites..., select your site, and click Edit. IN Dreamweaver CS4 on the Local Info category, there is a Enable Cache checkbox, check it and click OK. IN Dreamweaver CS5, you'll need to expand the Advanced Settings, and then select Local Info, and check the Enable Cache checkbox.

Resources