ᴊᴏᴇ ᴄʜᴇɴ
59e9fa191b
chore: remove all MIT license file headers ( #8083 )
...
Co-authored-by: deepsource-autofix[bot] <62050782+deepsource-autofix[bot]@users.noreply.github.com>
2026-01-08 19:32:15 -05:00
Jakub Domeracki
2c88cd4d9f
security: patch mermaid package version
...
Co-authored-by: Jakub Domeracki <jdomeracki.itsec@gmail.com >
Co-authored-by: ᴊᴏᴇ ᴄʜᴇɴ <jc@unknwon.io >
2025-12-04 14:58:06 +09:00
Dmitry Afanasiev
6a6364bb5d
chore: update mermaid to 11.9.0 ( #8009 )
...
Co-authored-by: ᴊᴏᴇ ᴄʜᴇɴ <jc@unknwon.io >
2025-09-30 06:11:09 -04:00
Edoardo Ottavianelli
4d6a0ebaac
security: patch for Stored XSS in PDF renderer ( #7966 )
2025-05-16 15:49:58 -04:00
MarcUs7i
b59e943aa6
Set timeout to explicit 0 in gogs.js ( #7890 )
...
## Describe the pull request
A simple fix in public/js/gogs.js making bug upload not result in a
timeout (added just one line)
Link to the issue: closes https://github.com/gogs/gogs/issues/6149
## Test plan
- Set the max_size of `attachment` to a high number
```toml
[release.attachment]
ENABLED = true
ALLOWED_TYPES = */*
MAX_SIZE = 512
MAX_FILES = 20
```
- Upload a file to releases

It doesn't randomly timeout!
2025-01-01 19:41:24 -05:00
Sergei Gnezdov
f4a78e5cfb
chore: update version of mermaid to 10.9.1 ( #7760 )
2024-06-08 12:57:00 -04:00
Joe Chen
d0a4a3401c
refactor(db): migrate avatar methods off user.go ( #7206 )
2022-10-23 20:54:16 +08:00
Michael Li
32c454ba5f
assets: convert usage of go-bindata to Go embed ( #6851 )
...
Co-authored-by: Joe Chen <jc@unknwon.io >
2022-03-17 14:05:09 +08:00
shuyue
7c893a58da
markdown: support rendering Mermaid diagrams ( #6776 )
...
Co-authored-by: Joe Chen <jc@unknwon.io >
2022-03-05 19:23:08 +08:00
Kevin
ba8be9489e
public/js: upgrade jQuery to 3.6.0 ( #6550 )
...
Co-authored-by: ᴜɴᴋɴᴡᴏɴ <u@gogs.io >
2021-05-19 15:12:34 +08:00
Atin
d6987ee05b
chore: fix typos in code comments ( #6556 )
2021-05-19 13:12:09 +08:00
ᴜɴᴋɴᴡᴏɴ
3af91d7cfd
auth: decouple types and functions from db ( #6320 )
2020-09-20 11:19:02 +08:00
ᴜɴᴋɴᴡᴏɴ
7b295378e4
public: remove unused github.min.css ( #6119 )
2020-04-18 12:29:11 +08:00
alpencrossi
3e055e329c
repo: disable public access option when using external wiki and issue tracker ( #6081 )
2020-04-09 04:13:50 +08:00
ᴜɴᴋɴᴡᴏɴ
af0cfe112b
web: rename CSRF header ( #6027 )
2020-03-28 19:17:15 +08:00
imgbot[bot]
5bcf4292b6
[ImgBot] Optimize images ( #6005 )
...
*Total -- 13.23kb -> 10.21kb (22.85%)
/public/img/dingtalk.png -- 7.86kb -> 5.96kb (24.1%)
/public/img/slack.png -- 5.38kb -> 4.25kb (21.02%)
Signed-off-by: ImgBotApp <ImgBotHelp@gmail.com >
Co-authored-by: ImgBotApp <ImgBotHelp@gmail.com >
2020-03-22 22:36:59 +08:00
ᴜɴᴋɴᴡᴏɴ
22717a1c06
webhook: overhaul route handlers ( #6002 )
...
* Overual route handlers and fixes #5366
* Merge routes for repo and org
* Inject OrgRepoContext
* DRY validateWebhook
* DRY c.HasError
* Add tests
* Update CHANGELOG
2020-03-22 22:07:22 +08:00
ᴜɴᴋɴᴡᴏɴ
a43fc9ad17
ipynb: sanitize rendered HTML ( #5996 )
...
* ipynb: sanitize rendered HTML
Fixes #5170
* Remove hardcode URL
* Add tests
2020-03-21 00:12:38 +08:00
ᴜɴᴋɴᴡᴏɴ
328c23c5d4
public: make lessc compile minimize CSS ( #5987 )
2020-03-15 03:47:07 +08:00
ᴜɴᴋɴᴡᴏɴ
6437d0180b
git: migrate to github.com/gogs/git-module@v1.0.0 ( #5958 )
...
* WIP
* Finish `internal/db/git_diff.go`
* FInish internal/db/mirror.go
* Finish internal/db/pull.go
* Finish internal/db/release.go
* Finish internal/db/repo.go
* Finish internal/db/repo_branch.go
* Finish internal/db/repo_editor.go
* Finish internal/db/update.go
* Save my work
* Add license header
* Compile!
* Merge master
* Finish internal/cmd/hook.go
* Finish internal/conf/static.go
* Finish internal/context/repo.go
* Finish internal/db/action.go
* Finish internal/db/git_diff.go
* Fix submodule URL inferring
* Finish internal/db/mirror.go
* Updat to beta.4
* css: update fonts
* Finish internal/db/pull.go
* Finish internal/db/release.go
* Finish internal/db/repo_branch.go
* Finish internal/db/wiki.go
* gitutil: enhance infer submodule UR
* Finish internal/route/api/v1/repo/commits.go
* mirror: only collect branch commits after sync
* mirror: fix tag support
* Finish internal/db/repo.go
* Finish internal/db/repo_editor.go
* Finish internal/db/update.go
* Finish internal/gitutil/pull_request.go
* Make it compile
* Finish internal/route/repo/setting.go
* Finish internal/route/repo/branch.go
* Finish internal/route/api/v1/repo/file.go
* Finish internal/route/repo/download.go
* Finish internal/route/repo/editor.go
* Use helper
* Finish internal/route/repo/issue.go
* Finish internal/route/repo/pull.go
* Finish internal/route/repo/release.go
* Finish internal/route/repo/repo.go
* Finish internal/route/repo/wiki.go
* Finish internal/route/repo/commit.go
* Finish internal/route/repo/view.go
* Finish internal/gitutil/tag.go
* go.sum
2020-03-08 19:09:31 +08:00
ᴜɴᴋɴᴡᴏɴ
344b784d69
js: fix jQuery error
2020-02-29 23:52:35 +08:00
ᴜɴᴋɴᴡᴏɴ
333998509f
css: fix /admin/config pre overflow
2020-02-29 23:34:03 +08:00
guan
40214ef109
public: fix jquery3.x syntax error ( #5951 )
...
$.post().success -> $.post().done
2020-02-28 22:52:26 +08:00
imgbot[bot]
4f70ab8e27
[ImgBot] Optimize images ( #5943 )
...
*Total -- 115.45kb -> 73.67kb (36.19%)
/public/img/gogs-hero.png -- 58.29kb -> 34.18kb (41.37%)
/public/img/favicon.png -- 57.15kb -> 39.48kb (30.91%)
Signed-off-by: ImgBotApp <ImgBotHelp@gmail.com >
Co-authored-by: Imgbot <help@imgbot.net >
[CI SKIP]
2020-02-27 21:56:03 +08:00
ᴜɴᴋɴᴡᴏɴ
177806068d
public: update to new logo
2020-02-27 20:21:41 +08:00
ᴜɴᴋɴᴡᴏɴ
f2dc0d3115
css: add img margin-right
...
[CI SKIP]
2020-02-23 11:38:50 +08:00
ᴜɴᴋɴᴡᴏɴ
f59a68c531
README: update headline and preview
...
[CI SKIP]
2020-02-22 13:07:17 +08:00
ᴜɴᴋɴᴡᴏɴ
ea75f01ba2
admin: show all version in dashboard
...
And removed version info from footer.
2020-02-19 17:32:56 +08:00
Michael Li
4d83fd4238
Use go-bindata to embed public and templates files into binary ( #5920 )
...
* fixed private repositories are hidden in the organization's view
* use go-bindata integrate public and templates files to gogs binary
* optimize Dockerfile don't COPY public and templates files
* use kevinburke's go-bindata to generate assets code
* reset develepment as default run mode in configure file
* optimize generated assets code relayout and help function
* fixed code format
* Update conf/app.ini
* assets: add LICENSE headers
* Some housekeeping
* assets/public: simplify code logic
* assets/templates: simplify code logic
* cmd/web: more concise variable names
* Minor changes
* Add custom public and templates support back
Co-authored-by: ᴜɴᴋɴᴡᴏɴ <u@gogs.io >
2020-02-17 22:48:24 +08:00
imgbot[bot]
465be9b16e
[ImgBot] Optimize images ( #5913 )
...
*Total -- 2,264.72kb -> 2,093.92kb (7.54%)
/public/plugins/pdfjs-1.4.20/web/images/annotation-noicon.svg -- 0.15kb -> 0.08kb (46.84%)
/public/img/emoji/back.png -- 3.97kb -> 2.46kb (37.95%)
/public/img/gogs-large-resize.png -- 80.67kb -> 54.16kb (32.86%)
/public/plugins/pdfjs-1.4.20/web/images/annotation-note.svg -- 1.02kb -> 0.69kb (32.08%)
/public/img/404.png -- 8.43kb -> 5.94kb (29.47%)
/public/img/500.png -- 9.76kb -> 7.27kb (25.47%)
/public/img/favicon.png -- 28.47kb -> 21.58kb (24.21%)
/public/plugins/pdfjs-1.4.20/web/images/annotation-check.svg -- 0.41kb -> 0.31kb (23.37%)
/public/plugins/pdfjs-1.4.20/web/images/annotation-newparagraph.svg -- 0.42kb -> 0.32kb (23%)
/public/img/gogs.svg -- 14.66kb -> 11.34kb (22.66%)
/public/plugins/pdfjs-1.4.20/web/images/annotation-insert.svg -- 0.40kb -> 0.31kb (22.55%)
/public/img/gogs-lg.png -- 164.32kb -> 133.07kb (19.02%)
/public/img/dingtalk.png -- 30.02kb -> 24.91kb (17.02%)
/public/plugins/pdfjs-1.4.20/web/images/annotation-comment.svg -- 0.86kb -> 0.74kb (14.72%)
/public/img/avatar_default.png -- 502.04kb -> 442.97kb (11.77%)
/public/img/emoji/black_circle.png -- 2.31kb -> 2.07kb (10.68%)
/public/plugins/pdfjs-1.4.20/web/images/annotation-paragraph.svg -- 1.12kb -> 1.00kb (10.15%)
/public/plugins/pdfjs-1.4.20/web/images/annotation-help.svg -- 2.12kb -> 1.96kb (7.29%)
/public/plugins/pdfjs-1.4.20/web/images/annotation-key.svg -- 1.42kb -> 1.32kb (6.68%)
/public/assets/octicons-4.3.0/octicons.svg -- 43.89kb -> 41.59kb (5.23%)
/public/img/emoji/envelope.png -- 1.62kb -> 1.53kb (5.08%)
/public/css/themes/default/assets/fonts/icons.svg -- 381.68kb -> 369.58kb (3.17%)
/public/css/themes/default/assets/fonts/outline-icons.svg -- 104.69kb -> 101.59kb (2.96%)
/public/css/themes/default/assets/fonts/brand-icons.svg -- 495.73kb -> 487.61kb (1.64%)
/public/img/emoji/page_facing_up.png -- 2.13kb -> 2.09kb (1.56%)
/public/assets/font-awesome-4.6.3/fonts/fontawesome-webfont.svg -- 382.44kb -> 377.43kb (1.31%)
Signed-off-by: ImgBotApp <ImgBotHelp@gmail.com >
Co-authored-by: Imgbot <help@imgbot.net >
2020-02-01 06:35:59 +08:00
Unknwon
19ae04da66
public/plugins: upgrade highlight.js 9.16.2 to 9.18.0
2020-01-31 23:33:47 +08:00
Unknwon
2e00f00ab0
public/plugins: upgrade Dropzone 4.2.0 to 5.5.0
2020-01-31 23:27:56 +08:00
Unknwon
e99f43f59c
public/js: upgrade jQuery 1.12.4 to 3.4.1
2020-01-31 23:26:44 +08:00
Unknwon
2637931102
public: upgrade Semantic UI 2.3.1 to 2.4.2
2020-01-31 21:37:30 +08:00
Unknwon
54067d105b
public/js: upgrade clipboard 1.5.9 to 2.0.4
2020-01-31 21:21:30 +08:00
Unknwon
4c415aefed
public/js: upgrade jQuery 1.11.3 to 1.12.4
2020-01-31 21:20:47 +08:00
Johannes
7a0fbd0eb1
public: makes CodeMirror mode by filename lookups case-insensitive ( #5857 )
...
* updated the highlight.js plugin
* added some explicit mappings for syntax highlighting
* public: makes CodeMirror mode by filename extension lookup case-insensitive
2019-11-08 15:23:08 -08:00
Unknwon
53d30ccde9
templates: fix line wrap for very long commit message
2019-11-07 11:18:21 -08:00
johannes69ki
7d9f408d3a
public: update highlights.js to 9.16.2 ( #5856 )
...
* updated the highlight.js plugin
* added some explicit mappings for syntax highlighting
2019-11-07 10:43:01 -08:00
Unknwon
9ff2df78f0
public/css: make less ( #5317 )
2018-12-25 08:58:59 -05:00
Kyumyeong Han
74f26bb667
public/less: fix layout misalignment in Firefox for Linux ( #5317 )
...
* Update _repository.less
* Update _repository.less
2018-12-25 08:56:41 -05:00
haixunlu
311df9c521
auth: add new authentication source: GitHub, including GitHub Enterprise ( #5340 )
...
* Add new Authentication Source: GitHub, including GitHub Enterprise.
* Add vendor dependencies.
2018-12-18 15:49:30 -05:00
Unknwon
f545faa06d
templates: make state changing routes to POST method ( #5541 )
...
- pkg/context: add ParamsUser to unify the injection process
2018-12-06 22:58:02 -05:00
Unknwon
945a378e55
public/css: adjust width of label color in dropdown
...
models/issue: unify Issue receiver name to 'issue'
2018-12-02 17:54:55 -05:00
A.J. Ruckman
f4630f9044
public/css: add 'overflow-wrap: break-word' to dashboard news feeds ( #5507 )
2018-11-08 17:51:56 -05:00
Unknwon
f94dc67a43
librejs: add jQuery
...
[ci skip]
2018-09-19 13:24:49 -04:00
PiPc2
5d4bb4d6f8
librejs.html: fix semantic version ( #5404 )
...
currently incompatible with librejs
2018-09-06 20:16:21 -04:00
Unknwon
f6bdefe3f3
public: minor fix for PR #5276
2018-06-26 21:16:29 +08:00
Unknwon
376a629c9f
repo: add changes to repository avatar feature ( #5221 )
2018-06-17 22:18:41 +08:00
Sergey Dryabzhinsky
303fa37b60
repo: support avatars ( #5221 )
...
* First code for repository avatars
* Last code for repository avatars
- add new option for repo avatars location on filesystem
- add route catch in web
- add new fields to repo model
- add migration
- update settings handlers
- update repo header template
* Update locale messages
* Add repo avatars to home page
* Add repo avatars to organization right panel
* Show repo avatars in repo list
* Remove AvatarEamil field, remove Gravatar support, use generic locale messages
* Fix migration
* Fix seed and not used tool
* Revert public css changes, add them to less files
* Latest lessc (2.6.0) don't put result into file but output to stdout
So redirect output to file
* Simplify things:
- migration don't needed, and table changes too
- just upload file to repo avatar storage
- or generate random image
* Fix repo image seed - name not unique
* Get rid of not needed model fields
* Class value is enough, remove height attribute
* Don't generate random avatar for repository
- use html and semantic ui icons if no avatar found
* Update styles and templates for repo
- use repo icon as default avatar
- use globe icon for public repos
- add micro style for repo avatars at dashboard
* Remvoe redundant empty line
* Fix nl2br filter - must return string
* Fix css style for micro-repo-avatar in dashboard list
* Remove `|len`, works fine w/o it.
* Update after review 2:
- use static route for repository avatar
- format images settings block in settings
* Update after review 2:
- no random avatar for repo
* Update after review 2:
- no random avatar for repo 2
- update imports
- update UploadAvatar* functions
* Update after review 2:
- update templates
* Fix trace call
* Remove unused immport since we use static route for repo avatars.
2018-06-17 20:21:52 +08:00