Commit Graph

107 Commits

Author SHA1 Message Date
gfyoung 50abbd3e53 Enable frozen string in app/models/*.rb
Partially addresses #47424.
2018-07-26 16:55:41 -07:00
Douwe Maan 10bd800297 Merge branch 'satishperala/gitlab-ce-20720_webhooks_full_image_url' into 'master'
Include full image URL in webhooks for uploaded images

Closes #20720

See merge request gitlab-org/gitlab-ce!18109
2018-07-17 15:57:10 +00:00
Lin Jen-Shin 9286f5b934 Use stable gitlab-styles and eliminate offenses 2018-07-09 21:13:08 +08:00
Lin Jen-Shin 4ee08b77bc Updates from `rubocop -a` 2018-07-09 21:13:08 +08:00
Sean McGivern 7ff24772b6 Add base class for hook builders, and use it for notes and wikis 2018-06-20 15:52:16 +01:00
Satish Perala 9170aab92e Passing absolute image urls in the markdown content in the webhooks 2018-06-20 14:13:23 +01:00
Francisco Javier López e8a27a67fa Fix Custom hooks are not triggered by UI wiki edit 2018-04-18 17:50:56 +00:00
Francisco Javier López 27c08a1689 Allow moving wiki pages from the UI 2018-02-05 17:17:21 +00:00
Ahmad Sherif fa9d47f221 Migrate fetching wiki page formatted content to Gitaly
Closes gitaly#958
2018-01-30 17:19:39 +01:00
Francisco Javier López ff26ea818c Resolve "Performance issues when loading large number of wiki pages" 2017-11-17 11:48:32 +00:00
Jacob Vosmaer (GitLab) 5dd26d4e5a Hide Gollum inside Gitlab::Git::Wiki 2017-10-03 16:58:33 +00:00
Jacopo 378ee1dac2 Unescape HTML characters in Wiki title
The special characters of a wiki title are now escaped correctly.
2017-08-30 21:59:09 +02:00
wendy0402 29be4e0f58 Allow wiki pages to be renamed in the UI 2017-08-03 07:38:11 +07:00
Hiroyuki Sato 35259a4f48 Encapsulate the commit.sha logic 2017-07-27 22:15:48 +09:00
Hiroyuki Sato df65334eca Refactor: use keyword arguments for optional parameters 2017-07-23 21:43:32 +09:00
Hiroyuki Sato 9b25bbc45d Merge branch 'master' into 1827-prevent-concurrent-editing-wiki
Conflicts:
	app/controllers/projects/wikis_controller.rb
	app/views/projects/wikis/edit.html.haml
	spec/features/projects/wiki/user_updates_wiki_page_spec.rb
2017-07-23 21:26:02 +09:00
Grzegorz Bizon 0430b76441 Enable Style/DotPosition Rubocop 👮 2017-06-21 13:48:12 +00:00
Dongqing Hu 2dd9b8a38a Fix Project Wiki update 2017-03-20 13:53:23 +00:00
TM Lee 333e39d492 [#28991] Wiki page edit button only appears on the current commit page
- Added method to check if the current Page version is the current latest version
- Conditionally checks for current version when showing Edit button
- Added feature specs for viewing project wiki page and expect edit button
- Added Changelog
2017-03-16 09:08:00 +08:00
Hiroyuki Sato a5521bad40 Prevent concurrent editing wiki 2017-03-08 18:42:50 +09:00
Mark Fletcher 109e8ef448 Make WikiPage comparable according to StaticModel interface
* Add WikiPage#id method returning associated SHA for wiki page commit
2017-02-14 11:16:34 +05:30
Douwe Maan 018a7c6a55 Merge branch '23535-folders-in-wiki-repository' into 'master'
Show directory hierarchy when listing wiki pages

Closes #23535

See merge request !8133
2017-02-13 17:04:15 +00:00
Z.J. van de Weg 128b1eae09 Update Rubocop to ruby 2.3 2017-02-07 15:16:46 +01:00
Alex Braha Stoll 683097666a Add WikiPage.unhyphenize 2017-01-30 01:07:31 -02:00
Alex Braha Stoll 389bd6b735 Improve WikiPage.group_by_directory 2016-12-31 17:03:20 -02:00
Alex Braha Stoll d2b3fe45af Change WikiPage#directory 2016-12-31 16:55:50 -02:00
Alex Braha Stoll 104bfa2a31 Remove WikiPage#full_path 2016-12-31 16:55:50 -02:00
Alex Braha Stoll 84735186a8 Add WikiPage#to_partial_path 2016-12-31 16:55:50 -02:00
Alex Braha Stoll c8a1e96826 Change WikiPage.group_by_directory to use WikiDirectory 2016-12-31 16:55:50 -02:00
Alex Braha Stoll 8d8c5d9f61 Simplify WikiPage.group_by_directory by using Enumerable#group_by 2016-12-31 16:55:50 -02:00
Alex Braha Stoll 77fe503a1f Remove WikiPage.sort_by_directory 2016-12-31 16:55:50 -02:00
Alex Braha Stoll f25344e36e Change WikiPage.group_by_directory to order by directory and file alphabetical order 2016-12-31 16:55:50 -02:00
Alex Braha Stoll 5607bb8f09 Change WikiPage#directory to always start a directory hierarchy with '/' 2016-12-31 16:55:50 -02:00
Alex Braha Stoll 904aa039e5 Change WikiPage.group_by_directory to use WikiPage#directory 2016-12-31 16:55:50 -02:00
Alex Braha Stoll 5bbe655991 Add component to show the full path of a wiki page when viewing its content 2016-12-31 16:55:50 -02:00
Alex Braha Stoll c7294dded2 Remove WikiPage.add_to_directory 2016-12-31 16:55:50 -02:00
Alex Braha Stoll bebfba3e6d Refactor WikiPage.group_by_directory 2016-12-31 16:55:50 -02:00
Alex Braha Stoll 8bf52a4ae3 Show directory hierarchy when listing wiki pages 2016-12-31 16:55:50 -02:00
Timothy Andrew 42a00f740b `WikiPage` should have a slug even when not persisted.
1. So we can build the markdown preview URL for it.

2. We can't skip the slug in this case, because the slug is used to
construct relative markdown URLs.

3. Add rspec feature tests to cover creating wiki pages with
   spaces/hyphens in the name.

4. Add rspec feature tests for markdown preview URL rewriting, which was
   only covered by unit tests up to this point.
2016-07-25 09:22:47 +05:30
Sebastian Klier 54661d3d44 add slack notifications for wiki pages
update changelog
2016-04-20 08:25:40 +08:00
Hiroyuki Sato 8acad49fe0 Support Wiki with UTF-8 page name 2016-03-16 02:17:07 +09:00
Douglas Barbosa Alexandre aa30088f6e Fix old version warning when viewing wiki latest version via version_id 2016-01-29 14:17:00 -02:00
Douglas Barbosa Alexandre aac6598482 Relax constraints for wiki slug
Since GitHub doesn’t apply these constraints to theirs wiki slug
allowing characters like `,`, `:`, `*`, etc, we need to relax our
constraints or some wiki pages will not be available after they were
imported.

For an example the Devise project have a wiki page with the following
slug: “How To: Add sign_in, sign_out, and sign_up links to your layout
template”
2016-01-14 12:09:31 -02:00
Stan Hu 59d5c77975 Fix dots in Wiki slug causing errors
Closes #1263, #431
2015-03-21 18:33:51 -07:00
Dmitriy Zaporozhets 9fbdbf8b3f Rubocop: Style/Alias enabled 2015-02-02 20:57:10 -08:00
Dmitriy Zaporozhets 4b65b0e0f5
Fix wiki
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2014-09-25 13:56:23 +03:00
Marin Jankovski fac225780c A bit clearer naming for gollum_wiki. 2014-05-05 14:01:48 +02:00
Marin Jankovski cb69baedd3 Remove empty line. 2014-04-30 11:48:46 +02:00
Marin Jankovski c4b1a5f5ea Allow nested files in wiki. 2014-04-28 16:22:31 +02:00
Dmitriy Zaporozhets 2ed56ce9d4 Merge branch 'speed_up_wiki_pages' into 'master'
Speed up wiki pages page
2014-04-14 13:20:35 +00:00
Marin Jankovski 872482678b Speed up loading and add pagination to wiki pages page. 2014-04-11 10:02:52 +02:00
Hiroyuki Sato bca528a57c Better title format for wiki page
The title format for wiki page may be unintelligible.
For example 'GitLab' is converted to 'Git Lab', 'MySQL' is converted to
'My Sql', etc.
2014-04-10 15:14:02 +09:00
Dmitriy Zaporozhets 26ec74c446
Refactor wiki model
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2014-04-09 14:35:26 +03:00
Dmitriy Zaporozhets 0e387919c3 Fixed wrong last-edit time for wiki 2013-08-16 16:59:26 +03:00
Johannes Schleifenbaum cd19f82e51 Fix typos 2013-07-29 12:47:06 +02:00
Dmitriy Zaporozhets 49b024f5f5 Use Gitlab::Git:: for git features across application 2013-04-01 16:04:35 +03:00
Dan Knox ea9b3687db Replace current Wiki system with Gollum Wikis.
This commit replaces the old database backed Wiki system with the
excellent Gollum git based Wiki system.

The UI has been updated to allow for utilizing the extra features
that Gollum provides. Specifically:

* Edit page now allows you to choose the content format.
* Edit page allows you to provide a commit message for the change.
* History page now shows Format, Commit Message, and Commit Hash.
* A new Git Access page has been added with the Wiki Repo URL.
* The default page has been changed to Home from Index to match
the Gollum standard.

The old Wiki model has been left in tact to provide for the
development of a migration script that will move all content stored
in the old Wiki system into new Gollum Wikis.
2013-03-09 16:39:51 -08:00