Skip to content

Commit

Permalink
[#791] Add recommendation note for p4 ignoring intermediate files in …
Browse files Browse the repository at this point in the history
…README
  • Loading branch information
mengdaming committed Oct 11, 2024
1 parent 3fd96f2 commit fd6f417
Showing 1 changed file with 32 additions and 18 deletions.
50 changes: 32 additions & 18 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -246,25 +246,39 @@ Before running TCR with Perforce, make sure that the P4 Client is properly confi
To use TCR with Perforce, you'll need to add the `--vcs=p4` to the command line (you can also set this up in
the `.tcr/config.yml`, see the [Configuration Directory](#configuration-directory) section below).

> ***Note: IDE configuration when using TCR with Perforce***
>
> In order to use TCR with Perforce, make sure to setup your IDE so that it
> automatically marks files for edit on modify. Without this you will still be able to use TCR,
> but you will have to repeatedly mark files for edit after every commit.
>
> - With VS-Code, look for available Perforce extensions to enable it
> - With JetBrains IDEs, [Perforce Helix Core](https://plugins.jetbrains.com/plugin/69-perforce-helix-core) plugin
allows to enable it
##### Ignoring intermediate files

> ***Note: Perforce limitations***
>
> At the moment, TCR over Perforce is still in the experimentation phase. It does not yet support all the options
> available with git.
> Here are the main limitations:
>
> - Option `--auto-push` or `-p` has no meaning with Perforce and is ignored
> - Sub-command `log` is not supported
> - Sub-command `stats` is not supported
As TCR automatically submits everything that changed since last submit,
you might end up with binary and/or build files in the depot.

To prevent this from happening, you
can [set up Perforce to ignore them](https://www.perforce.com/manuals/cmdref/Content/CmdRef/P4IGNORE.html).

In practice, we found that you can use the same setting as with git:

```shell
p4 set P4IGNORE=.gitignore
```

##### IDE configuration when using TCR with Perforce

In order to use TCR with Perforce, make sure to setup your IDE so that it
automatically marks files for edit on modify. Without this you will still be able to use TCR,
but you will have to repeatedly mark files for edit after every commit.

- With VS-Code, look for available Perforce extensions to enable it
- With JetBrains IDEs, [Perforce Helix Core](https://plugins.jetbrains.com/plugin/69-perforce-helix-core) plugin
allows to enable it

##### Perforce limitations

At the moment, TCR over Perforce is still in the experimentation phase. It does not yet support all the options
available with git.
Here are the main limitations:

- Option `--auto-push` or `-p` has no meaning with Perforce and is ignored
- Sub-command `log` is not supported
- Sub-command `stats` is not supported

</details>

Expand Down

0 comments on commit fd6f417

Please sign in to comment.