Compare commits

...
238 Commits
Author SHA1 Message Date
Dave Page 61f00a0cbb Update versions for 3.3. 2018-09-03 10:11:34 +01:00
Dave Page 43ccfd3af6 Update message catalogs 2018-09-03 10:09:10 +01:00
Akshay Joshi 09c388ecee Correct the documentation of View/Edit data. Fixes #3604 2018-08-31 19:02:26 +05:30
Xuri Gong 89e283fbc2 Add a geometry viewer that can render PostGIS data on a blank canvas or various map sources. Fixes #1407 2018-08-30 13:59:44 +01:00
Akshay Joshi b665f8fac8 Fixed auto complete issue for EPAS database server. 2018-08-30 12:30:00 +05:30
Aditya Toshniwal 283a69a21a Fix auto scrolling issue in debugger on step in and step out. Fixes #3554. 2018-08-29 18:20:45 +05:30
Harshal Dhumal 208ee4da8c Fixed debugger execution issues:
1. Allow debugging of EPAS package procedures/functions with INOUT params.
 2. Add support for indirect debugging for EPAS package procedures/functions.
 3. Allow debugging with NULL param values.
 4. Remove saved debug arguments.

Fixes #3191
2018-08-29 17:44:37 +05:30
Maxim Zakharov b7ad95907a When building the Windows installer, copy system Python packages before installing dependencies to ensure we don't end up with older versions than intended. Fixes #3579 2018-08-29 11:33:25 +01:00
Murtuza Zabuawala 9c8cf26784 Ensure that refresh button on dashboard should refresh the table. Fixes #3525 2018-08-29 11:24:45 +05:30
Akshay Joshi dd3c7c94e6 Ensure external table node should be visible only for GPDB. Fixes #3548 2018-08-27 19:11:25 +05:30
Aditya Toshniwal ea787b30eb Fixed auto complete issues for Python 2.6 2018-08-27 16:37:00 +05:30
Akshay Joshi 7a3f3046df Merge pgcli code with version 1.10.3, which is used for auto complete feature. 2018-08-27 15:00:56 +05:30
Aditya Toshniwal 25679fd542 Ensure sort/filter dialog should display proper message after losing database connection. Fixes #3561 2018-08-22 16:38:31 +05:30
Murtuza Zabuawala 0f17b4f738 Ensure 'select all' and 'unselect all' working properly for pgAgent schedule. Fixes #3313. 2018-08-22 15:13:40 +05:30
Akshay Joshi 0ab1305ddf 1. Added new backup/restore options for PostgreSQL 11. Fixes #3503
2. Ensure backup should work with '--data-only' and '--schema-only' for any format. Fixes #3347
3. Added supported "Dump Options" for "pg_dumpall" which was not there since pgAdmin 3.
4. Fixed issue where "--clean" should not clubbed with "--data-only" while taking backup.
5. Fixed "--oids" should not clubbed with "--inserts" or "--column-inserts" while taking backup.
2018-08-22 12:17:50 +05:30
Harshal Dhumal 013ad7446f Make the session thread safe.
As sessions in pgAdmin4 are filesystem based session, they need locking
for avoiding the access from multiple threads, specially running as an
WSGI application.

Fixes #3547
2018-08-22 11:58:27 +05:30
Usman Muzaffar 70c95fcdd5 Stabilise feature tests for continuous running on CI systems. Fixes #3136. 2018-08-21 17:39:36 +05:30
Aditya Toshniwal 57660d131f 1) Fix sort/filter dialog editing issue. Fixes #3558.
2) Fix sort/filter dialog issue where it incorrectly requires ASC/DESC. Fixes #3325.
2018-08-21 13:05:40 +05:30
Joao De Almeida Pereira 46d4bf027d Ensure sql for Role should be visible in SQL panel for GPDB. Fixes #3578 2018-08-17 14:50:16 +05:30
Akshay Joshi d68c967423 Fix passing of --globals-only to global backups. 2018-08-16 14:20:32 +01:00
Aditya Toshniwal ff87cf5544 Correctly handle "values" in web/pgadmin/__init__.py -> strip_version_number which can be None in some cases and will cause exception when None 2018-08-16 09:23:58 +01:00
Ashesh Vashi 0a8d7a37b9 Changed the icon, label, inode, etc. propely while refreshing the
browser tree item.

Refs #3461
2018-08-14 10:18:03 +05:30
Akshay Joshi 008359ad3a Ensure that refreshing a node also updates the Property list. Fixes #3461 2018-08-13 13:47:07 +01:00
Ashesh Vashi ffd41009ea We were refering to the wrong 'name' variable during cleaning up the
backform controls.
2018-08-12 15:44:52 +05:30
Akshay Joshi 7b2c1bb9f8 Handle connection errors properly in the query tool. Fixes #3528 2018-08-10 13:51:32 +01:00
Isaias Sanchez 2eac2f43ac Add a Spanish translation. Fixes #3553 2018-08-08 17:17:26 +01:00
Akshay Joshi 7117ce6a22 Fix keyboard shortcuts layout in the preferences panel. Fixes #3407 2018-08-07 14:41:50 +01:00
Identifier Anonymous 3a5684510a Updated Japanese translation. 2018-08-07 13:07:47 +01:00
Khushboo Vashi d4b3ded725 Add missing library to list. 2018-08-07 09:21:30 +01:00
Akshay Joshi 7479467a54 Update version and message catalog for release. 2018-08-06 16:15:11 +05:30
Akshay Joshi c8c5f83dfe Add support to save and clear SSH Tunnel password. Fixes #3511 2018-08-06 15:56:46 +05:30
Akshay Joshi 52fc0846cd pgAdmin4 should work with python 3.7, Fixes #3458 2018-08-06 15:35:03 +05:30
Aditya Toshniwal cb8a288f85 Added version number for URL's to ensure that files are only cached on a per-version basis. Fixes #2136. 2018-08-06 15:21:10 +05:30
Akshay Joshi a17aa212f0 COST statement should not be automatically duplicated after creating trigger function. Fixes #3526 2018-08-06 11:54:25 +05:30
Akshay Joshi e9e8b0b433 1. Change the string from 'Reset server password" to "Clear Saved Password" and move this sub menu from File to Object menu.
2. Move the "Change Password..." menu from 'File' to 'Object' menu.
RM #3074
2018-08-03 16:41:01 +05:30
Akshay Joshi 8f45e6fe68 View Data->Filtered Rows dialog should be displayed. Fixes #3527 2018-08-02 18:15:58 +05:30
Ashesh Vashi c4267f0878 Fixed couple of issues for the dashboard.
- Filter for the grids were showing on the server level dashboard.
  It was regression of the commit-id: f7e43d5e5
- Mark 'is_server_dashboard', and 'is_database_dashboard' to false, when
  the node has its own dashboard URL defined.
2018-07-30 13:33:20 +05:30
Khushboo Vashi 0cb25bde63 Add support for primary key, foreign key, unique key, indexes and triggers on partitioned tables for PG/EPAS 11. Fixes #3412 2018-07-27 17:31:21 +05:30
Akshay Joshi 0138dee989 Add support for reset saved password. Fixes #3074 2018-07-27 14:36:42 +05:30
Ashesh Vashi 00139f7750 Remove the unused variable to satisfy the linter. 2018-07-27 13:43:37 +05:30
Ashesh Vashi 5ff2942b4d Improved the functionality of enable/disable the auto-collection of
the graph data.

- Dashboard is intereseted only on the current selected object in the
  browser tree. And, not the one, which was got disconnected.
- Disable the auto-collection of data selectively, and only when the
  selected object got disconnected, and not when changing back to the
  Dashboard panel (as per Aditya).
2018-07-27 13:14:24 +05:30
Ashesh Vashi 35862b94a9 We need to remove the interval callbacks for retrieving the statistics
for the charts on dashboard every time the URL changed (not - just when
connection to the server was alive).
2018-07-26 22:44:34 +05:30
Ashesh Vashi e2ce73d855 'anyFamilyMember' runs the condition function for all nodes in the
hierarchy. No need to run the 'dashboardURL' function in the
'getDashboardURL' function for the current node too.
2018-07-26 21:37:40 +05:30
Aditya Toshniwal be3f9570e3 Fixed dashboard reloading even if subnodes under a dashboard or server selected. 2018-07-25 13:11:00 +01:00
Ashesh Vashi 53b5043520 As per Aditya - we need the server version for the certain operations,
which was removed during previous commit.
2018-07-25 13:07:28 +05:30
Ashesh Vashi e12e00703f Refactored the dashboard code, which was allowing each node type to
define its own dashboardURL.

There was a typo, while calling the dashboard function of a Node type.
2018-07-25 12:28:44 +05:30
Aditya Toshniwal f7e43d5e50 Realtime preference handling for the Dashboards and Debugger. Fixes #3294 2018-07-24 16:31:44 +01:00
Dave Page ae814d76d3 Update release notes. 2018-07-23 16:19:19 +01:00
Dave Page d7eb41fff4 Include a cacert file when needed for the upgrade check. Fixes #3185 2018-07-23 16:15:58 +01:00
Dave Page 58ef723476 SESSION_SKIP_PATHS should be set before we load local or distro config files. 2018-07-23 15:44:54 +01:00
Akshay Joshi 213cb440d0 Add support for SCRAM password changes (requires psycopg2 >= 2.8). Fixes #2214 2018-07-23 15:03:44 +01:00
Khushboo Vashi 2d1e835d32 Fix panel errors seen when click on partitions. 2018-07-23 14:33:40 +01:00
Dave Page cb9fffc7de Remove comment that's not really needed any more. 2018-07-20 16:56:03 +01:00
Aditya Toshniwal c353135a3a Add support for INCLUDE columns on indexes and index constraints with PG 11+. Fixes #3462 2018-07-19 13:13:37 +01:00
Dave Page a86604160a Allow the user to specify a fixed port number in the runtime to aid cookie whitelisting etc. Fixes #3506 2018-07-19 12:54:53 +01:00
Dave Page 2ce41e77f2 Add a menu option to the runtime to copy the appserver URL to the clipboard. Fixes #3510 2018-07-19 11:32:40 +01:00
Akshay Joshi 051ce6afeb Ensure the SSH tunnel port number is honoured. Fixes #3471 2018-07-19 10:52:16 +01:00
Akshay Joshi ce768c7f8a Support SSH tunneling with keys that don't have a passphrase. Fixes #3468 2018-07-18 14:15:05 +01:00
Akshay Joshi 7f7feee8c1 Added keyboard shortcut for 'pgAdmin4' menu. 2018-07-17 18:52:06 +05:30
Akshay Joshi 1fc82d328c Fix backup in directory format on Windows. 2018-07-17 13:04:28 +01:00
Akshay Joshi ba8f745f70 Exclude system columns in Import/Export. Fixes #3448 2018-07-17 13:01:40 +01:00
Khushboo Vashi 8869fd6eb3 Fix a number of debugger execution issues. Fixes #3191
1. EPAS packages' function/procedure does not honour INOUT arguments, it converts INOUT to OUT.

2.  Packages' functions and procedures are not getting listed in their respected nodes in some scenarios like procedure having INOUT argument and function with void return type

3. The Reverse engineering SQL is not correct for Packages' functions/procedures

4. In case of INOUT argument, debugger asks for mendatory input which should not.

5. Re-executing a procedure whilst direct debugging doesn't work.
2018-07-17 12:51:24 +01:00
Akshay Joshi 39b41d7b24 Various procedure/function related fixes for EPAS/PG 11. Fixes #3446
- Fix the RM #3446 "plpgsql keyword should displayed in SQL pane for EPAS-11".
- Procedures for EPAS 11 always created as 'edbspl', even though language is sql or plpgsql.
- Not able to create Function/Procedure/Trigger function if the language is "C" for all supported database server.
- Function creation for EPAS 9.6 and above when set "Window?" flag to "Yes".
- Disable Volatility, Strict, Parallel, Estimated cost and Leak prof while creating procedures in EPAS 11 when language is not 'edbspl'.
- Rename "default" folder to "11_plus" inside "pg" directory for procedures, as procedures are supported from PG11 onwards.
- Creating/Deleting parameter in Procedure for PG 11.
- Drop procedures with arguments for PG/EPAS 11.
pg_proc table has added default value 'v' for Volatility, 100 for Cost and 'u' for Parallel for any language. All the three are not supported for Procedures in PG/EPAS 11 (excluding 'edbspl' language for EPAS). Fixed the issue where it is visible in properties panel if we create procedure using language 'plpgsql' or 'sql'.
2018-07-17 12:43:46 +01:00
Dave Page a49923dba2 Add hints for the config options. 2018-07-17 12:18:37 +01:00
Akshay Joshi 765a88addf Support running on systems without a system tray. Fixes #3316 2018-07-17 12:10:35 +01:00
Dave Page 0137cfaee3 Update message catalogs:
1455 of 1984 messages (73%) translated in pgadmin/translations/de/LC_MESSAGES/messages.po
1910 of 1984 messages (96%) translated in pgadmin/translations/fr/LC_MESSAGES/messages.po
1941 of 1984 messages (97%) translated in pgadmin/translations/ja/LC_MESSAGES/messages.po
1789 of 1984 messages (90%) translated in pgadmin/translations/ko/LC_MESSAGES/messages.po
1785 of 1984 messages (89%) translated in pgadmin/translations/pl/LC_MESSAGES/messages.po
1787 of 1984 messages (90%) translated in pgadmin/translations/ru/LC_MESSAGES/messages.po
1411 of 1984 messages (71%) translated in pgadmin/translations/zh/LC_MESSAGES/messages.po
2018-07-12 10:04:07 +01:00
Ioseph Kim c7325bea93 Add a Korean translation. 2018-07-12 10:02:54 +01:00
Dave Page c6dba67d06 Add "messages" target to extract, update and compile message catalogs for convenience. 2018-07-12 10:00:40 +01:00
Dave Page 0c6e80f64d Improve sizing on Linux 2018-07-11 13:31:19 +01:00
Aditya Toshniwal 2b9c0a63fb Ensure CodeMirror always has a non-zero font size. Fixes #3480 2018-07-10 13:58:44 +01:00
Aditya Toshniwal 3b862bd70b More jQuery 3 updates. 2018-07-10 10:59:53 +01:00
Aditya Toshniwal d1784137a5 Ensure text is visible in the SQL Filter dialogue. Fixes #3478 2018-07-09 14:08:41 +01:00
Aditya Toshniwal 41a8333145 Replace deprecated success, error callbacks in $.ajax call with new functions .done and .fail. 2018-07-09 13:54:00 +01:00
Khushboo Vashi 81312d17e2 Add feature tests for Backup/Restore and Maintenance. Fixes #3206 2018-07-09 11:27:25 +01:00
Akshay Joshi 2b20b387e2 Add support for Trigger and JIT stats in the graphical query plan viewer. Fixes #3397 2018-07-06 13:13:14 +01:00
Aditya Toshniwal 73530c05aa Add missing files related to previous commit: Infrastructure and changes to the Query Tool for realtime preference handling. Refs #3294 2018-07-05 11:41:01 +01:00
Aditya Toshniwal bdb7e3fde2 Infrastructure and changes to the Query Tool for realtime preference handling. Refs #3294
Highlights of this patch include:
- Changes will affect SQL Editors in Create dialog boxes, SQL tab of the main screen, Query tool, History entries in the query tool, Query tool opened in New Tab/Window
- All the components of SQL editor will refer to single source of preferences which is cached in the Browser object. All other redundant ajax get preference calls are removed.
- SQL editor will not refer template JS variables anymore, once all the references are removed the template variables will also be removed.
- Code refactoring wherever possible.
- Covered JS test cases wherever possible.
2018-07-05 11:38:43 +01:00
Aditya Toshniwal 82d77c4608 Don't create a session when the /misc/ping test endpoint is called. Fixes #3371 2018-07-05 11:12:03 +01:00
Dave Page 165c4744b0 Correct the runtime options list. 2018-07-05 09:13:46 +01:00
Dave Page e802f2db64 Correct bug number. 2018-07-02 15:55:57 +01:00
Khushboo Vashi d56f1b17f3 Fix restoring of restore options for sections. Fixes #3362 2018-07-02 15:53:19 +01:00
Khushboo Vashi 28e0220e97 Fix restoring of restore options for sections. Fixes # 2018-07-02 15:52:15 +01:00
Murtuza Zabuawala d53c47e1cf Cleanup and fix handling of Query Tool Cancel button status. Fixes #3319 2018-07-02 15:43:36 +01:00
Murtuza Zabuawala b390c033cf Fix debugging of procedures in EPAS packages. Fixes #3457 2018-06-29 15:20:33 +01:00
Khushboo Vashi fb1ef9ac0b Properly support backups in Directory format. Fixes #3309 2018-06-29 15:14:37 +01:00
Dave Page c85ced4c6b Prep 3.2 release notes page. 2018-06-29 14:37:05 +01:00
Khushboo Vashi 43aa0c9f3c Fix wheel deps 2018-06-28 13:03:24 +01:00
Dave Page fbbf9d1de2 Fix stupid typo 2018-06-28 12:56:33 +01:00
Dave Page 6afaa4f400 Fix bug number, per Khushboo 2018-06-28 11:14:57 +01:00
Dave Page 21fd953672 PEP-8 fix 2018-06-27 16:55:57 +01:00
Shubham Agarwal ec476d6274 Feature test reliability improvements:
1. click_tab() -> Added wait till element is clickable, test cases are failing since the function attempts to click the tab which is not yet in the state to be clicked.

2. add_server() -> Replaced the sleep statement with wait till element to be clickable.
2018-06-27 16:40:03 +01:00
Dave Page ce8fb28b34 Message catalog updates:
1459 of 2000 messages (72%) translated in pgadmin/translations/de/LC_MESSAGES/messages.po
1930 of 2000 messages (96%) translated in pgadmin/translations/fr/LC_MESSAGES/messages.po
1961 of 2000 messages (98%) translated in pgadmin/translations/ja/LC_MESSAGES/messages.po
1796 of 2000 messages (89%) translated in pgadmin/translations/pl/LC_MESSAGES/messages.po
1798 of 2000 messages (89%) translated in pgadmin/translations/ru/LC_MESSAGES/messages.po
1415 of 2000 messages (70%) translated in pgadmin/translations/zh/LC_MESSAGES/messages.po
2018-06-27 11:48:33 +01:00
Identifier Anonymous 6ca07528ff Japanese translation fixes. 2018-06-27 11:46:39 +01:00
Khushboo Vashi 8136b72364 Fix a French translation error that could prevent the server starting up. Fixes #3411 2018-06-27 11:42:23 +01:00
Dave Page f04b2e33b5 Prep for 3.1 release. 2018-06-26 11:13:46 +01:00
Akshay Joshi 08e4cdf2ac Updated extension upgrade message. Fixes #3445 2018-06-26 11:53:46 +05:30
Dave Page 27bb7ff5db Don't use imple variable notation in bash scripts. 2018-06-25 17:00:21 +01:00
Dave Page 5bdd80e3da Correct version comparison, per Khushboo. 2018-06-25 16:41:34 +01:00
Akshay Joshi cf29e8df90 Require v1.1 of the pldbgapi extension to debug on EPAS 11. 2018-06-25 16:01:53 +01:00
Akshay Joshi 57c054fb0e Fix various Drop menu options that were broken during the treeview refactoring.
Fixes #3442. Fixes #3443. Fixes #3444
2018-06-25 15:52:12 +01:00
Akshay Joshi 4a71c6d7af Various EPAS/PG11 function & procedure fixes. Fixes #3421. Fixes #3422 2018-06-25 14:58:02 +01:00
Akshay Joshi 1f5ca1b540 Allow sorting in the file dialogue. Fixes #3273 2018-06-25 14:41:07 +01:00
Dave Page 4ba0e1a6f3 Fix Python 2.6 support for SQL_ASCII data in the query tool. 2018-06-21 17:06:28 -04:00
Akshay Joshi 560e5f225a Allow dropping of Procedures in PG 11. Fixes #3423 2018-06-21 16:36:10 -04:00
Akshay Joshi 83f9d8a547 Minor fix to handle auto-discovery of servers with no port recorded. 2018-06-21 16:34:33 -04:00
Akshay Joshi 480fe6b9fc Fixed issue of detection of EPAS server 11 and above. Version string is changed in EPAS 11 2018-06-21 18:30:37 +05:30
Dave Page 8480c10c74 Update release notes. 2018-06-21 08:32:15 -04:00
Aditya Toshniwal df85392bbf Fix handling of SQL_ASCII data in the query tool. Fixes #3289. Fixes #3250 2018-06-21 08:26:01 -04:00
Joao Pedro De Almeida Pereira 155f82676d Fix the RE-SQL generation for GreenPlum external tables. Fixes #3431 2018-06-19 20:01:45 -04:00
Akshay Joshi 7a06acb678 Allow the connection timeout to be configured on a per-server basis. Fixes #3388 2018-06-19 19:58:46 -04:00
Dave Page 9821e28da5 Fix file permissions per Devrim 2018-06-19 16:09:49 -04:00
Dave Page 717637c5b9 Fix indent. 2018-06-18 13:47:39 -04:00
Akshay Joshi a45c33cf76 Ensure that template0 and template1 are available as tempates when creating databasesa. Fixes #3361
[regardless of the Show System Objects? option]
2018-06-18 13:41:14 -04:00
Khushboo Vashi 521985c11a README update 2018-06-18 12:51:38 -04:00
Ashesh Vashi f2cef38364 Flask 1.0.2 does not allow a dot (.) in the view_func name, which we use
during generting the routes for the node.

References:
https://github.com/pallets/flask/commit/2f57a0b917478a028859b9d036b59cf1bba6cad2
https://github.com/pallets/flask/issues/2790

Fixes #3360
Reported by: Marcelo Mendes
Investigated by: Khushboo Vashi
2018-06-18 09:58:16 +05:30
Dave Page 5f51c39e6f Delete the venv folder prior to upgrade. Fixes #3384 2018-06-17 21:10:17 -04:00
Khushboo Vashi ba8829b64f Further Python 2.6 fixes. 2018-06-15 15:03:53 +01:00
Khushboo Vashi ab54a6d39a Fix external utilities to run with Python 2.6. 2018-06-15 12:38:31 +01:00
Khushboo Vashi d1902cd639 Add Python API tests for execution of external utilities such as pg_dump. 2018-06-15 11:36:07 +01:00
Akshay Joshi 766b389001 Include the schema name on RE-SQL for packages. Fixes #3356 2018-06-15 10:40:14 +01:00
Akshay Joshi b48145f01f Add an option to auto-complete keywords in upper case. Fixes #2686 2018-06-15 10:18:56 +01:00
Akshay Joshi df7b4d55c6 Remove an extra space in Procedure templates. 2018-06-15 09:16:00 +01:00
Akshay Joshi 1a6b6f61f7 Fix documentation indexing. 2018-06-15 09:14:12 +01:00
Dave Page 96544424dd Don't pipe the list of binaries through uniq.
It seems to be overflowing a buffer and truncating output with Python 3,
plus it's being fed a single line only so isn't actually doing anything.
2018-06-14 17:03:16 +01:00
Dave Page 1d322e2cd9 Enable building of the appbundle with Python 3.6. 2018-06-14 16:16:30 +01:00
Dave Page 087db8a75e Fix stored procedure test cases so they don't fail on EPAS 9.4 2018-06-13 17:01:19 +01:00
Akshay Joshi 88a2309a26 Fix auto-complete. Fixes #3374 2018-06-13 15:53:21 +01:00
Khushboo Vashi d1ecba56b8 Function and procedure support for PG11. Fixes #3362 2018-06-13 15:03:17 +01:00
Joao De Almeida Pereira e5048b4d0b Disable ACLs for the database objects for the Greenplum due to
performance issue.

Reviewed By: Ashesh
Fixes #3415
2018-06-12 10:07:23 +05:30
Murtuza Zabuawala e2b0cf6727 Fix labels and popups on EXPLAIN plan that were broken by the jQuery 3 update. Fixes #3404 2018-06-11 17:03:21 +01:00
Victoria Henry 226c872a84 Avoid an exception on GreenPlum when retrieving RE-SQL on a table. Fixes #3409 2018-06-11 16:56:39 +01:00
Anthony DeBarros a6ee27cf25 s/shutdown/shut down/ 2018-06-08 08:45:02 +01:00
Akshay Joshi 419f9069ae Move the notifications tab between messages and history as it seems more natural there. 2018-06-06 09:23:33 +01:00
Joao De Almeida Pereira 7dd6372eeb Extract the tests and refactor some of the methods.
Extract some of the ACI Tree functionalities, and decouple it from the
main source. Also - create some abstractions from the repeated code
around the enable/disable the schema children object create/edit/delete
functionalities, and also created the dialog wrappers for backup and
restore dialogs.

Reviewed by: Khushboo and Ashesh
Refactored by: Ashesh
2018-06-05 16:42:59 +05:30
Aditya Toshniwal 920934759f Handle a potential error case in the connection status monitoring.
When you disconnect the server with an open sqleditor tab, exception
 occurs at the back end. Also, after connecting server, the sqleditor
 is not able to connect back because of the exception.
2018-06-05 11:57:56 +01:00
Aditya Toshniwal 20ea8a69f5 Fix constraint on servers table in SQLite to allow ports < 1024. Fixes #3307 2018-06-05 10:47:03 +01:00
Dave Page 2860e82c63 Fix Gunicorn binding for IPv4. 2018-05-31 10:57:09 -04:00
Dave Page 6719ff141b Correct package name 2018-05-31 10:49:30 -04:00
Dave Page 4372dd051e Include libffi-devel in the Docker build. 2018-05-31 10:48:32 -04:00
Dave Page 98f84e5f34 Ignore the ycache directory when linting. 2018-05-31 10:34:29 -04:00
Dave Page 985e089c23 Update the release notes. 2018-05-31 10:29:47 -04:00
Dave Page eec9714191 Bind the container server to ipv6 as well as ipv4 ports. Fixes #3392 2018-05-31 10:27:23 -04:00
Murtuza Zabuawala f877de6a1f Fix an issue where a change to any field in server dialog causes the 'tunnel_identity_file' model value to get included unnecessarily in the update request. Fixes #3389 2018-05-31 10:10:43 -04:00
Akshay Joshi 5f0799714d Cleanup Python 3 server startup code. Fixes #3277 2018-05-31 10:07:08 -04:00
Dave Page bc63b278be Remove bug 3357 from the release notes. As it was a fix to a feature that will be in the next release, users will never have seen the bug so we shouldn't list it in the notes. 2018-05-31 07:10:56 -04:00
Akshay Joshi 55232b0944 Fixed ordering of changes in release note and added one missing entry. 2018-05-31 14:51:58 +05:30
Ashesh Vashi 86712b1bd2 Add support for source maps in the karma test framework to aid debugging. 2018-05-30 22:09:00 -04:00
Akshay Joshi 38ee39ae7a Add support for LISTEN/NOTIFY in the query tool. Fixes #3204 2018-05-30 21:58:28 -04:00
Akshay Joshi 2b4605a9d3 Ensure backup/restore/maintenance work via SSH tunnels. Fixes #3355 2018-05-30 21:25:42 -04:00
Dave Page b00931407e Fix failed yarn changes 2018-05-30 16:53:03 -04:00
Dave Page bea176a646 Fix failed yarn changes 2018-05-30 16:52:54 -04:00
Dave Page 6a28b9ff26 Revert failed Yarn changes. 2018-05-30 16:52:37 -04:00
Dave Page 8bda4e0230 Remove duplicate options 2018-05-30 16:48:23 -04:00
Dave Page 189e307671 Fix syntax 2018-05-30 16:42:09 -04:00
Dave Page b2d4c6ef9d Disable emojis in Yarn output. 2018-05-30 16:34:47 -04:00
Akshay Joshi 17977d5d0e Fix dropping of databases over SSH tunneled connections. Fixes #3357 2018-05-28 17:37:24 -04:00
Akshay Joshi 08990cb1de Handle errors properly if they occur when renaming a database. Fixes #3353 2018-05-28 17:35:33 -04:00
Aditya Toshniwal 9f13865777 Update jQuery to 3.3.1. Fixes #3271
Patch by Aditya, with test enhancements from Anthony and Joao at Pivotal.
2018-05-25 16:26:37 +01:00
Dave Page 61d8072a8c Batch, not bash!! Correct the syntax. 2018-05-23 13:09:40 +01:00
Dave Page fa07400fdd Hack to compile PyCrypto with VC++ 2018-05-23 13:04:58 +01:00
Dave Page dab5d94b7c Fix PyCrypto if using Python 3. 2018-05-23 10:00:46 +01:00
Dave Page 2c6938491e Add missing . 2018-05-23 08:48:26 +01:00
Dave Page fa57c02d0e Add some more missing CALL statements 2018-05-22 16:35:55 +01:00
Dave Page 83bee60fa4 CALL all external programs, or labels cannot be found. 2018-05-22 16:16:30 +01:00
Dave Page 81a5e1ffd3 Minor fixes 2018-05-22 15:41:10 +01:00
Dave Page 0b5912b09c Handle dependencies that may or may not be present. 2018-05-22 14:40:44 +01:00
Dave Page 5780719035 There's no need to activate/deactivate/activate the venv. 2018-05-22 14:01:13 +01:00
Dave Page f0f530e824 Returning %ERRORLEVEL% is proving unreliable. Just return 1 instead if there's an error. 2018-05-22 13:39:03 +01:00
Dave Page 0bf89f3dc0 Need to CALL Yarn. 2018-05-21 15:34:08 +01:00
Dave Page d5e48ecdc2 Further windows make script cleanup. 2018-05-21 15:06:14 +01:00
Dave Page 066a59d89c Don't barf on nested parentheses as we may find on 64 bit systems. 2018-05-21 12:54:19 +01:00
Dave Page e1a3caa780 Major cleanup of the Windows installer build script. 2018-05-18 13:27:57 +01:00
Aditya Toshniwal 6492dacbb2 Ensure the debugger container has focus when loaded. Fixes #3295 - this time on Firefox too! 2018-05-18 11:33:42 +01:00
Aditya Toshniwal a4ed9d6976 Allow connections to servers with port numbers < 1024 which may be seen in container environments. Fixes #3307 2018-05-18 11:12:38 +01:00
Akshay Joshi 28126a0a0d Fixed pep8 issue for last commit. 2018-05-18 11:30:40 +05:30
Akshay Joshi fb0c322ccf Correct the logic to set the SUPPORT_SSH_TUNNEL flag, if the flag is set the False in local config file, then we should not override it. 2018-05-18 11:26:11 +05:30
Akshay Joshi 719938a14c Fixed issue where 'Identity file' control of SSH Tunnel tab is enabled when database is connected and 'Use SSH tunneling' flag is set to No. 2018-05-17 17:18:00 +05:30
Anthony Emengo a7ee85619d Using the '.eslintignore' config file for excluding the temporary,
vendor specific, and templates files, instead of writing our own logic
to do so.

Patch by: Anthony & Joao
Reviewed by: Khushboo
2018-05-17 11:34:04 +05:30
Dave Page bd356ff9fa Fix a couple of find/replace errors. 2018-05-16 16:35:23 +01:00
Dave Page 765e0d03be Further cleanup of the environment setup 2018-05-16 16:31:41 +01:00
Dave Page 76749efb12 Further cleanup of the environment setup 2018-05-16 16:26:00 +01:00
Dave Page 9f8f1e8972 Rough cleanup of the environment setup 2018-05-16 16:15:44 +01:00
Dave Page 6d33542b24 PGDIR isn't needed in the path and we shouldn't have random Mingw paths hard-coded. 2018-05-16 14:39:58 +01:00
Dave Page ae03b7c226 PYTHON_VERSION is set automatically. Use it to conditionally fix the backports module. 2018-05-16 14:28:15 +01:00
Dave Page 246c434b61 No need to define PGADMIN4_USE_WEBKIT any more. 2018-05-16 13:33:53 +01:00
Dave Page 4496a97a97 Assume Yarn and Node are always in the path 2018-05-16 11:58:57 +01:00
Dave Page 7a1d9c750a Use VCINSTALLDIR instead of VCDIR, as that is set by Visual Studio 2018-05-16 11:56:30 +01:00
Akshay Joshi ccf58570b1 Support running feature tests against Firefox. Fixes #3270 2018-05-15 15:10:11 +01:00
Dave Page 8d9e9eab13 Allow "make" to be overridden in the environment. 2018-05-14 17:08:40 +01:00
Dave Page fe81ae3285 Correct error message 2018-05-14 16:16:18 +01:00
Anthony Emengo ab27b9d118 Fix template handling in tests for Windows. 2018-05-14 15:47:38 +01:00
Joao De Almeida Pereira bc4d16eb83 Initial version of the new tree implementation.
This is the first version of our Tree implementation. At this point is a
very simple tree without no abstractions and with code that eventually
is not very performant, but this is only the first iteration and we are
trying to follow the 'Last Responsible Moment Principle' [1].

Implemention details:
- Creation of PGBrowser.treeMenu
- Initial version of the Tree Adaptor 'pgadmin/static/js/tree/tree.js'
- TreeFake test double that can replace the Tree for testing purposes
- Tests, As an interesting asside because Fake’s need to behave like
  the real object you will noticed that there are tests for this type
  of double and they the same as of the real object.

[1] https://medium.com/@aidanjcasey/guiding-principles-for-an-evolutionary-software-architecture-b6dc2cb24680

Patched by: Victoria && Joao
Reviewed by: Khushboo & Ashesh
2018-05-14 18:00:23 +05:30
Aditya Toshniwal a34b3f27d4 Fix webpack config regexps to be more Windows-friendly. 2018-05-11 10:23:37 +01:00
Akshay Joshi 252a9b265b Ensure server cleanup on exit only happens if the server actually started up. Fixes #3277 2018-05-11 09:33:09 +01:00
Murtuza Zabuawala e17b62c055 Using the latest version (v2.3.0) of jquery.event.drop. 2018-05-10 13:26:10 +05:30
Ashesh Vashi ccdc1a6c74 Revert back to jquery version 1.12.4 until we fix the jasmine testsuite, which is failing with jQuery (v3.0+) 2018-05-10 13:24:42 +05:30
Murtuza Zabuawala a02a4eb51a Using the latest version (v2.3.0) of jquery.event.drag to fix the
jasmine testsuite.
2018-05-10 12:24:54 +05:30
Joao De Almeida Pereira b8f49daeb8 Change the order of the shims in the shims file.
Patch by: Victoria && Joao
Reviweb by: Khushboo
2018-05-10 12:06:43 +05:30
Ashesh Vashi b8d0db7e7a Using the 'webcabin-docker' from new repository, which contains fixed
for supporting jQuery 3.0+.

Also - updated the jquery version to '^3.0'.
2018-05-10 12:02:33 +05:30
Dave Page 26ae8318f2 Release notes update. 2018-05-09 14:28:15 +01:00
Khushboo Vashi ba23ba9b8b Ensure the debugger container has focus when loaded. Fixes #3295 2018-05-09 14:26:50 +01:00
Dave Page 0ffd3d0451 Update release notes 2018-05-09 14:06:17 +01:00
Murtuza Zabuawala a68dac97c4 Set SESSION_COOKIE_SAMESITE='Lax' per Flask recommendation to prevents sending cookies with CSRF-prone requests from external sites, such as submitting a form. Fixes #3342 2018-05-09 14:04:50 +01:00
Aditya Toshniwal 5b86a67a41 Fixed query tool keyboard issue where arrow keys were not behaving as expected for execute options dropdown. Fixes #3298 2018-05-09 13:05:22 +05:30
Dave Page 5960644bae Fix ordering of changes in release notes. 2018-05-08 11:04:53 +01:00
Akshay Joshi 39ea7c2916 Updated release note for 3.1 2018-05-08 14:38:51 +05:30
Dave Page c68848e7f3 Ensure the runtime core application is setup before trying to access any settings. Fixes #3333 2018-05-08 09:54:33 +01:00
Khushboo Vashi 3ac3e73daf Fixed layout of the alertify error message in the query tool. Fixes #3310 2018-05-07 16:04:47 +05:30
Khushboo Vashi 567f764234 Backup, Maintenance and Restore should not be started if database name contains "=" symbol. Fixes #1220 #1221 2018-05-07 15:09:12 +05:30
Dave Page 8937375885 Standardise the error handling for parsing of JSON response messages from the server. Fixes #3238 2018-05-04 16:56:15 +01:00
Dave Page 4f79f00d61 One day I'll remember to update the version everywhere... 2018-05-04 14:13:57 +01:00
Dave Page 554a199fd2 Bump version to avoid confusion 2018-05-04 13:52:24 +01:00
Akshay Joshi b7fb01ab04 Add support for SSH tunneled connections. Fixes #1447 2018-05-04 11:27:27 +01:00
Murtuza Zabuawala 455c45ea85 Update chromedriver version to support Chrome 66. 2018-05-04 10:20:14 +01:00
Anthony Emengo 3ff56b2d49 Scroll cells into the viewport if needed during the CheckForViewData feature test. 2018-05-04 10:15:02 +01:00
Anthony Emengo 56658a9f8e Fix the template loader to work reliably under Windows (fixing external tables under Greenplum). Fixes #3324 2018-05-03 15:54:15 +01:00
Dave Page 59d8f6fb84 Allow feature tests to run in Chrome headless mode. 2018-05-02 16:51:17 +01:00
Dave Page f0b6fb0e5d Python 3 fixes 2018-05-02 12:05:17 +01:00
Khushboo Vashi 732d8d903d F5 key should work to refresh Browser tree. Fixes #3284
Refactoring by:  Joao Pedro De Almeida Pereira
2018-05-02 11:43:42 +05:30
Dave Page c2122fbfb9 Fix mis-edit. 2018-04-30 17:15:44 +01:00
Dave Page ae1b2149a1 HAve the clean target zap any generated JS or CSS. Fixes #3134 2018-04-30 16:13:51 +01:00
Ashesh Vashi c94439bf8e Fixed the issues for all the javascript files reported by the liner. 2018-04-30 17:51:57 +05:30
Joao De Almeida Pereira 31e73f4096 Ensure the JS-linter is running on all the tests files. 2018-04-30 17:50:51 +05:30
Dave Page 92ba055d66 Fix compiler warning. 2018-04-27 13:27:37 +01:00
Joao Pedro De Almeida Pereira 201f6d359f Cleanup some old code that was failing CI. 2018-04-26 16:21:46 +01:00
Joao De Almeida Pereira 966279c1b3 Fixed issue where icon for Partitioned tables was the same as Non Partitioned tables for GreenPlum database. Fixes #3308 2018-04-26 17:05:56 +05:30
Joao De Almeida Pereira 2ace6a60f3 Fixed display SQL of table with index for GreenPlum database. Fixes #3306 2018-04-25 12:36:41 +05:30
Ashesh Vashi b653b742ed Close button added to the alertify message box, which pops up in case of backend error. Fixes #3290 2018-04-24 18:57:31 +05:30
Dave Page eb35629712 Another attempt at making the JA translation work properly. Gettext really doesn't seem to like percentage signs. Fixes #3303 2018-04-20 09:46:50 +01:00
Taiki Terauchi 51cc7c1e33 Fix an error in the Japanese translation that caused a startup failure. Fixes #3303 2018-04-20 09:12:03 +01:00
Dave Page 3ecfabfde5 Fix python wheel dependencies. 2018-04-19 17:08:06 +01:00
Dave Page 71620dc26e This time, properly fix Alertify version requirement which inadvertently got bumped. 2018-04-18 09:23:16 +01:00
Dave Page dea7491df6 Fix Alertify version requirement which inadvertently got bumped. 2018-04-18 09:09:28 +01:00
Dave Page 8f90b801bd Fix typo 2018-04-17 09:15:17 +01:00
Dave Page bb49d69293 Add required HTMLmin version - the Flask-htmlmin package doesn't seem to pull in the right version. 2018-04-17 08:58:47 +01:00
Identifier Anonymous 0493b86d4d Update Japanese translation. 2018-04-16 15:38:39 +01:00
Aditya Toshniwal d5fdd32971 Fix an error generating SQL for trigger functions. Fixes #3179 2018-04-12 14:10:35 +01:00
Murtuza Zabuawala c08adb5567 Catch errors when trying to EXPLAIN an invalid query. Fixes #3257 2018-04-12 10:50:57 +01:00
657 changed files with 71600 additions and 30511 deletions

No files matched your search

+3 -1
View File
@@ -36,8 +36,10 @@ runtime/pgAdmin4_resource.rc
runtime/release/
runtime/ui_BrowserWindow.h
web/config_local.py
web/geckodriver.log
web/regression/test_config.json
node_modules/
web/pgAdmin/static/js/generated
web/pgadmin/static/js/generated
web/yarn-error.log
web/yarn-error.log
/web/cacert.pem
+263 -321
View File
@@ -1,193 +1,242 @@
@ECHO off
SETLOCAL
REM
REM ****************************************************************
SET WD=%CD%
SET "PGBUILDPATH=%WD%\win-build"
SET CMDOPTION=""
IF "%1" == "clean" SET CMDOPTION="VALID"
IF "%1" == "x86" SET CMDOPTION="VALID"
IF NOT %CMDOPTION%=="VALID" ( GOTO USAGE )
IF NOT %CMDOPTION%=="VALID" (
GOTO USAGE
)
SET ARCHITECTURE=%1
IF "%ARCHITECTURE%"=="clean" (
GOTO CLEAN_RELEASE
GOTO EXIT
CALL :CLEAN
EXIT /B %ERRORLEVEL%
)
REM Main Functions
CALL :SET_PGADMIN4_ENVIRONMENT
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
REM Main build sequence
CALL :SET_ENVIRONMENT
CALL :VALIDATE_ENVIRONMENT || EXIT /B 1
CALL :CLEAN || EXIT /B 1
CALL :CREATE_VIRTUAL_ENV || EXIT /B 1
CALL :CREATE_RUNTIME_ENV || EXIT /B 1
CALL :CREATE_PYTHON_ENV || EXIT /B 1
CALL :CLEANUP_ENV || EXIT /B 1
CALL :CREATE_INSTALLER || EXIT /B 1
CALL :SIGN_INSTALLER || EXIT /B 1
CALL :VALIDATE_ENVIRONMENT
EXIT /B %ERRORLEVEL%
REM Main build sequence Ends
CALL :CLEAN_RELEASE
CALL :CREATE_VIRTUAL_ENV
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
:CLEAN
ECHO Removing build directory...
IF EXIST "%PGBUILDPATH%" RD "%PGBUILDPATH%" /S /Q > nul || EXIT /B 1
CALL :CREATE_RUNTIME_ENV
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
ECHO Removing temp build directory...
IF EXIST "%WD%\pkg\win32\Output" rd "%WD%\pkg\win32\Output" /S /Q > nul || EXIT /B 1
CALL :CREATE_PYTHON_ENV
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
ECHO Removing installer configuration script...
IF EXIST DEL /q "%WD%\pkg\win32\installer.iss" > nul || EXIT /B 1
CALL :CLEANUP_ENV
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
EXIT /B 0
CALL :CREATE_INSTALLER
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
CALL :SIGN_INSTALLER
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
CD %WD%
GOTO EXIT
REM Main function Ends
:CLEAN_RELEASE
ECHO Calling clean target...
IF EXIST "%PGBUILDPATH%" rd "%PGBUILDPATH%" /S /Q
FOR /R "%WD%" %%f in (*.pyc *.pyo) do DEL /q "%%f" > nul
IF EXIST "%WD%\pkg\win32\Output" rd "%WD%\pkg\win32\Output" /S /Q
IF EXIST DEL /q "%WD%\pkg\win32\installer.iss" > nul
CD %WD%
GOTO:eof
:SET_PGADMIN4_ENVIRONMENT
:SET_ENVIRONMENT
ECHO Configuring the environment...
IF "%PYTHON_HOME%" == "" SET "PYTHON_HOME=C:\Python27"
IF "%PYTHON_DLL%" == "" SET "PYTHON_DLL=C:\Windows\SysWOW64\python27.dll"
IF "%QTDIR%" == "" SET "QTDIR=C:\Qt\5.9.1\mingw53_32"
IF "%MAKE%" == "" SET "MAKE=mingw32-make.exe"
IF "%PGDIR%" == "" SET "PGDIR=C:\Program Files (x86)\PostgreSQL\10"
IF "%INNOTOOL%" == "" SET "INNOTOOL=C:\Program Files (x86)\Inno Setup 5"
IF "%YARNDIR%" == "" SET "YARNDIR=C:\Program Files\Yarn"
IF "%NODEJSDIR%" == "" SET "NODEJSDIR=C:\Program Files\nodejs"
IF "%VCDIR%" == "" SET "VCDIR=C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC"
IF "%VCREDIST%" == "" SET "VCREDIST=C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\redist\1033\vcredist_x86.exe"
IF "%SIGNTOOL%" == "" SET "SIGNTOOL=C:\Program Files\Microsoft SDKs\Windows\v7.1A\Bin\signtool.exe"
SET "VCREDISTNAME=vcredist_x86.exe"
GOTO:eof
REM Set VCREDISTNAME (the filename)
for /f "delims=" %%i in ("%VCREDIST%") do set "VCREDISTNAME=%%~nxi"
:VALIDATE_ENVIRONMENT
REM SET the variables IF not available in windows environment
REM Set additional variables we need
SET "QMAKE=%QTDIR%\bin\qmake.exe"
SET "VIRTUALENV=venv"
SET "TARGETINSTALLER=%WD%\dist"
SET "VCREDIST=%VCDIR%\redist\1033\%VCREDISTNAME%"
FOR /F "tokens=4,5 delims=. " %%a IN ('%QMAKE% -v ^| findstr /B /C:"Using Qt version "') DO SET QT_VERSION=%%a.%%b
FOR /F "tokens=3" %%a IN ('findstr /C:"APP_RELEASE =" %WD%\web\config.py') DO SET APP_RELEASE=%%a
FOR /F "tokens=3" %%a IN ('findstr /C:"APP_REVISION =" %WD%\web\config.py') DO SET APP_REVISION_VERSION=%%a
FOR /F "tokens=3" %%a IN ('findstr /C:"APP_SUFFIX =" %WD%\web\config.py') DO SET APP_SUFFIX_VERSION=%%a
SET "VIRTUALENV=venv"
SET "TARGET_DIR=%WD%\dist"
FOR /F "tokens=3" %%a IN ('findstr /C:"APP_RELEASE =" %WD%\web\config.py') DO SET APP_MAJOR=%%a
FOR /F "tokens=3" %%a IN ('findstr /C:"APP_REVISION =" %WD%\web\config.py') DO SET APP_MINOR=%%a
FOR /F "tokens=3" %%a IN ('findstr /C:"APP_SUFFIX =" %WD%\web\config.py') DO SET APP_VERSION_SUFFIX=%%a
REM remove single quote from the string
SET APP_SUFFIX_VERSION=%APP_SUFFIX_VERSION:'=%
SET APP_VERSION_SUFFIX=%APP_VERSION_SUFFIX:'=%
SET APP_NAME=""
FOR /F "tokens=2* DELims='" %%a IN ('findstr /C:"APP_NAME =" web\config.py') DO SET APP_NAME=%%a
FOR /f "tokens=1 DELims=." %%G IN ('%PYTHON_HOME%/python.exe -c "print('%APP_NAME%'.lower().replace(' ', ''))"') DO SET APP_SHORTNAME=%%G
FOR /F "tokens=4,5 delims=. " %%a IN ('%QMAKE% -v ^| findstr /B /C:"Using Qt version "') DO SET QT_VERSION=%%a.%%b
SET INSTALLERNAME=%APP_SHORTNAME%-%APP_RELEASE%.%APP_REVISION_VERSION%-%APP_SUFFIX_VERSION%-%ARCHITECTURE%.exe
IF "%APP_SUFFIX_VERSION%" == "" SET INSTALLERNAME=%APP_SHORTNAME%-%APP_RELEASE%.%APP_REVISION_VERSION%-%ARCHITECTURE%.exe
SET APP_VERSION=%APP_MAJOR%.%APP_MINOR%
SET INSTALLERNAME=%APP_SHORTNAME%-%APP_MAJOR%.%APP_MINOR%-%APP_VERSION_SUFFIX%-%ARCHITECTURE%.exe
IF "%APP_VERSION_SUFFIX%" == "" SET INSTALLERNAME=%APP_SHORTNAME%-%APP_MAJOR%.%APP_MINOR%-%ARCHITECTURE%.exe
SET PGADMIN4_VERSION=v%APP_RELEASE%
SET PGADMIN4_APP_VERSION=%APP_RELEASE%.%APP_REVISION_VERSION%
ECHO ****************************************************************
ECHO S U M M A R Y
ECHO ****************************************************************
ECHO Target mode = x86
ECHO INNOTOOL = %INNOTOOL%
ECHO VCDIR = %VCDIR%
ECHO VCDIST = %VCREDIST%
ECHO SIGNTOOL = %SIGNTOOL%
ECHO QTDIR = %QTDIR%
ECHO QMAKE = %QMAKE%
ECHO QT_VERSION = %QT_VERSION%
ECHO YARNDIR = %YARNDIR%
ECHO NODEJSDIR = %NODEJSDIR%
ECHO PYTHON_HOME = %PYTHON_HOME%
ECHO PYTHON_DLL = %PYTHON_DLL%
ECHO PGDIR = %PGDIR%
ECHO ****************************************************************
REM Check IF path SET in enviroments really exist or not ?
IF NOT EXIST "%INNOTOOL%" GOTO err_handle_inno
IF NOT EXIST "%VCDIR%" GOTO err_handle_visualstudio
IF NOT EXIST "%VCREDIST%" GOTO err_handle_visualstudio_dist
IF NOT EXIST "%QTDIR%" GOTO err_handle_qt
IF NOT EXIST "%QMAKE%" GOTO err_handle_qt
IF NOT EXIST "%PYTHON_HOME%" GOTO err_handle_python
IF NOT EXIST "%PYTHON_DLL%" GOTO err_handle_python
IF NOT EXIST "%PGDIR%" GOTO err_handle_pg
IF NOT EXIST "%YARNDIR%" GOTO err_handle_yarn
IF NOT EXIST "%NODEJSDIR%" GOTO err_handle_nodejs
REM get Python version ex. 2.7.1 will get as 27
REM get Python version for the runtime build ex. 2.7.1 will be 27
FOR /f "tokens=1 DELims=." %%G IN ('%PYTHON_HOME%/python.exe -c "import sys; print(sys.version.split(' ')[0])"') DO SET PYTHON_MAJOR=%%G
FOR /f "tokens=2 DELims=." %%G IN ('%PYTHON_HOME%/python.exe -c "import sys; print(sys.version.split(' ')[0])"') DO SET PYTHON_MINOR=%%G
SET "PYTHON_VERSION=%PYTHON_MAJOR%%PYTHON_MINOR%"
IF NOT EXIST "%PYTHON_HOME%\Scripts\virtualenv.exe" GOTO err_handle_pythonvirtualenv
EXIT /B 0
:VALIDATE_ENVIRONMENT
ECHO ****************************************************************
ECHO S U M M A R Y
ECHO ****************************************************************
ECHO Build path: %PGBUILDPATH%
ECHO Output directory: %TARGET_DIR%
ECHO Installer name: %INSTALLERNAME%
ECHO.
ECHO Python home: %PYTHON_HOME%
ECHO Python DLL: %PYTHON_DLL%
ECHO Python version: %PYTHON_VERSION%
ECHO Python major version: %PYTHON_MAJOR%
ECHO Python minor version: %PYTHON_MINOR%
ECHO.
ECHO Qt home: %QTDIR%
ECHO qmake executable: %QMAKE%
ECHO Qt version: %QT_VERSION%
ECHO.
ECHO PostgreSQL home: %PGDIR%
ECHO.
ECHO VC++ redistributable: %VCREDIST%
ECHO VC++ redistributable file: %VCREDISTNAME%
ECHO.
ECHO innotool executable: %INNOTOOL%
ECHO signtool executable: %SIGNTOOL%
ECHO.
ECHO App major version: %APP_MAJOR%
ECHO App minor version: %APP_MINOR%
ECHO App version: %APP_VERSION%
ECHO App version suffix: %APP_VERSION_SUFFIX%
ECHO App short name: %APP_SHORTNAME%
ECHO App name: %APP_NAME%
ECHO ****************************************************************
ECHO Checking the environment...
IF NOT EXIST "%INNOTOOL%" (
ECHO !INNOTOOL! does not exist
ECHO Please install Innotool and set the INNOTOOL environment variable.
EXIT /B 1
)
IF NOT EXIST "%VCREDIST%" (
ECHO !VCREDIST! does not exist
ECHO Please install Microsoft Visual studio and set the VCREDIST environment variable.
EXIT /B 1
)
IF NOT EXIST "%QTDIR%" (
ECHO !QTDIR! does not exist.
ECHO Please install Qt and set the QTDIR environment variable.
EXIT /B 1
)
IF NOT EXIST "%QMAKE%" (
ECHO !QMAKE! does not exist.
ECHO Please install Qt and set the QTDIR environment variable.
EXIT /B 1
)
IF NOT EXIST "%PYTHON_HOME%" (
ECHO !PYTHON_HOME! does not exist.
ECHO Please install Python and set the PYTHON_HOME environment variable.
EXIT /B 1
)
IF NOT EXIST "%PYTHON_DLL%" (
ECHO !PYTHON_DLL! does not exist.
ECHO Please install Python and set the PYTHON_DLL environment variable.
EXIT /B 1
)
IF NOT EXIST "%PGDIR%" (
ECHO !PGDIR! does not exist.
ECHO Please install PostgreSQL and set the PGDIR environment variable.
EXIT /B 1
)
IF NOT EXIST "%PYTHON_HOME%\Scripts\virtualenv.exe" (
ECHO !PYTHON_HOME!\Scripts\virtualenv.exe does not exist.
ECHO Please install the virtualenv package in Python.
EXIT /B 1
)
SET "PATH=%PGDIR%\bin;%PATH%"
EXIT /B 0
SET PATH=%PGDIR%;%PGDIR%\bin;%QTDIR%\..\..\Tools\mingw530_32\bin;%NODEJSDIR%;%YARNDIR%\bin;%PATH%;
GOTO:eof
:CREATE_VIRTUAL_ENV
ECHO Creating Virtual Enviroment...
ECHO Creating virtual environment...
IF NOT EXIST "%PGBUILDPATH%" MKDIR "%PGBUILDPATH%"
REM If we're using VC++, and this is Python 3.6+, we need a hack for PyCrypto
IF "%MAKE%" == "nmake" (
IF %PYTHON_VERSION% GEQ 36 SET CL=-FI"%VCINSTALLDIR%\INCLUDE\stdint.h"
)
CD "%PGBUILDPATH%"
"%PYTHON_HOME%\Scripts\virtualenv.exe" "%VIRTUALENV%"
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
ECHO Activating Virtual Enviroment - %PGBUILDPATH%\%VIRTUALENV%\Scripts\activate...
CALL "%PGBUILDPATH%\%VIRTUALENV%\Scripts\activate"
SET PATH=%PGDIR%\bin;%PATH%
XCOPY /S /I /E /H /Y "%PYTHON_HOME%\DLLs" "%PGBUILDPATH%\%VIRTUALENV%\DLLs" > nul || EXIT /B 1
XCOPY /S /I /E /H /Y "%PYTHON_HOME%\Lib" "%PGBUILDPATH%\%VIRTUALENV%\Lib" > nul || EXIT /B 1
ECHO Activating virtual environment - %PGBUILDPATH%\%VIRTUALENV%...
CALL "%PGBUILDPATH%\%VIRTUALENV%\Scripts\activate" || EXIT /B 1
ECHO Installing dependencies...
pip install -r "%WD%\requirements.txt"
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
pip install sphinx
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
ECHO Virtual Environment created successfully.
CALL pip install -r "%WD%\requirements.txt" || EXIT /B 1
CALL pip install sphinx || EXIT /B 1
ECHO Deactivating Virtual Enviroment - %PGBUILDPATH%\%VIRTUALENV%\Scripts\deactivate...
CALL "%PGBUILDPATH%\%VIRTUALENV%\Scripts\deactivate"
REM If we're using VC++, and this is Python 3.6+, we need to remove the hack
REM above or it will break qmake. Sigh.
IF "%MAKE%" == "nmake" (
IF %PYTHON_VERSION% GEQ 36 SET CL=
)
CD %WD%
GOTO:eof
EXIT /B 0
:CREATE_RUNTIME_ENV
ECHO Compiling source code...
MKDIR "%PGBUILDPATH%\runtime" > nul
MKDIR "%PGBUILDPATH%\runtime"
REM --- Processing WEB ---
CD "%WD%\web"
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
ECHO Installing javascript dependencies...
CALL yarn install || EXIT /B 1
ECHO Install Javascript dependencies
call yarn install
ECHO Bundle all Javascript
call yarn run bundle
ECHO Bundling javascript...
CALL yarn run bundle || EXIT /B 1
REM Remove any cache
RD /Q /S "%WD%\web\pgadmin\static\js\generated\.cache"
ECHO Removing webpack caches...
RD /Q /S "%WD%\web\pgadmin\static\js\generated\.cache" 1> nul 2>&1
XCOPY /S /I /E /H /Y "%WD%\web" "%PGBUILDPATH%\web" > nul
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
ECHO Copying web directory...
XCOPY /S /I /E /H /Y "%WD%\web" "%PGBUILDPATH%\web" > nul || EXIT /B 1
REM Clean up .pyc, .pyo, pgadmin4.db, config_local.py
ECHO Cleaning up unnecessary files...
FOR /R "%PGBUILDPATH%\web" %%f in (*.pyc *.pyo) do DEL /q "%%f"
FOR /R "%PGBUILDPATH%\web" %%f in (tests feature_tests __pycache__ node_modules) do RD /Q /S "%%f"
RD /Q /S "%PGBUILDPATH%\web\regression"
RD /Q /S "%PGBUILDPATH%\web\tools"
DEL /q "%PGBUILDPATH%\web\pgadmin4.db"
DEL /q "%PGBUILDPATH%\web\config_local.py"
ECHO Cleaning up unnecessary .pyc and .pyo files...
FOR /R "%PGBUILDPATH%\web" %%f in (*.pyc *.pyo) do DEL /q "%%f" 1> nul 2>&1
ECHO Removing tests, Python caches and node modules...
FOR /R "%PGBUILDPATH%\web" %%f in (tests feature_tests __pycache__ node_modules) do RD /Q /S "%%f" 1> nul 2>&1
ECHO Removing the test framework...
RD /Q /S "%PGBUILDPATH%\web\regression" 1> nul 2>&1
ECHO Removing tools...
RD /Q /S "%PGBUILDPATH%\web\tools" 1> nul 2>&1
ECHO Removing any existing configurations...
DEL /q "%PGBUILDPATH%\web\pgadmin4.db" 1> nul 2>&1
DEL /q "%PGBUILDPATH%\web\config_local.py" 1> nul 2>&1
ECHO Creating config_distro.py
ECHO SERVER_MODE = False > "%PGBUILDPATH%\web\config_distro.py"
@@ -197,261 +246,154 @@ REM Main function Ends
ECHO 'ppas': '' >> "%PGBUILDPATH%\web\config_distro.py"
ECHO } >> "%PGBUILDPATH%\web\config_distro.py"
ECHO Activating Virtual Enviroment - %PGBUILDPATH%\%VIRTUALENV%\Scripts\activate...
CALL "%PGBUILDPATH%\%VIRTUALENV%\Scripts\activate"
ECHO Building docs...
MKDIR "%PGBUILDPATH%\docs\en_US\html"
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
CD "%WD%\docs\en_US"
"%PGBUILDPATH%\%VIRTUALENV%\Scripts\python.exe" build_code_snippet.py
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
"%PGBUILDPATH%\%VIRTUALENV%\Scripts\sphinx-build.exe" "%WD%\docs\en_US" "%PGBUILDPATH%\docs\en_US\html"
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
CALL "%PGBUILDPATH%\%VIRTUALENV%\Scripts\python.exe" build_code_snippet.py || EXIT /B 1
CALL "%PGBUILDPATH%\%VIRTUALENV%\Scripts\sphinx-build.exe" "%WD%\docs\en_US" "%PGBUILDPATH%\docs\en_US\html" || EXIT /B 1
ECHO Removing Sphinx
pip uninstall -y sphinx Pygments alabaster colorama docutils imagesize requests snowballstemmer
CALL pip uninstall -y sphinx Pygments alabaster colorama docutils imagesize requests snowballstemmer
ECHO Fixing backports.csv - adding missing __init__.py
type nul >> "%PGBUILDPATH%\%VIRTUALENV%\Lib\site-packages\backports\__init__.py"
IF %PYTHON_MAJOR% == 2 (
ECHO Fixing backports.csv for Python 2 by adding missing __init__.py
type nul >> "%PGBUILDPATH%\%VIRTUALENV%\Lib\site-packages\backports\__init__.py"
)
IF %PYTHON_MAJOR% == 3 (
ECHO Fixing PyCrypto module for Python 3...
CALL "%PYTHON_HOME%\python" "%WD%\pkg\win32\replace.py" "-i" "%PGBUILDPATH%\%VIRTUALENV%\Lib\site-packages\Crypto\Random\OSRNG\nt.py" "-o" "%PGBUILDPATH%\%VIRTUALENV%\Lib\site-packages\Crypto\Random\OSRNG\nt.py.new" "-s" "import winrandom" -r "from . import winrandom"
MOVE /Y "%PGBUILDPATH%\%VIRTUALENV%\Lib\site-packages\Crypto\Random\OSRNG\nt.py.new" "%PGBUILDPATH%\%VIRTUALENV%\Lib\site-packages\Crypto\Random\OSRNG\nt.py"
)
ECHO Assembling runtime environment...
CD "%WD%\runtime"
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
CALL "%QMAKE%" "DEFINES+=PGADMIN4_USE_WEBKIT"
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
ECHO Running qmake...
CALL "%QMAKE%" || EXIT /B 1
CALL mingw32-make.exe clean
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
ECHO Cleaning the build directory...
CALL %MAKE% clean || EXIT /B 1
CALL mingw32-make.exe
IF ERRORLEVEL 1 GOTO ERR_HANDLER
ECHO Running make...
CALL %MAKE% || EXIT /B 1
REM Copy binary to Release Folder
copy "%WD%\runtime\release\pgAdmin4.exe" "%PGBUILDPATH%\runtime"
IF ERRORLEVEL 1 GOTO ERR_HANDLER
REM Copy QT dependences
copy "%QTDIR%\bin\Qt5Core.dll" "%PGBUILDPATH%\runtime"
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
copy "%QTDIR%\bin\Qt5Gui.dll" "%PGBUILDPATH%\runtime"
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
copy "%QTDIR%\bin\Qt5Widgets.dll" "%PGBUILDPATH%\runtime"
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
copy "%QTDIR%\bin\Qt5Network.dll" "%PGBUILDPATH%\runtime"
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
copy "%QTDIR%\bin\libgcc_s_dw2-1.dll" "%PGBUILDPATH%\runtime"
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
copy "%QTDIR%\bin\libstdc++-6.dll" "%PGBUILDPATH%\runtime"
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
copy "%QTDIR%\bin\libwinpthread-1.dll" "%PGBUILDPATH%\runtime"
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
MKDIR "%PGBUILDPATH%\runtime\platforms"
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
copy "%QTDIR%\plugins\platforms\qwindows.dll" "%PGBUILDPATH%\runtime\platforms" > nul
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
ECHO Staging pgAdmin4.exe...
COPY "%WD%\runtime\release\pgAdmin4.exe" "%PGBUILDPATH%\runtime" > nul || EXIT /B 1
ECHO Staging Qt components...
COPY "%QTDIR%\bin\Qt5Core.dll" "%PGBUILDPATH%\runtime" > nul || EXIT /B 1
COPY "%QTDIR%\bin\Qt5Gui.dll" "%PGBUILDPATH%\runtime" > nul || EXIT /B 1
COPY "%QTDIR%\bin\Qt5Widgets.dll" "%PGBUILDPATH%\runtime" > nul || EXIT /B 1
COPY "%QTDIR%\bin\Qt5Network.dll" "%PGBUILDPATH%\runtime" > nul || EXIT /B 1
IF EXIST "%QTDIR%\bin\libgcc_s_dw2-1.dll" COPY "%QTDIR%\bin\libgcc_s_dw2-1.dll" "%PGBUILDPATH%\runtime" > nul || EXIT /B 1
IF EXIST "%QTDIR%\bin\libstdc++-6.dll" COPY "%QTDIR%\bin\libstdc++-6.dll" "%PGBUILDPATH%\runtime" > nul || EXIT /B 1
IF EXIST "%QTDIR%\bin\libwinpthread-1.dll" COPY "%QTDIR%\bin\libwinpthread-1.dll" "%PGBUILDPATH%\runtime" > nul || EXIT /B 1
MKDIR "%PGBUILDPATH%\runtime\platforms" > nul || EXIT /B 1
COPY "%QTDIR%\plugins\platforms\qwindows.dll" "%PGBUILDPATH%\runtime\platforms" > nul || EXIT /B 1
ECHO [Paths] > "%PGBUILDPATH%\runtime\qt.conf"
ECHO Plugins=plugins >> "%PGBUILDPATH%\runtime\qt.conf"
copy "%PGDIR%\bin\libpq.dll" "%PGBUILDPATH%\runtime"
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
copy "%PGDIR%\bin\ssleay32.dll" "%PGBUILDPATH%\runtime"
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
copy "%PGDIR%\bin\libeay32.dll" "%PGBUILDPATH%\runtime"
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
copy "%PGDIR%\bin\libintl-*.dll" "%PGBUILDPATH%\runtime"
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
copy "%PGDIR%\bin\libiconv-*.dll" "%PGBUILDPATH%\runtime"
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
copy "%PGDIR%\bin\zlib1.dll" "%PGBUILDPATH%\runtime"
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
copy "%PGDIR%\bin\pg_dump.exe" "%PGBUILDPATH%\runtime"
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
copy "%PGDIR%\bin\pg_dumpall.exe" "%PGBUILDPATH%\runtime"
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
copy "%PGDIR%\bin\pg_restore.exe" "%PGBUILDPATH%\runtime"
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
copy "%PGDIR%\bin\psql.exe" "%PGBUILDPATH%\runtime"
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
ECHO Staging PostgreSQL components...
COPY "%PGDIR%\bin\libpq.dll" "%PGBUILDPATH%\runtime" > nul || EXIT /B 1
COPY "%PGDIR%\bin\ssleay32.dll" "%PGBUILDPATH%\runtime" > nul || EXIT /B 1
COPY "%PGDIR%\bin\libeay32.dll" "%PGBUILDPATH%\runtime" > nul || EXIT /B 1
IF EXIST "%PGDIR%\bin\libintl-*.dll" COPY "%PGDIR%\bin\libintl-*.dll" "%PGBUILDPATH%\runtime" > nul || EXIT /B 1
IF EXIST "%PGDIR%\bin\libiconv-*.dll" COPY "%PGDIR%\bin\libiconv-*.dll" "%PGBUILDPATH%\runtime" > nul || EXIT /B 1
IF EXIST "%PGDIR%\bin\zlib.dll" COPY "%PGDIR%\bin\zlib.dll" "%PGBUILDPATH%\runtime" > nul || EXIT /B 1
IF EXIST "%PGDIR%\bin\zlib1.dll" COPY "%PGDIR%\bin\zlib1.dll" "%PGBUILDPATH%\runtime" > nul || EXIT /B 1
COPY "%PGDIR%\bin\pg_dump.exe" "%PGBUILDPATH%\runtime" > nul || EXIT /B 1
COPY "%PGDIR%\bin\pg_dumpall.exe" "%PGBUILDPATH%\runtime" > nul || EXIT /B 1L%
COPY "%PGDIR%\bin\pg_restore.exe" "%PGBUILDPATH%\runtime" > nul || EXIT /B 1
COPY "%PGDIR%\bin\psql.exe" "%PGBUILDPATH%\runtime" > nul || EXIT /B 1
MKDIR "%PGBUILDPATH%\installer"
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
copy "%VCREDIST%" "%PGBUILDPATH%\installer" > nul
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
ECHO Runtime built successfully.
ECHO Staging VC++ runtime...
MKDIR "%PGBUILDPATH%\installer" || EXIT /B 1
COPY "%VCREDIST%" "%PGBUILDPATH%\installer" > nul || EXIT /B 1
CD %WD%
GOTO:eof
EXIT /B 0
:CREATE_PYTHON_ENV
copy %PYTHON_DLL% "%PGBUILDPATH%\runtime" > nul
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
ECHO Staging Python...
COPY %PYTHON_DLL% "%PGBUILDPATH%\runtime" > nul || EXIT /B 1
COPY %PYTHON_HOME%\python.exe "%PGBUILDPATH%\runtime" > nul || EXIT /B 1
COPY %PYTHON_HOME%\pythonw.exe "%PGBUILDPATH%\runtime" > nul || EXIT /B 1
REM Copy Python interpretor as it's needed to run background processes
copy %PYTHON_HOME%\python.exe "%PGBUILDPATH%\runtime" > nul
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
copy %PYTHON_HOME%\pythonw.exe "%PGBUILDPATH%\runtime" > nul
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
ECHO Cleaning up unnecessary .pyc and .pyo files...
FOR /R "%PGBUILDPATH%\%VIRTUALENV%" %%f in (*.pyc *.pyo) do DEL /q "%%f" 1> nul 2>&1
ECHO Removing tests...
FOR /R "%PGBUILDPATH%\%VIRTUALENV%\Lib" %%f in (test tests) do RD /Q /S "%%f" 1> nul 2>&1
ECHO Removing TCL...
RD /Q /S "%PGBUILDPATH%\%VIRTUALENV%\tcl" 1> nul 2>&1
XCOPY /S /I /E /H /Y "%PYTHON_HOME%\DLLs" "%PGBUILDPATH%\%VIRTUALENV%\DLLs" > nul
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
XCOPY /S /I /E /H /Y "%PYTHON_HOME%\Lib" "%PGBUILDPATH%\%VIRTUALENV%\Lib" > nul
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
EXIT /B 0
ECHO Cleaning up unnecessary files...
FOR /R "%PGBUILDPATH%\%VIRTUALENV%" %%f in (*.pyc *.pyo) do DEL /q "%%f"
FOR /R "%PGBUILDPATH%\%VIRTUALENV%\Lib" %%f in (test tests) do RD /Q /S "%%f"
RD /Q /S "%PGBUILDPATH%\%VIRTUALENV%\tcl"
CD %WD%
GOTO:eof
:CREATE_INSTALLER
ECHO Preparing for creation of windows installer...
IF NOT EXIST "%TARGETINSTALLER%" MKDIR "%TARGETINSTALLER%"
IF NOT EXIST "%TARGET_DIR%" MKDIR "%TARGET_DIR%"
copy "%WD%\pkg\win32\Resources\pgAdmin4.ico" "%PGBUILDPATH%"
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
ECHO Copying icon file...
COPY "%WD%\pkg\win32\Resources\pgAdmin4.ico" "%PGBUILDPATH%" > nul || EXIT /B 1
CD "%WD%"
CD pkg
CD win32
CD "%WD%\pkg\win32"
"%PYTHON_HOME%\python" "%WD%\pkg\win32\replace.py" "-i" "%WD%\pkg\win32\installer.iss.in" "-o" "%WD%\pkg\win32\installer.iss.in_stage1" "-s" MYAPP_NAME -r """%APP_NAME%"""
"%PYTHON_HOME%\python" "%WD%\pkg\win32\replace.py" "-i" "%WD%\pkg\win32\installer.iss.in_stage1" "-o" "%WD%\pkg\win32\installer.iss.in_stage2" "-s" MYAPP_FULLVERSION -r """%PGADMIN4_APP_VERSION%"""
"%PYTHON_HOME%\python" "%WD%\pkg\win32\replace.py" "-i" "%WD%\pkg\win32\installer.iss.in_stage2" "-o" "%WD%\pkg\win32\installer.iss.in_stage3" "-s" MYAPP_VERSION -r """%PGADMIN4_VERSION%"""
ECHO Processing installer configuration script...
CALL "%PYTHON_HOME%\python" "%WD%\pkg\win32\replace.py" "-i" "%WD%\pkg\win32\installer.iss.in" "-o" "%WD%\pkg\win32\installer.iss.in_stage1" "-s" MYAPP_NAME -r """%APP_NAME%"""
CALL "%PYTHON_HOME%\python" "%WD%\pkg\win32\replace.py" "-i" "%WD%\pkg\win32\installer.iss.in_stage1" "-o" "%WD%\pkg\win32\installer.iss.in_stage2" "-s" MYAPP_FULLVERSION -r """%APP_VERSION%"""
CALL "%PYTHON_HOME%\python" "%WD%\pkg\win32\replace.py" "-i" "%WD%\pkg\win32\installer.iss.in_stage2" "-o" "%WD%\pkg\win32\installer.iss.in_stage3" "-s" MYAPP_VERSION -r """v%APP_MAJOR%"""
set ARCMODE=
SET ARCMODE=
IF "%ARCHITECTURE%"=="amd64" (
set ARCMODE="x64"
)
"%PYTHON_HOME%\python" "%WD%\pkg\win32\replace.py" "-i" "%WD%\pkg\win32\installer.iss.in_stage3" "-o" "%WD%\pkg\win32\installer.iss.in_stage4" "-s" MYAPP_ARCHITECTURESMODE -r """%ARCMODE%"""
"%PYTHON_HOME%\python" "%WD%\pkg\win32\replace.py" "-i" "%WD%\pkg\win32\installer.iss.in_stage4" "-o" "%WD%\pkg\win32\installer.iss" "-s" MYAPP_VCDIST -r """%VCREDISTNAME%"""
CALL "%PYTHON_HOME%\python" "%WD%\pkg\win32\replace.py" "-i" "%WD%\pkg\win32\installer.iss.in_stage3" "-o" "%WD%\pkg\win32\installer.iss.in_stage4" "-s" MYAPP_ARCHITECTURESMODE -r """%ARCMODE%"""
CALL "%PYTHON_HOME%\python" "%WD%\pkg\win32\replace.py" "-i" "%WD%\pkg\win32\installer.iss.in_stage4" "-o" "%WD%\pkg\win32\installer.iss" "-s" MYAPP_VCDIST -r """%VCREDISTNAME%"""
ECHO Cleaning up...
DEL /s "%WD%\pkg\win32\installer.iss.in_stage*" > nul
ECHO Creating windows installer... using INNO tool
CALL "%INNOTOOL%\ISCC.exe" /q "%WD%\pkg\win32\installer.iss"
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
ECHO Creating windows installer using INNO tool...
CALL "%INNOTOOL%\ISCC.exe" /q "%WD%\pkg\win32\installer.iss" || EXIT /B 1
MOVE "%WD%\pkg\win32\Output\Setup.exe" "%TARGETINSTALLER%\%INSTALLERNAME%"
IF %ERRORLEVEL% NEQ 0 EXIT /B %ERRORLEVEL%
ECHO Renaming installer...
MOVE "%WD%\pkg\win32\Output\Setup.exe" "%TARGET_DIR%\%INSTALLERNAME%" > nul || EXIT /B 1
ECHO "Location - %TARGETINSTALLER%\%INSTALLERNAME%"
ECHO Location - %TARGET_DIR%\%INSTALLERNAME%
ECHO Installer generated successfully.
CD %WD%
GOTO:eof
EXIT /B 0
:SIGN_INSTALLER
ECHO Attempting to sign the installer...
"%SIGNTOOL%" sign /t http://timestamp.verisign.com/scripts/timstamp.dll "%TARGETINSTALLER%\%INSTALLERNAME%"
CALL "%SIGNTOOL%" sign /t http://timestamp.verisign.com/scripts/timstamp.dll "%TARGET_DIR%\%INSTALLERNAME%"
IF %ERRORLEVEL% NEQ 0 (
ECHO
ECHO.
ECHO ************************************************************
ECHO * Failed to sign the installer
ECHO ************************************************************
PAUSE
)
CD %WD%
GOTO:eof
EXIT /B 0
:CLEANUP_ENV
ECHO Cleaning up private environment...
rd "%PGBUILDPATH%\%VIRTUALENV%\Include" /S /Q
DEL /s "%PGBUILDPATH%\%VIRTUALENV%\pip-selfcheck.json"
ECHO Cleaning the build environment...
RD "%PGBUILDPATH%\%VIRTUALENV%\Include" /S /Q 1> nul 2>&1
DEL /s "%PGBUILDPATH%\%VIRTUALENV%\pip-selfcheck.json" 1> nul 2>&1
ECHO Cleaned up private environment successfully.
CD %WD%
GOTO:eof
EXIT /B 0
:err_handle_inno
ECHO %INNOTOOL% does not exist
ECHO Please Install Innotool and SET INNOTOOL enviroment Variable.
ECHO SET "INNOTOOL=<PATH>"
exit /B 1
GOTO EXIT
:err_handle_visualstudio
ECHO %VCDIR% does not exist
ECHO Please Install Microsoft Visual studio and SET the VCDIR enviroment Variable.
ECHO SET "VCDIR=<PATH>"
exit /B 1
GOTO EXIT
:err_handle_visualstudio_dist
ECHO %VCREDIST% does not exist
ECHO Please Install Microsoft Visual studio and SET the VCDIST enviroment Variable.
ECHO SET "VCDIST=<PATH>"
exit /B 1
GOTO EXIT
:err_handle_python
ECHO %PYTHON_HOME% does not exist, or
ECHO PYTHON_VERSION is not SET, or
ECHO %PYTHON_DLL% does not exist.
ECHO Please install Python and SET the PYTHON_HOME enviroment Variable.
ECHO SET "PYTHON_VERSION=<VERSION NUMBER>"
ECHO SET "PYTHON_HOME=<PATH>"
ECHO SET "PYTHON_DLL=<PATH>"
exit /B 1
GOTO EXIT
:err_handle_qt
ECHO %QTDIR% does not exist.
ECHO Please Install QT SDK and SET the QTDIR enviroment variable.
ECHO SET "QTDIR=<PATH>"
exit /B 1
GOTO EXIT
:err_handle_yarn
ECHO %YARNDIR% does not exist.
ECHO Please Install YARN and SET the YARNDIR enviroment variable.
ECHO SET "YARNDIR=<YARN PATH>"
exit /B 1
GOTO EXIT
:err_handle_nodejs
ECHO %NODEJSDIR% does not exist.
ECHO Please Install NodeJs and SET the NODEJSDIR enviroment variable.
ECHO SET "NODEJSDIR=<NODEJS PATH>"
exit /B 1
GOTO EXIT
:err_handle_pg
ECHO %PGDIR% does not exist.
ECHO Please Install Postgres and SET enviroment Variable
ECHO SET "PGDIR=<PATH>"
exit /B 1
GOTO EXIT
:err_handle_pythonvirtualenv
ECHO Python virtualenv is missing @ location - %PYTHON_HOME%\Scripts\virtualenv.exe
exit /B 1
GOTO EXIT
:ERR_HANDLER
ECHO.
ECHO Aborting build!
CD %WD%
exit /B 1
GOTO EXIT
:USAGE
ECHO Invalid command line options....
ECHO Invalid command line options.
ECHO Usage: "Make.bat <x86 | clean>"
ECHO.
exit /B 1
GOTO EXIT
:EXIT
EXIT /B 1
+6
View File
@@ -54,6 +54,10 @@ runtime:
# Include all clean sub-targets in clean
clean: clean-appbundle clean-docker clean-dist clean-docs clean-node clean-pip clean-src clean-runtime
rm -rf web/pgadmin/static/js/generated/*
rm -rf web/pgadmin/static/js/generated/.cache
rm -rf web/pgadmin/static/css/generated/*
rm -rf web/pgadmin/static/css/generated/.cache
clean-runtime:
cd runtime && make clean
@@ -88,6 +92,8 @@ docs:
docs-pdf:
LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 $(MAKE) -C docs/en_US -f Makefile.sphinx latexpdf
messages: msg-extract msg-update msg-compile
msg-compile:
cd web && pybabel compile --statistics -d pgadmin/translations
+1
View File
@@ -80,6 +80,7 @@ Create a migration file with the following command:
This will create a file in: $PGADMIN4_SRC/web/migrations/versions/ .
Add any changes to the 'upgrade' function.
Increment the SCHEMA_VERSION in $PGADMIN4_SRC/web/pgadmin/model/__init__.py file.
There is no need to increment the SETTINGS_SCHEMA_VERSION.
+4 -4
View File
@@ -3,15 +3,15 @@
echo "EXECUTING: Build docs"
echo
cd $WORKSPACE
cd ${WORKSPACE}
. $WORKSPACE/pgadmin-venv/bin/activate
. ${WORKSPACE}/pgadmin-venv/bin/activate
SPHINX_VER=""
if [ "$PYTHON_VERSION" = "2.6" -o "$PYTHON_VERSION" = "3.3" ]; then
if [ "${PYTHON_VERSION}" = "2.6" -o "${PYTHON_VERSION}" = "3.3" ]; then
SPHINX_VER="==1.4.9"
fi
$WORKSPACE/pgadmin-venv/bin/pip install Sphinx$SPHINX_VER || { echo 'ERROR: Failed to install Sphinx to build the docs.' ; exit 1; }
${WORKSPACE}/pgadmin-venv/bin/pip install Sphinx${SPHINX_VER} || { echo 'ERROR: Failed to install Sphinx to build the docs.' ; exit 1; }
make docs || { echo 'ERROR: Failed to build the documentation.' ; exit 1; }
+4 -4
View File
@@ -3,15 +3,15 @@
echo "EXECUTING: Build PIP wheel"
echo
cd $WORKSPACE
cd ${WORKSPACE}
. $WORKSPACE/pgadmin-venv/bin/activate
. ${WORKSPACE}/pgadmin-venv/bin/activate
SPHINX_VER=""
if [ "$PYTHON_VERSION" = "2.6" -o "$PYTHON_VERSION" = "3.3" ]; then
if [ "${PYTHON_VERSION}" = "2.6" -o "${PYTHON_VERSION}" = "3.3" ]; then
SPHINX_VER="==1.4.9"
fi
$WORKSPACE/pgadmin-venv/bin/pip install Sphinx$SPHINX_VER || { echo 'ERROR: Failed to install Sphinx to build the PIP wheel.' ; exit 1; }
${WORKSPACE}/pgadmin-venv/bin/pip install Sphinx${SPHINX_VER} || { echo 'ERROR: Failed to install Sphinx to build the PIP wheel.' ; exit 1; }
make pip || { echo 'ERROR: Failed to build the PIP wheel.' ; exit 1; }
+4 -4
View File
@@ -4,13 +4,13 @@ echo "EXECUTING: Build runtime - QT4"
echo
if [ ${PYTHON_VERSION:0:1} == "3" ]; then
CONFIG=/usr/local/python-$PYTHON_VERSION/bin/python3-config
CONFIG=/usr/local/python-${PYTHON_VERSION}/bin/python3-config
else
CONFIG=/usr/local/python-$PYTHON_VERSION/bin/python-config
CONFIG=/usr/local/python-${PYTHON_VERSION}/bin/python-config
fi
cd $WORKSPACE/runtime
cd ${WORKSPACE}/runtime
make clean
PATH=/usr/local/python-$PYTHON_VERSION/bin:$PATH PYTHON_CONFIG=$CONFIG /bin/qmake-qt4 || { echo 'ERROR: Failed to run the QT4 qmake step.' ; exit 1; }
PATH=/usr/local/python-${PYTHON_VERSION}/bin:$PATH PYTHON_CONFIG=${CONFIG} /bin/qmake-qt4 || { echo 'ERROR: Failed to run the QT4 qmake step.' ; exit 1; }
make all || { echo 'ERROR: Failed to build the QT4 runtime.' ; exit 1; }
+4 -4
View File
@@ -4,13 +4,13 @@ echo "EXECUTING: Build runtime - QT5"
echo
if [ ${PYTHON_VERSION:0:1} == "3" ]; then
CONFIG=/usr/local/python-$PYTHON_VERSION/bin/python3-config
CONFIG=/usr/local/python-${PYTHON_VERSION}/bin/python3-config
else
CONFIG=/usr/local/python-$PYTHON_VERSION/bin/python-config
CONFIG=/usr/local/python-${PYTHON_VERSION}/bin/python-config
fi
cd $WORKSPACE/runtime
cd ${WORKSPACE}/runtime
make clean
PATH=/usr/local/python-$PYTHON_VERSION/bin:$PATH PYTHON_CONFIG=$CONFIG /bin/qmake-qt5 DEFINES+=PGADMIN4_USE_WEBKIT || { echo 'ERROR: Failed to run the QT5 qmake step.' ; exit 1; }
PATH=/usr/local/python-${PYTHON_VERSION}/bin:$PATH PYTHON_CONFIG=${CONFIG} /bin/qmake-qt5 DEFINES+=PGADMIN4_USE_WEBKIT || { echo 'ERROR: Failed to run the QT5 qmake step.' ; exit 1; }
make all || { echo 'ERROR: Failed to build the QT4 runtime.' ; exit 1; }
+5 -5
View File
@@ -3,15 +3,15 @@
echo "EXECUTING: Build Tarballs"
echo
cd $WORKSPACE
cd ${WORKSPACE}
. $WORKSPACE/pgadmin-venv/bin/activate
. ${WORKSPACE}/pgadmin-venv/bin/activate
SPHINX_VER=""
if [ "$PYTHON_VERSION" = "2.6" -o "$PYTHON_VERSION" = "3.3" ]; then
if [ "${PYTHON_VERSION}" = "2.6" -o "${PYTHON_VERSION}" = "3.3" ]; then
SPHINX_VER="==1.4.9"
fi
$WORKSPACE/pgadmin-venv/bin/pip install Sphinx$SPHINX_VER || { echo 'ERROR: Failed to install Sphinx to build the tarballs.' ; exit 1; }
cd $WORKSPACE/
${WORKSPACE}/pgadmin-venv/bin/pip install Sphinx${SPHINX_VER} || { echo 'ERROR: Failed to install Sphinx to build the tarballs.' ; exit 1; }
cd ${WORKSPACE}/
make src || { echo 'ERROR: Failed to build the tarballs.' ; exit 1; }
+9 -9
View File
@@ -1,11 +1,11 @@
#!/bin/sh
$WORKSPACE/ci/create_config.sh || { echo 'ERROR: Failed to create the configuration.' ; exit 1; }
$WORKSPACE/ci/run_python_tests.sh || { echo 'ERROR: Error detected when running the Python tests.' ; exit 1; }
$WORKSPACE/ci/run_jasmine_tests.sh || { echo 'ERROR: Error detected when running the Jasmine tests.' ; exit 1; }
$WORKSPACE/ci/build_docs.sh || { echo 'ERROR: Failed to build the documentation.' ; exit 1; }
$WORKSPACE/ci/build_runtime_qt4.sh || { echo 'ERROR: Failed to build the QT4 runtime.' ; exit 1; }
$WORKSPACE/ci/build_runtime_qt5.sh || { echo 'ERROR: Failed to build the QT5 runtime.' ; exit 1; }
$WORKSPACE/ci/update_messages.sh || { echo 'ERROR: Failed to update translation message catalogs.' ; exit 1; }
$WORKSPACE/ci/build_pip_wheel.sh || { echo 'ERROR: Failed to build the PIP wheel.' ; exit 1; }
$WORKSPACE/ci/build_tarballs.sh || { echo 'ERROR: Failed to build the tarballs.' ; exit 1; }
${WORKSPACE}/ci/create_config.sh || { echo 'ERROR: Failed to create the configuration.' ; exit 1; }
${WORKSPACE}/ci/run_python_tests.sh || { echo 'ERROR: Error detected when running the Python tests.' ; exit 1; }
${WORKSPACE}/ci/run_jasmine_tests.sh || { echo 'ERROR: Error detected when running the Jasmine tests.' ; exit 1; }
${WORKSPACE}/ci/build_docs.sh || { echo 'ERROR: Failed to build the documentation.' ; exit 1; }
${WORKSPACE}/ci/build_runtime_qt4.sh || { echo 'ERROR: Failed to build the QT4 runtime.' ; exit 1; }
${WORKSPACE}/ci/build_runtime_qt5.sh || { echo 'ERROR: Failed to build the QT5 runtime.' ; exit 1; }
${WORKSPACE}/ci/update_messages.sh || { echo 'ERROR: Failed to update translation message catalogs.' ; exit 1; }
${WORKSPACE}/ci/build_pip_wheel.sh || { echo 'ERROR: Failed to build the PIP wheel.' ; exit 1; }
${WORKSPACE}/ci/build_tarballs.sh || { echo 'ERROR: Failed to build the tarballs.' ; exit 1; }
+8 -8
View File
@@ -3,13 +3,13 @@
echo "EXECUTING: Create pgAdmin config"
echo
cd $WORKSPACE
cd ${WORKSPACE}
cp $JENKINS_HOME/pgadmin-configs/config_local.py $WORKSPACE/web/config_local.py || { echo 'ERROR: Failed to create config_local.py.' ; exit 1; }
echo LOG_FILE = \"$WORKSPACE/var/pgadmin4.log\" >> $WORKSPACE/web/config_local.py || { echo 'ERROR: Failed to create config_local.py.' ; exit 1; }
echo SESSION_DB_PATH = \"$WORKSPACE/var/sessions\" >> $WORKSPACE/web/config_local.py || { echo 'ERROR: Failed to create config_local.py.' ; exit 1; }
echo STORAGE_DIR = \"$WORKSPACE/var/storage\" >> $WORKSPACE/web/config_local.py || { echo 'ERROR: Failed to create config_local.py.' ; exit 1; }
echo SQLITE_PATH = \"$WORKSPACE/var/pgadmin4.db\" >> $WORKSPACE/web/config_local.py || { echo 'ERROR: Failed to create config_local.py.' ; exit 1; }
echo TEST_SQLITE_PATH = \"$WORKSPACE/var/pgadmin4.db\" >> $WORKSPACE/web/config_local.py || { echo 'ERROR: Failed to create config_local.py.' ; exit 1; }
cp ${JENKINS_HOME}/pgadmin-configs/config_local.py ${WORKSPACE}/web/config_local.py || { echo 'ERROR: Failed to create config_local.py.' ; exit 1; }
echo LOG_FILE = \"${WORKSPACE}/var/pgadmin4.log\" >> ${WORKSPACE}/web/config_local.py || { echo 'ERROR: Failed to create config_local.py.' ; exit 1; }
echo SESSION_DB_PATH = \"${WORKSPACE}/var/sessions\" >> ${WORKSPACE}/web/config_local.py || { echo 'ERROR: Failed to create config_local.py.' ; exit 1; }
echo STORAGE_DIR = \"${WORKSPACE}/var/storage\" >> ${WORKSPACE}/web/config_local.py || { echo 'ERROR: Failed to create config_local.py.' ; exit 1; }
echo SQLITE_PATH = \"${WORKSPACE}/var/pgadmin4.db\" >> ${WORKSPACE}/web/config_local.py || { echo 'ERROR: Failed to create config_local.py.' ; exit 1; }
echo TEST_SQLITE_PATH = \"${WORKSPACE}/var/pgadmin4.db\" >> ${WORKSPACE}/web/config_local.py || { echo 'ERROR: Failed to create config_local.py.' ; exit 1; }
cp $JENKINS_HOME/pgadmin-configs/test_config.json $WORKSPACE/web/regression/test_config.json || { echo 'ERROR: Failed to copy the test configuration.' ; exit 1; }
cp ${JENKINS_HOME}/pgadmin-configs/test_config.json ${WORKSPACE}/web/regression/test_config.json || { echo 'ERROR: Failed to copy the test configuration.' ; exit 1; }
+12 -12
View File
@@ -13,25 +13,25 @@ export DISPLAY=:99
echo "Creating Python ${PYTHON_VERSION} virtual environment..."
echo
cd $WORKSPACE/
cd ${WORKSPACE}/
PYTHON_SUFFIX=""
if [[ "$PYTHON_VERSION" == 3* ]]; then
if [[ "${PYTHON_VERSION}" == 3* ]]; then
PYTHON_SUFFIX="3"
fi
if [ "$PYTHON_VERSION" == 2.6 -o "$PYTHON_VERSION" == 3.3 ]; then
/usr/bin/virtualenv --no-wheel -p /usr/local/python-$PYTHON_VERSION/bin/python$PYTHON_SUFFIX $WORKSPACE/pgadmin-venv || { echo 'ERROR: Failed to create the Python virtual environment.' ; exit 1; }
. $WORKSPACE/pgadmin-venv/bin/activate || { echo 'ERROR: Failed to activate the Python virtual environment.' ; exit 1; }
$WORKSPACE/pgadmin-venv/bin/pip install wheel==0.29.0 || { echo 'ERROR: Failed to install wheel 0.29.0.' ; exit 1; }
if [ "${PYTHON_VERSION}" == 2.6 -o "${PYTHON_VERSION}" == 3.3 ]; then
/usr/bin/virtualenv --no-wheel -p /usr/local/python-${PYTHON_VERSION}/bin/python${PYTHON_SUFFIX} ${WORKSPACE}/pgadmin-venv || { echo 'ERROR: Failed to create the Python virtual environment.' ; exit 1; }
. ${WORKSPACE}/pgadmin-venv/bin/activate || { echo 'ERROR: Failed to activate the Python virtual environment.' ; exit 1; }
${WORKSPACE}/pgadmin-venv/bin/pip install wheel==0.29.0 || { echo 'ERROR: Failed to install wheel 0.29.0.' ; exit 1; }
else
/usr/bin/virtualenv -p /usr/local/python-$PYTHON_VERSION/bin/python$PYTHON_SUFFIX $WORKSPACE/pgadmin-venv || { echo 'ERROR: Failed to create the Python virtual environment.' ; exit 1; }
. $WORKSPACE/pgadmin-venv/bin/activate || { echo 'ERROR: Failed to activate the Python virtual environment.' ; exit 1; }
/usr/bin/virtualenv -p /usr/local/python-${PYTHON_VERSION}/bin/python${PYTHON_SUFFIX} ${WORKSPACE}/pgadmin-venv || { echo 'ERROR: Failed to create the Python virtual environment.' ; exit 1; }
. ${WORKSPACE}/pgadmin-venv/bin/activate || { echo 'ERROR: Failed to activate the Python virtual environment.' ; exit 1; }
fi
$WORKSPACE/pgadmin-venv/bin/pip install -r requirements.txt || { echo 'ERROR: Failed to install the application requirements.' ; exit 1; }
$WORKSPACE/pgadmin-venv/bin/pip install -r web/regression/requirements.txt || { echo 'ERROR: Failed to install the regression test requirements.' ; exit 1; }
${WORKSPACE}/pgadmin-venv/bin/pip install -r requirements.txt || { echo 'ERROR: Failed to install the application requirements.' ; exit 1; }
${WORKSPACE}/pgadmin-venv/bin/pip install -r web/regression/requirements.txt || { echo 'ERROR: Failed to install the regression test requirements.' ; exit 1; }
cd web
/usr/bin/yarn install || { echo 'ERROR: Failed to install the required Javascript modules.' ; exit 1; }
@@ -41,9 +41,9 @@ cd ../
echo "Running regression tests..."
echo
$WORKSPACE/pgadmin-venv/bin/python $WORKSPACE/web/regression/runtests.py --pkg feature_tests || { echo 'ERROR: Error detected when running the Feature tests.' ; exit 1; }
${WORKSPACE}/pgadmin-venv/bin/python ${WORKSPACE}/web/regression/runtests.py --pkg feature_tests || { echo 'ERROR: Error detected when running the Feature tests.' ; exit 1; }
echo "Cleaning up..."
echo
kill $FB_PID
kill ${FB_PID}
+1 -1
View File
@@ -3,7 +3,7 @@
echo "EXECUTING: Jasmine tests"
echo
cd $WORKSPACE/web/
cd ${WORKSPACE}/web/
/usr/bin/yarn install || { echo 'ERROR: Failed to install the required Javascript modules.' ; exit 1; }
/usr/bin/yarn run linter || { echo 'ERROR: Failed to lint the Javascript code.' ; exit 1; }
+11 -11
View File
@@ -6,25 +6,25 @@ echo
echo "Creating Python ${PYTHON_VERSION} virtual environment..."
echo
cd $WORKSPACE/
cd ${WORKSPACE}/
PYTHON_SUFFIX=""
if [[ "$PYTHON_VERSION" == 3* ]]; then
if [[ "${PYTHON_VERSION}" == 3* ]]; then
PYTHON_SUFFIX="3"
fi
if [ "$PYTHON_VERSION" == 2.6 -o "$PYTHON_VERSION" == 3.3 ]; then
/usr/bin/virtualenv --no-wheel -p /usr/local/python-$PYTHON_VERSION/bin/python$PYTHON_SUFFIX $WORKSPACE/pgadmin-venv || { echo 'ERROR: Failed to create the Python virtual environment.' ; exit 1; }
. $WORKSPACE/pgadmin-venv/bin/activate || { echo 'ERROR: Failed to activate the Python virtual environment.' ; exit 1; }
$WORKSPACE/pgadmin-venv/bin/pip install wheel==0.29.0 || { echo 'ERROR: Failed to install wheel 0.29.0.' ; exit 1; }
if [ "${PYTHON_VERSION}" == 2.6 -o "${PYTHON_VERSION}" == 3.3 ]; then
/usr/bin/virtualenv --no-wheel -p /usr/local/python-${PYTHON_VERSION}/bin/python${PYTHON_SUFFIX} ${WORKSPACE}/pgadmin-venv || { echo 'ERROR: Failed to create the Python virtual environment.' ; exit 1; }
. ${WORKSPACE}/pgadmin-venv/bin/activate || { echo 'ERROR: Failed to activate the Python virtual environment.' ; exit 1; }
${WORKSPACE}/pgadmin-venv/bin/pip install wheel==0.29.0 || { echo 'ERROR: Failed to install wheel 0.29.0.' ; exit 1; }
else
/usr/bin/virtualenv -p /usr/local/python-$PYTHON_VERSION/bin/python$PYTHON_SUFFIX $WORKSPACE/pgadmin-venv || { echo 'ERROR: Failed to create the Python virtual environment.' ; exit 1; }
. $WORKSPACE/pgadmin-venv/bin/activate || { echo 'ERROR: Failed to activate the Python virtual environment.' ; exit 1; }
/usr/bin/virtualenv -p /usr/local/python-${PYTHON_VERSION}/bin/python${PYTHON_SUFFIX} ${WORKSPACE}/pgadmin-venv || { echo 'ERROR: Failed to create the Python virtual environment.' ; exit 1; }
. ${WORKSPACE}/pgadmin-venv/bin/activate || { echo 'ERROR: Failed to activate the Python virtual environment.' ; exit 1; }
fi
$WORKSPACE/pgadmin-venv/bin/pip install -r requirements.txt || { echo 'ERROR: Failed to install the application requirements.' ; exit 1; }
$WORKSPACE/pgadmin-venv/bin/pip install -r web/regression/requirements.txt || { echo 'ERROR: Failed to install the regression test requirements.' ; exit 1; }
${WORKSPACE}/pgadmin-venv/bin/pip install -r requirements.txt || { echo 'ERROR: Failed to install the application requirements.' ; exit 1; }
${WORKSPACE}/pgadmin-venv/bin/pip install -r web/regression/requirements.txt || { echo 'ERROR: Failed to install the regression test requirements.' ; exit 1; }
echo "Running PEP-8 checks..."
echo
@@ -34,5 +34,5 @@ make check-pep8 || { echo 'ERROR: Error detected when running the Python PEP-8 c
echo "Running regression tests..."
echo
$WORKSPACE/pgadmin-venv/bin/python $WORKSPACE/web/regression/runtests.py --exclude feature_tests || { echo 'ERROR: Error detected when running the Python tests.' ; exit 1; }
${WORKSPACE}/pgadmin-venv/bin/python ${WORKSPACE}/web/regression/runtests.py --exclude feature_tests || { echo 'ERROR: Error detected when running the Python tests.' ; exit 1; }
+2 -2
View File
@@ -3,9 +3,9 @@
echo "EXECUTING: Compile messages"
echo
cd $WORKSPACE/web
cd ${WORKSPACE}/web
. $WORKSPACE/pgadmin-venv/bin/activate || { echo 'ERROR: Failed to activate the Python virtual environment.' ; exit 1; }
. ${WORKSPACE}/pgadmin-venv/bin/activate || { echo 'ERROR: Failed to activate the Python virtual environment.' ; exit 1; }
pybabel extract -F babel.cfg -o pgadmin/messages.pot pgadmin || { echo 'ERROR: Failed to extract messages from the source code.' ; exit 1; }
+3 -3
View File
@@ -1,8 +1,8 @@
.. _add_restore_point_dialog:
**********************************
The Add named restore point Dialog
**********************************
***************************************
`Add named restore point Dialog`:index:
***************************************
Use the *Add named restore point* dialog to take a named snapshot of the state of the server for use in a recovery file. To create a named restore point, the server's postgresql.conf file must specify a *wal_level* value of *archive*, *hot_standby*, or *logical*. You must be a database superuser to create a restore point.
+3 -3
View File
@@ -1,8 +1,8 @@
.. _backup_and_restore:
******************
Backup and Restore
******************
***************************
`Backup and Restore`:index:
***************************
A powerful, but user-friendly Backup and Restore tool provides an easy way to use pg_dump, pg_dumpall, and pg_restore to take backups and create copies of databases or database objects for use in a development environment.
+11 -7
View File
@@ -1,8 +1,8 @@
.. _backup_dialog:
*****************
The Backup Dialog
*****************
**********************
`Backup Dialog`:index:
**********************
Using the *pg_dump* utility, *pgAdmin* provides an easy way to create a backup in a plain-text or archived format. You can then use a client application (like *psql* or the *Query Tool*) to restore a plain-text backup file, or use the Postgres *pg_restore* utility to restore an archived backup. The *pg_dump* utility must have read access to all database objects that you want to back up.
@@ -58,13 +58,15 @@ Click the *Dump options* tab to continue. Use the box fields in the *Dump option
* Move switches in the **Do not save** field box to select the objects that will not be included in the backup.
* Move the switch next to *Owner* to the *Yes* position to include commands that set object ownership.
* Move the switch next to *Owner* to the *Yes* position to exclude commands that set object ownership.
* Move the switch next to *Privilege* to the *Yes* position to include commands that create access privileges.
* Move the switch next to *Privilege* to the *Yes* position to exclude commands that create access privileges.
* Move the switch next to *Tablespace* to the *Yes* position to include tablespaces.
* Move the switch next to *Tablespace* to the *Yes* position to exclude tablespaces.
* Move the switch next to *Unlogged table data* to the *Yes* position to include the contents of unlogged tables.
* Move the switch next to *Unlogged table data* to the *Yes* position to exclude the contents of unlogged tables.
* Move the switch next to *Comments* to the *Yes* position to exclude commands that set the comments. **Note:** This option is visible only for database server greater than or equal to 11.
.. image:: images/backup_queries.png
:alt: Queries option on backup dialog
@@ -79,6 +81,8 @@ Click the *Dump options* tab to continue. Use the box fields in the *Dump option
* Move the switch next to *Include DROP DATABASE statement* to the *Yes* position to include a command in the backup that will drop any existing database object with the same name before recreating the object during a backup.
* Move the switch next to *Load Via Partition Root* to the *Yes* position, so when dumping a COPY or INSERT statement for a partitioned table, target the root of the partitioning hierarchy which contains it rather than the partition itself. **Note:** This option is visible only for database server greater than or equal to 11.
.. image:: images/backup_disable.png
:alt: Disable option on backup dialog
+3 -3
View File
@@ -1,8 +1,8 @@
.. _backup_globals_dialog:
*************************
The Backup Globals Dialog
*************************
******************************
`Backup Globals Dialog`:index:
******************************
Use the *Backup Globals* dialog to create a plain-text script that recreates all of the database objects within a cluster, and the global objects that are shared by those databases. Global objects include tablespaces, roles, and object properties. You can use the pgAdmin *Query Tool* to play back a plain-text script, and recreate the objects in the backup.
+60 -6
View File
@@ -1,8 +1,8 @@
.. _backup_server_dialog:
*************************
The Backup Server Dialog
*************************
*****************************
`Backup Server Dialog`:index:
*****************************
Use the *Backup Server* dialog to create a plain-text script that will recreate the selected server. You can use the pgAdmin *Query Tool* to play back a plain-text script, and recreate the server.
@@ -12,12 +12,66 @@ Use the *Backup Server* dialog to create a plain-text script that will recreate
Use the fields in the *General* tab to specify the following:
* Enter the name of the backup file in the *Filename* field. Optionally, select the *Browser* icon (ellipsis) to the right to navigate into a directory and select a file that will contain the archive.
* Use the *Encoding* drop-down listbox to select the character encoding method that should be used for the archive. **Note:** This option is visible only for database server greater than or equal to 11.
* Use the drop-down listbox next to *Role name* to specify a role with connection privileges on the selected server. The role will be used for authentication during the backup.
Move switches in the *Miscellaneous* box to specify the type of statements that should be included in the backup.
.. image:: images/backup_server_objects.png
:alt: Type of objects option on backup server dialog
* Move the *Verbose messages* switch to the *No* position to exclude status messages from the backup. The default is *Yes*.
* Move the *Force double quote on identifiers* switch to the *Yes* position to name identifiers without changing case. The default is *No*.
* Move switches in the **Type of objects** field box to specify details about the type of objects that will be backed up.
* Move the switch next to *Only data* to the *Yes* position to limit the back up to data.
* Move the switch next to *Only schema* to limit the back up to schema-level database objects.
.. image:: images/backup_server_do_not_save.png
:alt: Do not save option on backup server dialog
* Move switches in the **Do not save** field box to select the objects that will not be included in the backup.
* Move the switch next to *Owner* to the *Yes* position to exclude commands that set object ownership.
* Move the switch next to *Privilege* to the *Yes* position to exclude commands that create access privileges.
* Move the switch next to *Tablespace* to the *Yes* position to exclude tablespaces.
* Move the switch next to *Unlogged table data* to the *Yes* position to exclude the contents of unlogged tables.
* Move the switch next to *Comments* to the *Yes* position to exclude commands that set the comments. **Note:** This option is visible only for database server greater than or equal to 11.
.. image:: images/backup_server_queries.png
:alt: Queries option on backup server dialog
* Move switches in the **Queries** field box to specify the type of statements that should be included in the backup.
* Move the switch next to *Use Column Inserts* to the *Yes* position to dump the data in the form of INSERT statements and include explicit column names. Please note: this may make restoration from backup slow.
* Move the switch next to *Use Insert commands* to the *Yes* position to dump the data in the form of INSERT statements rather than using a COPY command. Please note: this may make restoration from backup slow.
* Move the switch next to *Include DROP DATABASE statement* to the *Yes* position to include a command in the backup that will drop any existing database object with the same name before recreating the object during a backup.
.. image:: images/backup_server_disable.png
:alt: Disable option on backup server dialog
* Move switches in the **Disable** field box to specify the type of statements that should be excluded from the backup.
* Move the switch next to *Trigger* (active when creating a data-only backup) to the *Yes* position to include commands that will disable triggers on the target table while the data is being loaded.
* Move the switch next to *$ quoting* to the *Yes* position to enable dollar quoting within function bodies; if disabled, the function body will be quoted using SQL standard string syntax.
.. image:: images/backup_server_miscellaneous.png
:alt: Miscellaneous option on backup server dialog
* Move switches in the **Miscellaneous** field box to specify miscellaneous backup options.
* Move the switch next to *With OIDs* to the *Yes* position to include object identifiers as part of the table data for each table.
* Move the switch next to *Verbose messages* to the *No* position to instruct *pg_dump* to exclude verbose messages.
* Move the switch next to *Force double quotes on identifiers* to the *Yes* position to force the quoting of all identifiers.
* Move the switch next to *Use SET SESSION AUTHORIZATION* to the *Yes* position to include a statement that will use a SET SESSION AUTHORIZATION command to determine object ownership (instead of an ALTER OWNER command).
Click the *Backup* button to build and execute a command based on your selections; click the *Cancel* button to exit without saving work.
+3 -3
View File
@@ -1,8 +1,8 @@
.. _browser:
********************
The pgAdmin 4 Client
********************
*****************************
`The pgAdmin 4 Client`:index:
*****************************
pgAdmin 4 supports all PostgreSQL features, from writing simple SQL queries to developing complex databases. It is designed to query an active database (in real-time), allowing you to stay current with modifications and implementations.
+3 -3
View File
@@ -1,8 +1,8 @@
.. _cast_dialog:
***************
The Cast Dialog
***************
********************
`Cast Dialog`:index:
********************
Use the *Cast* dialog to define a cast. A cast specifies how to convert a value from one data type to another.
+3 -3
View File
@@ -1,8 +1,8 @@
.. _change_password_dialog:
**************************
The Change Password Dialog
**************************
*******************************
`Change Password Dialog`:index:
*******************************
It is a good policy to routinely change your password to protect data, even in what you may consider a 'safe' environment. In the workplace, failure to apply an appropriate password policy could leave you in breach of Data Protection laws.
+3 -3
View File
@@ -1,8 +1,8 @@
.. _change_user_password:
*******************************
The Change User Password Dialog
*******************************
************************************
`Change User Password Dialog`:index:
************************************
It is a good policy to routinely change your password to protect data, even in what you may consider a 'safe' environment. In the workplace, failure to apply an appropriate password policy could leave you in breach of Data Protection laws.
+3 -3
View File
@@ -1,8 +1,8 @@
.. _check_dialog:
****************
The Check Dialog
****************
*********************
`Check Dialog`:index:
*********************
Use the *Check* dialog to define or modify a check constraint. A check constraint specifies an expression that produces a Boolean result that new or updated rows must satisfy for an insert or update operation to succeed.
+19
View File
@@ -0,0 +1,19 @@
.. _clear_saved_passwords:
******************************
`Clear Saved Passwords`:index:
******************************
Use *Clear Saved Password* functionality to clear the saved password for the database server.
.. image:: images/clear_saved_password.png
*Clear Saved Password* shows in the context menu for the selected server as well as under the *Object* menu on the top menu bar.
Use *Clear SSH Tunnel Password* functionality to clear the saved password of SSH Tunnel to connect to the database server.
.. image:: images/clear_tunnel_password.png
*Clear SSH Tunnel Password* shows in the context menu for the selected server as well as under the *Object* menu on the top menu bar.
**Note:** It will be enabled/visible when the password for the selected database server is already saved.
+3 -3
View File
@@ -1,8 +1,8 @@
.. _code_overview:
*************
Code Overview
*************
**********************
`Code Overview`:index:
**********************
The bulk of pgAdmin is a Python web application written using the Flask framework
on the backend, and HTML5 with CSS3, Bootstrap and jQuery on the front end. A
+3 -3
View File
@@ -1,8 +1,8 @@
.. _code_review:
*****************
Code Review Notes
*****************
**************************
`Code Review Notes`:index:
**************************
This document lists a number of standard items that will be checked during the
review process for any patches submitted for inclusion in pgAdmin.
+3 -3
View File
@@ -1,8 +1,8 @@
.. _coding_standards:
****************
Coding Standards
****************
*************************
`Coding Standards`:index:
*************************
pgAdmin uses multiple technologies and multiple languages, each of which have
their own coding standards.
+3 -3
View File
@@ -1,8 +1,8 @@
.. _collation_dialog:
********************
The Collation Dialog
********************
*************************
`Collation Dialog`:index:
*************************
Use the *Collation* dialog to define a collation. A collation is an SQL schema object that maps a SQL name to operating system locales. To create a collation, you must have a CREATE privilege on the destination schema.
+3 -3
View File
@@ -1,8 +1,8 @@
.. _column_dialog:
*****************
The Column Dialog
*****************
**********************
`Column Dialog`:index:
**********************
Use the *Column* dialog to add a column to an existing table or modify a column definition.
+3 -3
View File
@@ -1,8 +1,8 @@
.. _connect_error:
******************
`Connection error`
******************
*************************
`Connection error`:index:
*************************
When connecting to a PostgreSQL server, you may get an error message. If you encounter an error message, please review the message carefully; each error message attempts to incorporate the information you'll need to resolve the problem. For more details about specific errors, please locate the error message in the list below:
+13 -3
View File
@@ -1,8 +1,8 @@
.. _connect_to_server:
*****************
Connect to server
*****************
**************************
`Connect to server`:index:
**************************
Use the *Connect to Server* dialog to authenticate with a defined server and access the objects stored on the server through the pgAdmin tree control. To access the dialog, right click on the server name in the *pgAdmin* tree control, and select *Connect Server...* from the context menu.
@@ -14,6 +14,16 @@ Provide authentication information for the selected server:
* Use the *Password* field to provide the password of the user that is associated with the defined server.
* Check the box next to *Save Password* to instruct the server to save the password for future connections; if you save the password, you will not be prompted when reconnecting to the database server with this server definition.
In case of SSH Tunneling, *Connect to Server* dialog will prompt for SSH Tunnel and Database server passwords if not already saved.
.. image:: images/connect_to_tunneled_server.png
:alt: Connect to server dialog
Provide authentication information for the selected server:
* Use the *Password* field to provide the password of the user that is associated with the defined server.
* Check the box next to respective *Save Password* to instruct the server to save the password for future connections; if you save the password, you will not be prompted when reconnecting to the database server with this server definition.
The pgAdmin client displays a message in a green status bar in the lower right corner when the server connects successfully.
If you receive an error message while attempting a connection, verify that your network is allowing the pgAdmin host and the host of the database server to communicate. For detailed information about a specific error message, please see the :ref:`Connection Error <connect_error>` help page.
+3 -3
View File
@@ -1,8 +1,8 @@
.. _connecting:
**********************
Connecting to a Server
**********************
*******************************
`Connecting to a Server`:index:
*******************************
Before you can use the pgAdmin client to manage the objects that reside on your Postgres server, you must define a connection to the server. You can (optionally) use the *Server Group* dialog to create server groups to organize the server connections within the tree control for easier management. To open the *Server Group* dialog, right-click on the *Servers* node of the tree control, and select *Server Group* from the *Create* menu.
+3 -3
View File
@@ -1,8 +1,8 @@
.. _contributions:
*****************************
pgAdmin Project Contributions
*****************************
**************************************
`pgAdmin Project Contributions`:index:
**************************************
pgAdmin is an open-source project that invites you to get involved in the development process. For more information about contributing to the pgAdmin project, contact the developers on the pgAdmin mailing list pgadmin-hackers@postgresql.org to discuss any ideas you might have for enhancements or bug fixes.
+3 -3
View File
@@ -1,8 +1,8 @@
.. _database_dialog:
*******************
The Database Dialog
*******************
************************
`Database Dialog`:index:
************************
Use the *Database* dialog to define or modify a database. To create a database, you must be a database superuser or have the CREATE privilege.
+3 -3
View File
@@ -1,8 +1,8 @@
.. _debugger:
******************
`pgAdmin Debugger`
******************
*************************
`pgAdmin Debugger`:index:
*************************
.. image:: images/debug_main.png
:alt: Debugger page
+3 -3
View File
@@ -1,8 +1,8 @@
.. _deployment:
******************
pgAdmin Deployment
******************
***************************
`pgAdmin Deployment`:index:
***************************
Pre-compiled and configured installation packages for pgAdmin 4 are available for a number of desktop environments; we recommend using an installer whenever possible. If you are interested in learning more about the project, or if a pgAdmin installer is not available for your environment, the pages listed below will provide detailed information about creating a custom deployment.
+8 -11
View File
@@ -1,8 +1,8 @@
.. _desktop_deployment:
******************
Desktop Deployment
******************
***************************
`Desktop Deployment`:index:
***************************
pgAdmin may be deployed as a desktop application by configuring the application
to run in desktop mode and then utilising the desktop runtime to host the
@@ -14,7 +14,7 @@ additional instances of pgAdmin are launched, a new browser tab will be opened
and be served by the existing instance of the server in order to minimise system
resource utilisation. Clicking the icon in the system tray will present a menu
offering options to open a new pgAdmin window, configure the runtime, view the
server log and shutdown the server.
server log and shut down the server.
.. note:: Pre-compiled and configured installation packages are available for
a number of platforms. These packages should be used by end-users whereever
@@ -68,7 +68,7 @@ semi-colon character, for example:
.. code-block:: bash
/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/;/Users/dpage/python-libs/
The configuration settings are stored using the QSettings class in Qt, which
will use an INI file on Unix systems (~/.config/pgadmin/pgadmin4.conf),
a plist file on Mac OS X (~/Library/Preferences/org.pgadmin.pgadmin4.plist),
@@ -81,13 +81,10 @@ The configuration settings:
+==========================+====================+===============================================================+
| ApplicationPath | String | The directory containing pgAdmin4.py |
+--------------------------+--------------------+---------------------------------------------------------------+
| BrowserCommand | String | An alternate command to run instead of the default browser. |
+--------------------------+--------------------+---------------------------------------------------------------+
| ConnectionTimeout | Integer | The number of seconds to wait for application server startup. |
+--------------------------+--------------------+---------------------------------------------------------------+
| PythonPath | String | The Python module search path |
+--------------------------+--------------------+---------------------------------------------------------------+
| Browser/Geometry | Binary | The runtime window's size/shape |
+--------------------------+--------------------+---------------------------------------------------------------+
| Browser/WindowState | Binary | The runtime window's state |
+--------------------------+--------------------+---------------------------------------------------------------+
| Browser/Zoom | String | The runtime window's zoom level (zoom % / 100) |
+--------------------------+--------------------+---------------------------------------------------------------+
+3 -3
View File
@@ -1,8 +1,8 @@
.. _developer_tools:
***************
Developer Tools
***************
************************
`Developer Tools`:index:
************************
The pgAdmin *Tools* menu displays a list of powerful developer tools that you can use to execute and analyze complex SQL commands, manage data, and debug PL/SQL code.
+3 -3
View File
@@ -1,8 +1,8 @@
.. _domain_constraint_dialog:
*****************************
The Domain Constraints Dialog
*****************************
**********************************
`Domain Constraints Dialog`:index:
**********************************
Use the *Domain Constraints* dialog to create or modify a domain constraint. A domain constraint confirms that the values provided for a domain meet a defined criteria. The *Domain Constraints* dialog implements options of the ALTER DOMAIN command.
+3 -3
View File
@@ -1,8 +1,8 @@
.. _domain_dialog:
*****************
The Domain Dialog
*****************
**********************
`Domain Dialog`:index:
**********************
Use the *Domain* dialog to define a domain. A domain is a data type definition that may constrain permissible values. Domains are useful when you are creating multiple tables that contain comparable columns; you can create a domain that defines constraints that are common to the columns and re-use the domain definition when creating the columns, rather than individually defining each set of constraints.
+24 -3
View File
@@ -38,7 +38,7 @@ Hover over an icon to display a tooltip that describes the icon's functionality.
+----------------------+---------------------------------------------------------------------------------------------------+-------------+
| *Paste Row* | Click the *Paste Row* icon to paste the content that is currently on the clipboard. | |
+----------------------+---------------------------------------------------------------------------------------------------+-------------+
| *Delete Row* | Use the *Delete Row* icon to add a new row in the output panel. | |
| *Delete Row* | Use the *Delete Row* icon to delete all the selected rows from the output panel. | |
+----------------------+---------------------------------------------------------------------------------------------------+-------------+
| *Filter* | Click the *Filter* icon to open a dialog that allows you to write and apply a filter for the | |
| | content currently displayed in the output panel. Click the down arrow to open the *Filter* drop- | |
@@ -67,7 +67,7 @@ Hover over an icon to display a tooltip that describes the icon's functionality.
+----------------------+---------------------------------------------------------------------------------------------------+-------------+
| *Stop* | Click the *Stop* icon to cancel the execution of the currently running query. | |
+----------------------+---------------------------------------------------------------------------------------------------+-------------+
| *Clear query window* | Use the *Clear query window* drop-down menu to erase the contents of the *History* tab. | |
| *Clear History* | Use the *Clear History* drop-down menu to erase the contents of the *History* tab. | |
+----------------------+---------------------------------------------------------------------------------------------------+-------------+
| *Download as CSV* | Click the *Download as CSV* icon to download the result set of the current query to a | F8 |
| | comma-separated list. You can control the CSV settings through | |
@@ -95,6 +95,28 @@ To delete a row, press the *Delete* toolbar button. A popup will open, asking y
To commit the changes to the server, select the *Save* toolbar button. Modifications to a row are written to the server automatically when you select a different row.
**Geometry Data Viewer**
If PostGIS is installed, you can view GIS objects in a map by selecting row(s) and clicking the 'View Geometry' button in the column. If no rows are selected, the entire data set will be rendered:
.. image:: images/geometry_viewer.png
:alt: Geometry Viewer Button
You can adjust the layout by dragging the title of the panel. To view the properties of the geometries directly in map, just click the specific geometry:
.. image:: images/geometry_viewer_property_table.png
:alt: Geometry Viewer Property Table
Notes:
- *Supported data types:* The Geometry Viewer supports 2D and 3DM geometries in EWKB format including `Point, LineString, Polygon MultiPoint, MultiLineString, MultiPolygon and GeometryCollection`.
- *SRIDs:* If there are geometries with different SRIDs in the same column, the viewer will render geometries with the same SRID in the map. If SRID=4326 the OSM tile layer will be added into the map.
- *Data size:* For performance reasons, the viewer will render no more than 100000 geometries, totaling up to 20MB.
- *Internet access:* An internet connection is required for the Geometry Viewer to function correctly.
**Sort/Filter options dialog**
You can access *Sort/Filter options dialog* by clicking on Sort/Filter button. This allows you to specify an SQL Filter to limit the data displayed and data sorting options in the edit grid window:
@@ -120,4 +142,3 @@ To delete a row from the grid, click the trash icon.
* Click the *Help* button (?) to access online help.
* Click the *Ok* button to save work.
* Click the *Close* button to discard current changes and close the dialog.
+3 -3
View File
@@ -1,8 +1,8 @@
.. _event_trigger_dialog:
************************
The Event Trigger Dialog
************************
*****************************
`Event Trigger Dialog`:index:
*****************************
Use the *Domain Trigger* dialog to define an event trigger. Unlike regular triggers, which are attached to a single table and capture only DML events, event triggers are global to a particular database and are capable of capturing DDL events. Like regular triggers, event triggers can be written in any procedural language that includes event trigger support, or in C, but not in SQL.
+5 -3
View File
@@ -1,8 +1,8 @@
.. _exclusion_constraint_dialog:
*******************************
The Exclusion constraint Dialog
*******************************
************************************
`Exclusion constraint Dialog`:index:
************************************
Use the *Exclusion constraint* dialog to define or modify the behavior of an exclusion constraint. An exclusion constraint guarantees that if any two rows are compared on the specified column or expression (using the specified operator), at least one of the operator comparisons will return false or null.
@@ -48,6 +48,8 @@ Use the fields in the *Columns* tab to to specify the column(s) to which the con
* Use the *NULLs order* column to specify the placement of NULL values (when sorted). Specify *FIRST* or *LAST*.
* Use the drop-down list next to *Operator* to specify a comparison or conditional operator.
Use *Include columns* field to specify columns for *INCLUDE* clause of the constraint. This option is available in Postgres 11 and later.
Click the *SQL* tab to continue.
Your entries in the *Exclusion Constraint* dialog generate a SQL command (see an example below). Use the *SQL* tab for review; revisit or switch tabs to make any changes to the SQL command.
+3 -3
View File
@@ -1,8 +1,8 @@
.. _extension_dialog:
********************
The Extension Dialog
********************
*************************
`Extension Dialog`:index:
*************************
Use the *Extension* dialog to install a new extension into the current database. An extension is a collection of SQL objects that add targeted functionality to your Postgres installation. The *Extension* dialog adds the functionality of an extension to the current database only; you must register the extension in each database that use the extension. Before you load an extension into a database, you should confirm that any pre-requisite files are installed.
+3 -3
View File
@@ -1,8 +1,8 @@
.. _foreign_data_wrapper_dialog:
*******************************
The Foreign Data Wrapper Dialog
*******************************
************************************
`Foreign Data Wrapper Dialog`:index:
************************************
Use the *Foreign Data Wrapper* dialog to create or modify a foreign data wrapper. A foreign data wrapper is an adapter between a Postgres database and data stored on another data source.
+3 -3
View File
@@ -1,8 +1,8 @@
.. _foreign_key_dialog:
**********************
The Foreign key Dialog
**********************
***************************
`Foreign key Dialog`:index:
***************************
Use the *Foreign key* dialog to specify the behavior of a foreign key constraint. A foreign key constraint maintains referential integrity between two tables. A foreign key constraint cannot be defined between a temporary table and a permanent table.
+3 -3
View File
@@ -1,8 +1,8 @@
.. _foreign_server_dialog:
*************************
The Foreign Server Dialog
*************************
******************************
`Foreign Server Dialog`:index:
******************************
Use the *Foreign Server* dialog to create a foreign server. A foreign server typically encapsulates connection information that a foreign-data wrapper uses to access an external data resource. Each foreign data wrapper may connect to a different foreign server; in the *pgAdmin* tree control, expand the node of the applicable foreign data wrapper to launch the *Foreign Server* dialog.
+3 -3
View File
@@ -1,8 +1,8 @@
.. _foreign_table_dialog:
************************
The Foreign Table Dialog
************************
*****************************
`Foreign Table Dialog`:index:
*****************************
Use the *Foreign Table* dialog to define a foreign table in the current database. Foreign tables define the structure of an external data source that resides on a foreign server.
+3 -3
View File
@@ -1,8 +1,8 @@
.. _fts_configuration_dialog:
****************************
The FTS Configuration dialog
****************************
*********************************
`FTS Configuration dialog`:index:
*********************************
Use the *FTS Configuration* dialog to configure a full text search. A text search configuration specifies a text search parser that can divide a string into tokens, along with dictionaries that can identify searchable tokens.
+3 -3
View File
@@ -1,8 +1,8 @@
.. _fts_dictionary_dialog:
*************************
The FTS Dictionary Dialog
*************************
******************************
`FTS Dictionary Dialog`:index:
******************************
Use the *FTS Dictionary* dialog to create a full text search dictionary. You can use a predefined templates or create a new dictionary with custom parameters.
+3 -3
View File
@@ -1,8 +1,8 @@
.. _fts_parser_dialog:
*********************
The FTS Parser Dialog
*********************
**************************
`FTS Parser Dialog`:index:
**************************
Use the *FTS Parser* dialog to create a new text search parser. A text search parser defines a method for splitting a text string into tokens and assigning types (categories) to the tokens.
+3 -3
View File
@@ -1,8 +1,8 @@
.. _fts_template_dialog:
***********************
The FTS Template Dialog
***********************
****************************
`FTS Template Dialog`:index:
****************************
Use the *FTS Template* dialog to create a new text search template. A text search template defines the functions that implement text search dictionaries.
+3 -3
View File
@@ -1,8 +1,8 @@
.. _function_dialog:
*******************
The Function Dialog
*******************
************************
`Function Dialog`:index:
************************
Use the *Function* dialog to define a function. If you drop and then recreate a function, the new function is not the same entity as the old; you must drop existing rules, views, triggers, etc. that refer to the old function.
+3 -3
View File
@@ -1,8 +1,8 @@
.. _getting_started:
***************
Getting Started
***************
************************
`Getting Started`:index:
************************
Pre-compiled and configured installation packages for pgAdmin 4 are available
for a number of desktop environments; we recommend using an installer
+3 -3
View File
@@ -1,8 +1,8 @@
.. _grant_wizard:
************
Grant Wizard
************
*********************
`Grant Wizard`:index:
*********************
The *Grant Wizard* tool is a graphical interface that allows you to manage the privileges of one or more database objects in a point-and-click environment. A search box, dropdown lists, and checkboxes facilitate quick selections of database objects, roles and privileges.
Binary file not shown.

Before

Width:  |  Height:  |  Size: 39 KiB

After

Width:  |  Height:  |  Size: 60 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 47 KiB

After

Width:  |  Height:  |  Size: 94 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 85 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 95 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 47 KiB

After

Width:  |  Height:  |  Size: 105 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 99 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 80 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 91 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 113 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 117 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 57 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 57 KiB

After

Width:  |  Height:  |  Size: 52 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 38 KiB

After

Width:  |  Height:  |  Size: 37 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 58 KiB

After

Width:  |  Height:  |  Size: 59 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 36 KiB

After

Width:  |  Height:  |  Size: 49 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 449 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 495 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 75 KiB

After

Width:  |  Height:  |  Size: 59 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 82 KiB

After

Width:  |  Height:  |  Size: 68 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 50 KiB

After

Width:  |  Height:  |  Size: 91 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 54 KiB

After

Width:  |  Height:  |  Size: 40 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 129 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 52 KiB

After

Width:  |  Height:  |  Size: 59 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 52 KiB

After

Width:  |  Height:  |  Size: 58 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 36 KiB

After

Width:  |  Height:  |  Size: 114 KiB

BIN
View File
Binary file not shown.

Before

Width:  |  Height:  |  Size: 33 KiB

After

Width:  |  Height:  |  Size: 70 KiB

BIN
View File
Binary file not shown.

Before

Width:  |  Height:  |  Size: 65 KiB

After

Width:  |  Height:  |  Size: 59 KiB

BIN
View File
Binary file not shown.

Before

Width:  |  Height:  |  Size: 36 KiB

After

Width:  |  Height:  |  Size: 54 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 75 KiB

Regular → Executable
BIN
View File
Binary file not shown.

Before

Width:  |  Height:  |  Size: 41 KiB

After

Width:  |  Height:  |  Size: 56 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 321 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 63 KiB

After

Width:  |  Height:  |  Size: 60 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 53 KiB

After

Width:  |  Height:  |  Size: 35 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 77 KiB

After

Width:  |  Height:  |  Size: 69 KiB

+3 -3
View File
@@ -1,8 +1,8 @@
.. _import_export_data:
*****************************
The Import/Export data Dialog
*****************************
**********************************
`Import/Export data Dialog`:index:
**********************************
Use the *Import/Export data* dialog to copy data from a table to a file, or copy data from a file into a table.
+5 -3
View File
@@ -1,8 +1,8 @@
.. _index_dialog:
****************
The Index Dialog
****************
*********************
`Index Dialog`:index:
*********************
Use the *Index* dialog to create an index on a specified table or materialized view.
@@ -55,6 +55,8 @@ Use the context-sensitive fields in the *Columns* panel to specify which column(
* Use the drop-down listbox in the *Collation* field to select a collation to use for the index.
Use *Include columns* field to specify columns for *INCLUDE* clause of the index. This option is available in Postgres 11 and later.
Click the *SQL* tab to continue.
Your entries in the *Index* dialog generate a SQL command (see an example below). Use the *SQL* tab for review; revisit or switch tabs to make any changes to the SQL command.
+3 -3
View File
@@ -1,6 +1,6 @@
******************
Keyboard Shortcuts
******************
***************************
`Keyboard Shortcuts`:index:
***************************
Keyboard shortcuts are provided in pgAdmin to allow easy access to specific
functions. Alternate shortcuts can be configured through File > Preferences if
+3 -3
View File
@@ -1,8 +1,8 @@
.. _language:
*******************
The Language Dialog
*******************
************************
`Language Dialog`:index:
************************
Use the CREATE LANGUAGE dialog to register a new procedural language.
+3 -3
View File
@@ -1,7 +1,7 @@
.. _licence:
*******
Licence
*******
****************
`Licence`:index:
****************
pgAdmin is released under the `PostgreSQL Licence <http://www.postgresql.org/about/licence>`_, which is a liberal Open Source licence similar to BSD or MIT, and approved by the Open Source Initiative. The copyright for the project source code, website and documentation is attributed to the `pgAdmin Development Team <https://www.pgadmin.org/development/team.php>`_.
+3 -3
View File
@@ -1,8 +1,8 @@
.. _maintenance_dialog:
**********************
The Maintenance Dialog
**********************
***************************
`Maintenance Dialog`:index:
***************************
Use the *Maintenance* dialog to VACUUM, ANALYZE, REINDEX or CLUSTER a database or selected database objects.
+3 -3
View File
@@ -1,8 +1,8 @@
.. _management_basics:
*****************
Management Basics
*****************
**************************
`Management Basics`:index:
**************************
pgAdmin provides point and click dialogs that help you perform server management functions. Dialogs simplify tasks such as managing named restore points, granting user privileges, and performing VACUUM, ANALYZE and REINDEX functions.
+3 -3
View File
@@ -1,8 +1,8 @@
.. _managing_cluster_objects:
******************************
Managing Cluster Level Objects
******************************
***************************************
`Managing Cluster Level Objects`:index:
***************************************
Some object definitions reside at the cluster level; pgAdmin 4 provides dialogs that allow you to create these objects, manage them, and control their relationships to each other. To access a dialog that allows you to create a database object, right-click on the object type in the pgAdmin tree control, and select the *Create* option for that object. For example, to create a new database, right-click on the *Databases* node, and select *Create Database...*
+3 -3
View File
@@ -1,8 +1,8 @@
.. _managing_database_objects:
*************************
Managing Database Objects
*************************
**********************************
`Managing Database Objects`:index:
**********************************
pgAdmin 4 provides simple but powerful dialogs that you can use to design and create database objects. Each dialog contains a series of tabs that you use to describe the object that will be created by the dialog; the SQL tab displays the SQL command that the server will execute when creating the object.
Loaded 100 of 657 files, more files were not shown because too many files have changed in this diff. Show more