Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
545 changes: 33 additions & 512 deletions package-lock.json

Large diffs are not rendered by default.

77 changes: 71 additions & 6 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -47,10 +47,17 @@
"jsonValidation": [
{
"fileMatch": [
".vscode/actions.json"
".vscode/actions.json",
"/etc/vscode/actions.json"
],
"url": "./schemas/actions.json"
},
{
"fileMatch": [
"/etc/vscode/profiles.json"
],
"url": "./schemas/profiles.json"
},
{
"fileMatch": [
"/etc/vscode/settings.json"
Expand Down Expand Up @@ -91,7 +98,7 @@
"properties": {
"name": {
"type": "string",
"description": "Connection name"
"description": "Filter name"
},
"library": {
"type": "string",
Expand Down Expand Up @@ -129,7 +136,7 @@
}
},
"default": [],
"description": "List of filters for Object List"
"description": "List of filters shown in the Object Browser"
},
"libraryList": {
"type": "array",
Expand All @@ -154,7 +161,7 @@
"additionalProperties": true
},
"default": [],
"description": "A collection of connection settings to easily switch between them on this system."
"description": "A collection of library lists, filters, and custom variables to easily switch between on this system."
},
"ifsShortcuts": {
"type": "array",
Expand All @@ -163,7 +170,7 @@
"title": "Path to directory"
},
"default": [],
"description": "List of directories shown in IFS Browser"
"description": "List of directories shown in the IFS Browser"
},
"autoSortIFSShortcuts": {
"type": "boolean",
Expand Down Expand Up @@ -1779,6 +1786,24 @@
"category": "IBM i",
"title": "Unload active profile",
"icon": "$(sign-out)"
},
{
"command": "code-for-ibmi.resolveProfile.saveChangeToServer",
"enablement": "code-for-ibmi:connected",
"category": "IBM i",
"title": "Save Changes To Server"
},
{
"command": "code-for-ibmi.resolveProfile.discardChangesAndSyncWithServer",
"enablement": "code-for-ibmi:connected",
"category": "IBM i",
"title": "Discard Changes and Sync with Server"
},
{
"command": "code-for-ibmi.resolveProfile.overwriteChangesToServer",
"enablement": "code-for-ibmi:connected",
"category": "IBM i",
"title": "Overwrite Changes to Server"
}
],
"customEditors": [
Expand Down Expand Up @@ -1975,6 +2000,11 @@
{
"id": "code-for-ibmi.compareWithLocal",
"label": "Compare with"
},
{
"id": "code-for-ibmi.resolveProfile",
"label": "Resolve...",
"icon": "$(edit-sparkle)"
}
],
"menus": {
Expand Down Expand Up @@ -2065,6 +2095,23 @@
"when": "!explorerResourceIsFolder"
}
],
"code-for-ibmi.resolveProfile": [
{
"command": "code-for-ibmi.resolveProfile.saveChangeToServer",
"when": "viewItem =~ /^profileItem_active.*_Modified/",
"group": "00_resolve@01"
},
{
"command": "code-for-ibmi.resolveProfile.discardChangesAndSyncWithServer",
"when": "viewItem =~ /^profileItem_active.*_(Modified|Out of Sync)/",
"group": "00_resolve@02"
},
{
"command": "code-for-ibmi.resolveProfile.overwriteChangesToServer",
"when": "viewItem =~ /^profileItem_active.*_Out of Sync/",
"group": "00_resolve@01"
}
],
"commandPalette": [
{
"command": "code-for-ibmi.testing.connectWithFixture",
Expand Down Expand Up @@ -2529,6 +2576,18 @@
{
"command": "code-for-ibmi.environment.profile.unload",
"when": "never"
},
{
"command": "code-for-ibmi.resolveProfile.saveChangeToServer",
"when": "never"
},
{
"command": "code-for-ibmi.resolveProfile.discardChangesAndSyncWithServer",
"when": "never"
},
{
"command": "code-for-ibmi.resolveProfile.overwriteChangesToServer",
"when": "never"
}
],
"view/title": [
Expand Down Expand Up @@ -3168,7 +3227,7 @@
},
{
"command": "code-for-ibmi.environment.profile.unload",
"when": "view === environmentView && viewItem =~ /^profilesNode/ && code-for-ibmi:activeProfile",
"when": "view === environmentView && viewItem =~ /^profileItem_active/",
"group": "inline@03"
},
{
Expand All @@ -3181,6 +3240,11 @@
"when": "view === environmentView && viewItem =~ /^profileItem_active_command/",
"group": "inline@01"
},
{
"submenu": "code-for-ibmi.resolveProfile",
"when": "view === environmentView && viewItem =~ /^profileItem_active.*_(Modified|Out of Sync)/",
"group": "inline@02"
},
{
"command": "code-for-ibmi.environment.profile.rename",
"when": "view === environmentView && viewItem =~ /^profileItem/",
Expand Down Expand Up @@ -3261,6 +3325,7 @@
"csv": "6.4.1",
"escape-string-regexp": "5.0.0",
"ignore": "7.0.5",
"jsonc-parser": "^3.3.1",
"node-ssh": "13.2.1",
"tar": "7.5.7",
"tmp": "0.2.5",
Expand Down
30 changes: 20 additions & 10 deletions schemas/actions.json
Original file line number Diff line number Diff line change
@@ -1,23 +1,22 @@
{
"type": "array",
"title": "Actions",
"description": "List of Actions that apply to this Workspace. Actions may be used to run commands on the remote system.",
"description": "List of Code for IBM i Actions which may be used to run commands on the remote system.",
"items": {
"$ref": "#/$defs/code4iAction"
},
"$defs": {
"code4iAction": {
"type": "object",
"title": "Action",
"description": "A single Action.",
"required": [
"name",
"command",
"environment",
"extensions"
],
"properties": {
"type": "object",
"title": "Action",
"description": "A single Action.",
"required": [
"name",
"command",
"environment",
"extensions"
],
"name": {
"type": "string",
"title": "Name",
Expand All @@ -29,6 +28,17 @@
"description": "The command that will be run when executing this Action.",
"default": ""
},
"type": {
"type": "string",
"title": "File system type",
"description": "File system which supports this Action.",
"default": "ile",
"enum": [
"file",
"member",
"streamfile"
]
},
"environment": {
"type": "string",
"title": "Command Environment",
Expand Down
138 changes: 138 additions & 0 deletions schemas/profiles.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,138 @@
{
"type": "array",
"title": "Profiles",
"description": "List of Code for IBM i Profiles which may be used to have collections of library lists, filters, and custom variables to easily switch between on this system",
"items": {
"$ref": "#/$defs/code4iProfile"
},
"$defs": {
"code4iProfile": {
"type": "object",
"title": "Profile",
"description": "A single profile.",
"required": [
"name",
"currentLibrary",
"libraryList",
"objectFilters",
"ifsShortcuts",
"customVariables"
],
"properties": {
"name": {
"type": "string",
"title": "Name",
"description": "Profile name"
},
"currentLibrary": {
"type": "string",
"title": "Current Library",
"description": "Library used as the current library and &CURLIB variable when running Actions.",
"default": ""
},
"libraryList": {
"type": "array",
"title": "Library List",
"description": "Library list used when running Actions.",
"default": [],
"items": {
"type": "string",
"title": "Library"
}
},
"objectFilters": {
"type": "array",
"title": "Object Filters",
"description": "List of filters shown in the Object Browser.",
"default": [],
"items": {
"type": "object",
"required": [
"name",
"library",
"object",
"types",
"member",
"memberType"
],
"properties": {
"name": {
"type": "string",
"description": "Filter name"
},
"library": {
"type": "string",
"description": "Library filter",
"maxLength": 10
},
"object": {
"type": "string",
"description": "Object filter",
"maxLength": 10
},
"types": {
"type": "array",
"description": "Object types filter",
"items": {
"type": "string",
"description": "Object type. Usually starts with an asterisk."
},
"default": [
"*ALL"
]
},
"member": {
"type": "string",
"description": "Member filter",
"maxLength": 10,
"default": "*"
},
"memberType": {
"type": "string",
"description": "Member type filter",
"maxLength": 10,
"default": "*"
}
}
}
},
"ifsShortcuts": {
"type": "array",
"title": "IFS Shortcuts",
"description": "List of directories shown in the IFS Browser.",
"default": [],
"items": {
"type": "string",
"title": "Library"
}
},
"customVariables": {
"type": "array",
"title": "Custom Variables",
"description": "Custom variables used when running Actions.",
"default": [],
"items": {
"type": "object",
"description": "Variable",
"properties": {
"name": {
"type": "string",
"description": "Variable name. Will be forced uppercase."
},
"value": {
"type": "string",
"description": "Variable value"
}
}
}
},
"setLibraryListCommand": {
"type": "string",
"title": "Set Library List Command",
"description": "Library List Command can be used to set your library list based on the result of a command like `CHGLIBL`, or your own command that sets the library list. Commands should be as explicit as possible. When refering to commands and objects, both should be qualified with a library. Put `?` in front of the command to prompt it before execution."
}
},
"additionalProperties": true
}
}
}
2 changes: 2 additions & 0 deletions schemas/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -139,6 +139,8 @@
"type": "object",
"properties": {
"codefori": {
"title": "Connection settings",
"description": "Set of Code for IBM i connection settings.",
"$ref": "#/definitions/CodeForI"
}
}
Expand Down
Loading
Loading