ページ ツリー

比較バージョン

キー

  • この行は追加されました。
  • この行は削除されました。
  • 書式設定が変更されました。

...

パネル
borderColorgray
borderWidth1
borderStylesolid
title実行結果

Extension template created in the 'narrow_workspace_mappings' directory.
※"main.lua"、"manifest.json"の2ファイルが作成されます。

2."narrow_workspace_mappings"のダウンロード
  ※例題として"narrow_workspace_mappings"を使用するための手順です。

  ダウンロードサイトより2.main.luaの編集
  main.luaファイルを編集してロジックを追加します。

  今回の作業ではファイルの編集ではなく、ダウンロードサイトより"narrow_workspace_mappings"の"main.lua"を入手し
  "/master/narrow_workspace_mappings"ディレクトリ内のファイルを置き換えます

情報
iconfalse
titlePerforce Workshop(ダウンロードサイト)

narrow_workspace_mappings

3.main.luaの編集
  main.luaファイルを編集してロジックを追加します。

  編集?

4.".p4-extension"ファイルの作成
  
クライアントで"narrow_workspace_mappings.p4-extension"ファイルを作成します。
  ".p4-extension"ファイルは、サーバエクステンションをサーバにインストールする際に必要です。

...

パネル
borderColorgray
borderWidth1
borderStylesolid
title実行結果

Extension packaged successfully.
※"narrow_workspace_mappings.p4-extension"ファイルが作成されます

5.サーバエクステンションのインストール4.サーバエクステンションのインストール(確認)
  作成したサーバエクステンションを、Helixサーバに実際にインストールする前に、レポートモードで確認します。

...

パネル
borderColorgray
borderWidth1
borderStylesolid
title実行結果

Would install Extension 'ExampleInc::narrow_workspace_mappings'
   ⋮
Version: '2019.1'
UUID: 22BB3349-4AD5-8617-203B-575747XXXXXX
Developer: Perforce Software Inc.
Description: [Example Extension, sample code] Restrict client views to have a configurable minimum
directory depth. This is to prevent user from
having a wide open workspace leading to getting unecessary files.
E.g. reject a mapping of //depot/... and allow //depot/some/more/narrow/path/...
License: BSD
Homepage URL: https://swarm.workshop.perforce.com/files/guest/perforce_software/extensions/2019-1
Compatible products: p4d
   ⋮
This was report mode. Use -y to perform the operation.

6.サーバエクステンションのインストール5.サーバエクステンションのインストール(実行)
  
実行結果が確認できたら"-y"オプションを追加し、インストールを実行します。

...

パネル
borderColorgray
borderWidth1
borderStylesolid
title実行結果

Extension 'ExampleInc::narrow_workspace_mappings' version '2019.1' installed successfully.

7.インストールされているサーバエクステンションの確認6.インストールされているサーバエクステンションの確認
  
サーバエクステンションがインストールされていることを確認します

...

パネル
borderColorgray
borderWidth1
borderStylesolid
title実行結果

... extension ExampleInc::narrow_workspace_mappings
... rev 1
... developer Perforce Software Inc.
... description-snippet [Example Extension,
... UUID 22BB3349-4AD5-8617-203B-575747XXXXXX
... version 2019.1
... enabled false
... arch-dir server.extensions.dir/22BB3349-4AD5-8617-203B-575747XXXXXX/1-arch
... data-dir server.extensions.dir/22BB3349-4AD5-8617-203B-575747XXXXXX/1-data

8.サーバエクステンション構成のグローバル設定7.サーバエクステンション構成のグローバル設定
  インストールしたサーバエクステンションが、自動ログインに使用するユーザをsuperにするため、グローバル設定を変更します。
  ※コマンドで使用する
ネームスペース名は"manifest.json"ファイル内で定義されています。ここでは"ExampleInc"がネームスペース名となっています。

...

情報
title参照ページ(英文)
「Helix Core Extensions Developer Guide (2019.1)」- Server extension configuration (global and instance specs)

9.8.サーバエクステンション構成のインスタンス設定
  
インストールしたサーバエクステンションのインスタンス設定を変更します。
  本手順では、「ワークスペースのビュー定義でディポパスの階層数を3より少ない」をチェックするサーバエクステションとするため、下記の変更を行います

...

パネル
borderColorgray
borderWidth1
borderStylesolid
title赤文字部分を修正

   ⋮
ExtConfig:
        exempt_users:
                super  ●"Space-separated list of which users do NOT have this restriction"を修正
        num_level:
                3               ●"insert minimum number of level across all"を修正
   ⋮

10.インストールしたサーバエクステンションの動作確認9.インストールしたサーバエクステンションの動作確認
  P4Vを起動し、クライアントワークスペースのビューの定義を表示します
  ① [ 接続(C) ] → [ 現在のワークスペースを編集(W) ]を選択します。

...