Yahnis Elsts
bf21da2ff2
Re-add Puc_v4_Factory for better backwards compatibility.
...
This way developers that used an older 4.x version shouldn't need to change their code when they update to this version.
2017-11-26 21:40:17 +02:00
Yahnis Elsts
ec5ee45379
Show API errors when manually checking for updates.
...
Introduces a new hook: "puc_api_error". This is an action with up to 4 callback arguments:
1) $error - A WP_Error instance that provides a brief description of the error.
2) $response - The value returned by wp_remote_get(). Can be omitted if the original response is not available at this point.
3) $url - The URL that the update checker requested. Can be omitted.
4) $slug - The plugin or theme slug. Can be omitted.
See #151
2017-11-24 17:36:15 +02:00
Yahnis Elsts
585f60d91c
Add the ability to show a plugin icon on the "Dashboard -> Updates" page.
...
Usage: Add the following entry to your JSON file:
"icons" : {
"1x" : "http://example.com/assets/icon-128x128.png ",
"2x" : "http://example.com/assets/icon-256x256.png ",
"svg": "http://example.com/assets/icon.svg "
}
All of the keys are optional. They should point to different versions of the same icon:
- "1x": a 128x128 px image.
- "2x": a 256x256 px image for HiDPI screens.
- "svg": a vector version of the icon.
See WordPress.org for more information on supported icon sizes and image formats:
https://developer.wordpress.org/plugins/wordpress-org/plugin-assets/#plugin-icons
Suggested in #153
2017-11-21 22:11:18 +02:00
Yahnis Elsts
150d3d8165
Rename Puc_v4_Factory to Puc_v4p3_Factory
...
This should fix the fatal error that happens when running PUC 4.3 together with an older 4.x release while Debug Bar is active.
See #152
2017-11-16 17:00:22 +02:00
Yahnis Elsts
22fd23a32b
Fix: Remove left-over debugging code.
2017-11-03 19:20:11 +02:00
Yahnis Elsts
548b9fbec7
Minor: Fix incorrect link text in the readme
2017-11-03 13:45:11 +02:00
Yahnis Elsts
8be2d1d966
Minor: Fix another spelling error and reformat comments for consistency
2017-11-03 13:44:29 +02:00
Yahnis Elsts
1a7d95a017
Minor: Fix a spelling error in method name
2017-11-03 13:23:53 +02:00
Yahnis Elsts
92763829c6
Bump version number to 4.3
2017-11-03 13:22:55 +02:00
Yahnis Elsts
3a1f929a7f
VCS integration: Support alternative readme.txt capitalisations
...
Apparently, some developers call the file "README.txt" instead of "readme.txt". Most version control systems are case-sensitive, so we need to known the exact capitalisation to successfully retrieve the readme from the repository. Let's search the plugin directory to find the local readme file and then use that name.
Closes #147
2017-11-02 13:49:17 +02:00
Yahnis Elsts
9d9bab0462
Minor: Reformat and refactor addViewDetailsLink()
...
- WordPress escapes the site URL when building the "Visit plugin site" link, so we need to look for the escaped URL instead of the raw string.
- Using regexps is probably overkill. A simple string search will do.
- Add a default case to the switch in case a plugin returns an invalid link position.
- Move the "view_details_link_position" filter inside the foreach loop to eliminate an if().
- Move the slug check closer to the top. There's no point in running the "view_details_link" filter if the link isn't going to be shown anyway.
2017-11-02 10:13:21 +02:00
Yahnis Elsts
fa412cad65
Merge pull request #146 from Mikk3lRo/always-show-details-link
...
Always show the "View details" link
2017-11-02 09:47:59 +02:00
Mikk3lRo
eaa06eae6c
My IDE still refuses to use tabs for indentation - sorry :p
2017-11-01 16:53:50 +01:00
Mikk3lRo
5703f6e338
Make "Visit Plugin Site"-link detection more robust and correct comment to reflect new default position.
2017-11-01 16:51:33 +01:00
Mikk3lRo
727b99573c
Rename first -> before and last -> after and set default to before for placement of View details link.
2017-11-01 16:39:00 +01:00
Mikk3lRo
844c1fdb53
Update docblock
2017-10-31 03:07:23 +01:00
Mikk3lRo
1ebe29e1a4
Add spaces inside some paranthesis.
2017-10-31 03:04:04 +01:00
Mikk3lRo
5a4e5a44a2
Remove filter to add View Details Link. Extend / modify order of links.
2017-10-31 02:35:00 +01:00
Mikk3lRo
eb12e77706
Added third argument to addViewDetailsLink.
2017-10-30 19:18:52 +01:00
Mikk3lRo
5e987d8982
Use the same method of checking for empty linkText as used in the pre-
...
existing addCheckForUpdatesLink
2017-10-23 23:59:09 +02:00
Mikk3lRo
e5d96dbf05
Whoops, we use tabs in this one, not spaces.
2017-10-23 23:49:14 +02:00
Mikk3lRo
d39c1e400c
Wrong hook
2017-10-23 23:41:00 +02:00
Mikk3lRo
732179b0c0
Always show the plugin details link on the plugin list
2017-10-23 23:38:36 +02:00
Yahnis Elsts
1d3893edf9
Merge pull request #143 from Mikk3lRo/add-danish-language
...
Add Danish translation.
2017-10-17 19:44:46 +03:00
Mikkel-i123
1f810e1015
Add Danish translation.
2017-10-17 11:07:53 +02:00
Yahnis Elsts
21814c43a3
Merge pull request #141 from dylanmoller/master
...
Add Swedish translation
2017-10-17 11:48:21 +03:00
dylanmoller
6ae193fb26
added po/mo language files for Swedish translation
2017-10-16 15:23:20 +02:00
Yahnis Elsts
18818714c3
Merge pull request #140 from DavidAnderson684/patch-9
...
Use the wp_get_installed_translations function conditionally
This function was introduced in WP 3.7.
2017-10-13 19:09:03 +03:00
David Anderson
f0a10eaca9
Use a WP 3.7+ function conditionally
...
`wp_get_installed_translations()` was introduced in WP 3.7. This change returns an empty result for the translations list if the function does not exist. (Encountered in the wild, fatal error).
2017-10-13 12:26:16 +00:00
Yahnis Elsts
818ceaffc0
Merge pull request #139 from Mikk3lRo/add-note-about-134
...
Add note about issue #134 until a better solution is found.
2017-10-11 17:47:13 +03:00
Yahnis Elsts
e48d41e30d
Remove PUC hooks upon uninstallation to prevent a crash
...
See #138 for details.
2017-10-11 17:24:23 +03:00
Mikkel-i123
500e5ebb86
Add note about issue #134 until a better solution is found.
2017-10-10 16:41:48 +02:00
Yahnis Elsts
1cc6a90acf
Merge pull request #137 from aaronkirkham/master
...
GitLab Integration
2017-10-06 10:56:25 +03:00
aaronlad
58e28b8fd7
code style consistency changes
2017-10-05 16:52:41 +01:00
Yahnis Elsts
76c3e1cea1
Merge pull request #136 from DavidAnderson684/patch-8
...
Work on WP versions without wp_normalize_path()
2017-09-30 19:12:38 +03:00
David Anderson
aa4272cbcc
Correct typo
2017-09-30 16:08:50 +00:00
David Anderson
36eb8e3b10
Use Puc_v4_Factory::normalizePath()
2017-09-30 16:06:46 +00:00
David Anderson
972d649614
Make normalizePath public
2017-09-30 16:03:50 +00:00
aaronkirkham07@gmail.com
50b5d7170e
removed getLatestCommit method
...
removed Factory magic to detect self-hosted gitlab instances
updated readme with gitlab instructions
2017-09-30 16:15:00 +01:00
David Anderson
2f225bdcce
Code style consistency
2017-09-30 14:40:07 +00:00
aaronkirkham07@gmail.com
a2ca0ba0f2
support gitlab instances installed in a subdirectory
...
no longer checking for 'gitlab' in the hostname
2017-09-30 15:38:16 +01:00
Yahnis Elsts
8db5115e69
Minor: Update year in license.txt
2017-09-30 12:34:06 +03:00
aaronkirkham07@gmail.com
ccc07e9ce3
sprintf consistency
2017-09-30 01:55:37 +01:00
aaronkirkham07@gmail.com
4339460aed
fix weird tab/spaces
2017-09-30 01:45:09 +01:00
aaronkirkham07@gmail.com
cf2c07a531
support downloads from gitlab
...
added support for branches
implemented getLatestCommitTime method
2017-09-30 01:32:10 +01:00
aaronkirkham07@gmail.com
84f2efda8f
fix spaces
2017-09-30 00:45:46 +01:00
aaronkirkham07@gmail.com
3760c5140e
initial support for GitLab
2017-09-30 00:43:58 +01:00
David Anderson
fbe1d818c1
Work on WP versions without wp_normalize_path()
...
WP < 3.9 does not have the wp_normalize_path() function available. This edit restores the ability to work on such versions.
2017-09-29 21:37:31 +00:00
Yahnis Elsts
a0e272295a
Merge pull request #131 from anugupta/PHP7
...
Fix a false-positive PHP 7 compatibility issue
Several users have reported a PHP 7 compatibility issue in ParsedownLegacy.php. This file is never used on sites running PHP 7 (it's a back-compat thing for PHP 5.2 and below), but it seems like a good idea to merge the fix anyway as it will prevent any more time being wasted on this issue.
2017-09-07 11:22:38 +03:00
Anu Gupta
c7fcfb38b1
Force evaluation order for PHP 7 conpat
...
As per http://php.net/manual/en/migration70.incompatible.php#migration70.incompatible.variable-handling.indirect
In PHP 7, indirect access to variables, properties, and methods is now evaluated strictly in left-to-right order. Code that used the old right-to-left evaluation order must be rewritten to explicitly use that evaluation order with curly braces
2017-09-07 00:49:29 +01:00