0
0
Fork 0
mirror of https://github.com/go-gitea/gitea synced 2024-12-25 22:04:32 +01:00
gitea/modules
Jason Song d9f748a700
Support asciicast files as new markup (#22448)
Support [asciicast
files](https://github.com/asciinema/asciinema/blob/develop/doc/asciicast-v2.md)
as a new markup via
[asciinema-player](https://github.com/asciinema/asciinema-player). For
more on asciinema, see the [introduction](https://asciinema.org/).

So users can use asciinema recorder to generate an asciicast file (or
you can download a sample file from
https://asciinema.org/a/335480.cast?dl=1), then upload it to Gitea and
play it on Gitea.

Snapshots:
<details>

## Upload asciicast files

<img width="1134" alt="image"
src="https://user-images.githubusercontent.com/9418365/212461061-cc2c7181-0e14-4534-af55-1ec60a639fd1.png">

## Open an asciicast file

<img width="1137" alt="image"
src="https://user-images.githubusercontent.com/9418365/212461090-a3b5141f-4894-430d-a2b4-ea257801a0ed.png">

## Play it

<img width="1144" alt="image"
src="https://user-images.githubusercontent.com/9418365/212461157-4e82db69-0e41-471d-928f-ac1fe0737105.png">

## Copy contents from the "video"

<img width="1145" alt="image"
src="https://user-images.githubusercontent.com/9418365/212461286-211612bc-15d6-427a-89a9-6abff5c6a0a5.png">


## View the source

<img width="1140" alt="image"
src="https://user-images.githubusercontent.com/9418365/212461187-05473b2d-ba3d-4072-84a6-4aa1e7d82182.png">


</details>

Known issue:

Don't support the [v1 version asciicast
files](https://github.com/asciinema/asciinema/blob/develop/doc/asciicast-v1.md),
it's a poorly designed version, it does not specify the file extension
and uses `*.json` usually, so it's impossible to recognize the files.

Co-authored-by: silverwind <me@silverwind.io>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
2023-01-18 08:46:58 +08:00
..
activitypub
analyze
auth Replace deprecated Webauthn library (#22400) 2023-01-11 21:51:00 -05:00
avatar Unify hashing for avatar (#22289) 2023-01-02 22:46:39 +01:00
base
cache Fix get system setting bug when enabled redis cache (#22295) 2023-01-02 00:06:52 +08:00
charset
container
context Supports wildcard protected branch (#20825) 2023-01-16 16:00:22 +08:00
csv
doctor Add cron method to gc LFS MetaObjects (#22385) 2023-01-16 13:50:53 -06:00
emoji Fix unstable emoji sort (#22346) 2023-01-05 13:58:51 +02:00
eventsource
generate
git Use git command instead of exec.Cmd in blame (#22098) 2023-01-03 16:17:13 +08:00
gitgraph
graceful
hcaptcha
highlight
hostmatcher
html
httpcache
httplib
indexer
issue/template
json
lfs
log Change use of Walk to WalkDir to improve disk performance (#22462) 2023-01-16 16:21:44 +00:00
markup Support asciicast files as new markup (#22448) 2023-01-18 08:46:58 +08:00
mcaptcha
metrics
migration
mirror
nosql
notification Always reuse transaction (#22362) 2023-01-08 09:34:58 +08:00
options
packages Use ErrInvalidArgument in packages (#22268) 2022-12-31 12:49:37 +01:00
paginator
password Implement FSFE REUSE for golang files (#21840) 2022-11-27 18:20:29 +00:00
pprof
private
process
proxy
proxyprotocol
public
queue
recaptcha
references
regexplru
repository Change use of Walk to WalkDir to improve disk performance (#22462) 2023-01-16 16:21:44 +00:00
secret
session
setting Add support for incoming emails (#22056) 2023-01-14 23:57:10 +08:00
sitemap
ssh
storage Change use of Walk to WalkDir to improve disk performance (#22462) 2023-01-16 16:21:44 +00:00
structs Supports wildcard protected branch (#20825) 2023-01-16 16:00:22 +08:00
svg
sync
system
templates Display error log when a modified template has an error so that it could recovery when the error fixed (#22261) 2023-01-03 15:17:36 +08:00
test
timeutil
translation
typesniffer
updatechecker
upload
uri
user
util Add support for incoming emails (#22056) 2023-01-14 23:57:10 +08:00
validation
watcher
web
webhook Restructure webhook module (#22256) 2023-01-01 23:23:15 +08:00