I sometimes use the feature \'Reconcile Offline Work...\' found in Perforce\'s P4V IDE to sync up any files that I have been working on while disconnected from the P4 depot.
If you are using the Eclipse Perforce plugin, then the plugin documentation lists several ways to ignore files.