GithubHelp home page GithubHelp logo

sublime-text-3-perforce-plugin's People

Contributors

djfdat avatar ericmartel avatar nfvs avatar tobya avatar wadetb avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

sublime-text-3-perforce-plugin's Issues

It looks like this bit of code was removed from the ST3 version...

In ST2, under IsFolderUnderClientRoot you handled a "null" setting. This seems to have been removed in the ST3 version and I was wondering if you could put it back? :).

def IsFolderUnderClientRoot(in_folder):
# check if the file is in the depot
clientroot = GetClientRoot(in_folder)
if(clientroot == -1):
return 0

clientroot = clientroot.lower()
if(clientroot == "null"):
    return 1

file is not under client root sublime3 and windows

Hello Eric,

Thanks for good job on plugin. This is what I’ve always searched for sublime, but I’ve got a question, how can I properly configure it to work with perforce?

Cause currently I’ve got an error: “file is not under client root”

IDE: Sublime Text 3 (C:\Program Files\Sublime Text 3)
OS: Windows 7
Perforce: C:\Program Files\Perforce

p4 is in PATH, and from cmd p4 is working.

p4 SET

P4CLIENT=myworkspace
P4EDITOR=C:\Program Files\Sublime Text 3\sublime_text.exe
P4IGNORE=.p4ignore
P4PASSWD=mypassword
P4PORT=perforce.server:port
P4USER=myusername
P4_perforce.server:port_CHARSET=none

workspace

name: myworkspace
root: C:\Users\my.user\Perforce\myworkspace\

I would greatly appreciate any help you can give me in working this problem.

Saving Perforce.sublime-settings - User Hangs Sublime Text

I'm having an issue when I attempt to save the Perforce.sublime-settings in order to make modifications. I tried just copy / pasting the default config text into the empty user specific settings file but when I hit save Sublime Text hangs indefinitely. The plugin actually works out of the box with the default settings but I was curious if you had ever seen this behavior before or had any suggestions.

Thanks for this plugin by the way, it's saving me a bunch of time already.

Environment settings are erased.

Regarding v2016.06.19.20.44.38 on Windows 7.

When opening sublime my P4 environment values have the correct value in the console:

import os
print([(k,v) for k,v in os.environ.items() if "P4" in k])
[('P4USER', 'stso'), ('P4PORT', 'zel-as01.greenpeak.com:1666'), ('P4CLIENT', 'LAPTOP-HP-STSO')]

When trying to checkout a file form the Tools -> Perforce -> Checkout menu I get:

     "Perforce warning: file not under client root!"

When I check the environment again I see:

import os
print([(k,v) for k,v in os.environ.items() if "P4" in k])
[('P4USER', 'P4USER'), ('P4PORT', 'P4PORT'), ('P4CLIENT', 'P4CLIENT')]

So it looks like the plugin is erasing the environment settings! The checkout option in the menu is disabled from then on.

SIR show P4 info output.

It would be nice if you could have a button that shows the p4 info output. I jump between server and would like to be able to check when one i am current working against.

perforce login issues

I attempted to use the perforce login command (which allowed my password to be displayed in clear text, minor issue there). It never seems to be able to login. I don't see any errors emitted from the login attempt, but when I try to do something subsequently, I see the following in the console:

Perforce: Perforce password (P4PASSWD) invalid or unset.

File is not under the client root

Hi.

I've been using your p4 plugin for ST3 for a while now and I have to say it's really great. Making work much easier! So thank you for that.

Recently though, I moved from CentOS 6.5 to a new Linux installation (Ubuntu 14.04), set up perforce, installed ST3 with the plugin and started working on a file in the p4 root.
However, this time the plugin doesn't recognize that I'm in the client root.

p4 (and p4v) work without any problem. I am 100% sure that the files are inside the client root (everything is fine from command-line).

Can't seem to find any online information (in the context of the plugin) about it either.

Have you heard of similar issues occuring?
I can send you my p4 info or any other details that you might need.

Thank you,
Boris.

Various commands fail with P4V 2020.2

P4V 2020.2 removed -cmd which breaks the 'View File History' 'Time Lapse View' and other options in this plugin.

The unsupported P4V command syntax, "p4v -cmd" (described in
https://community.perforce.com/s/article/2871) will be discontinued
in P4V 2020.2. The actions available with the '-cmd' flag can be
replaced by P4VC commands. We will continue to support the "p4v -s"
and "p4v -t" functionality described in the preceding KB article.

https://www.perforce.com/perforce/doc.current/user/p4vnotes.txt

Since this plugin seems unmaintained, we may make a fork to fix this. Figured i'd bug it here for documentation.

Unable to login/connect with ST3 Perforce Plugin

Here's a Stack Overflow question containing some details on my issue:
http://stackoverflow.com/questions/19599942/sublime-text-3-perforce-plugin

In short,

  • I'm using linux mint
  • I've installed p4v, p4 and ST3.
  • I've created a P4CONFIG (named .p4settings and set the P4CONFIG environment variable to '.p4settings') in the workspace folder that contains the P4PORT, P4CLIENT and P4USER variables and their appropriate values.
  • I can connect to the perforce server using the p4 command
  • I've added the Perforce.sublime-settings files to my ~/.config/sublime-text-3/Packages/User folder that contains the other ST3 plugin settings.
  • The settings include "perforce_auto_checkout_on_save": true.
  • I've gone to terminal in the relevant folder I am trying to edit and ran the p4 info command and it seems to recognize the server and workspace I am trying to access.

Still can't log in using the ST3 Perforce: Login command, and as a result, when I save, it doesn't check out the files. There is no output in the console when I attempt to log in. No errors, and no warning/descriptive output.

Can't Login and Auto Checkout not working

I know these issues have been reported before but most of them are at least 3 years old so I figured maybe my problem isn't related. I'm also getting an error that hasn't been reported.

First off I did all of the command line configurations. I had to set the required variables on the command line because no matter what I did I couldn't get P4 to recognize my configurations in my P4CONFIG. But I know they're set because I get the correct info when I run p4 info.

When I try to login to P4 on Sublime I get the following error in the console:


Traceback (most recent call last):
  File "./python3.3/subprocess.py", line 1104, in _execute_child
OSError: [WinError 123] The filename, directory name, or volume label syntax is incorrect

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "C:\Users\user\AppData\Roaming\Sublime Text 3\Packages\Perforce\Perforce.py", line 995, in on_done
    p = subprocess.Popen(command, stdin=subprocess.PIPE,stdout=subprocess.PIPE, stderr=subprocess.PIPE, cwd=global_folder, shell=True)            
  File "./python3.3/subprocess.py", line 819, in __init__
  File "./python3.3/subprocess.py", line 1110, in _execute_child
OSError: [WinError 123] The filename, directory name, or volume label syntax is incorrect
Traceback (most recent call last):
  File "./python3.3/subprocess.py", line 1104, in _execute_child
OSError: [WinError 123] The filename, directory name, or volume label syntax is incorrect

But then I realized that if I'm logged in to P4V then I don't get that error in Sublime when I attempt to login. Everything works then except for the auto checkout feature. I did some research and found out that I had to add the Perforce settings file. So I copied Perforce.sublime-settings file from the Perforce directory into my Sublime Text 3->Packages->User directory. But I still have the same problem. I'm thinking maybe that login problem is causing the auto checkout problem.

I wouldn't mind having to login to P4V before using Sublime as long as the auto-checkout feature worked.

Any help would be appreciated.

Thanx

Console error

Hello,

I just tried the plugin but it does not work with a relatively recent version of sublime text on my machine.
The sublime text console show the following error:

Traceback (most recent call last):
  File "C:\Program Files\Sublime Text\Lib\python33\sublime_plugin.py", line 948, in on_deactivated
    run_view_callbacks('on_deactivated', view_id)
  File "C:\Program Files\Sublime Text\Lib\python33\sublime_plugin.py", line 708, in run_view_callbacks
    callback(v, *args)
  File "C:\Program Files\Sublime Text\Lib\python33\sublime_plugin.py", line 152, in profiler
    return event_handler(*args)
  File "C:\Users\jrichard3\AppData\Roaming\Sublime Text\Installed Packages\Subforce - Perforce for Sublime.sublime-package\Subforce.py", line 352, in on_deactivated
    self.updateStatus(view)
  File "C:\Users\jrichard3\AppData\Roaming\Sublime Text\Installed Packages\Subforce - Perforce for Sublime.sublime-package\Subforce.py", line 362, in updateStatus
    with PerforceWrapper(squelchErrorAndWarninMessages=True) as p4:
  File "C:\Users\jrichard3\AppData\Roaming\Sublime Text\Installed Packages\Subforce - Perforce for Sublime.sublime-package\Subforce.py", line 66, in __init__
    projectPath = sublime.active_window().extract_variables()['folder']
KeyError: 'folder'

The key does not exist. I guess it has been deleted recently.
This cause the plugin not to be able to do a command on any file.

How to fix this:

sublime.active_window().extract_variables()['file_path'] can be used to get the file path of the current window and the containing folder can be extracted using os.path.dirname. This works on my machine with that.
It looks like the code Perforce.py on master is different and does not contains this line.

plugin not working on all fronts

None of the functionality of the plugin is working for me. I wonder if it's because the root folders of my ST3 project are not the same as the root folder of the Perforce workspace (which is huge, and I only work on a small part of it)?

For example, when I try to list the checked out files, it doesn't find any (I get "error: Sublime-Text-3-Perforce-Plugin.Perforce: There are no checked out files to list."). But running "p4 opened" from the terminal (from one of the root directories of my ST3 project) shows many files that I've checked out in this workspace.

Let me know what further information you might need to troubleshoot.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.