Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revision | |||
playground:playground [2019/06/23 20:54] – Docker-compose filetype janax | playground:playground [2020/05/01 10:44] (current) – external edit 127.0.0.1 | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | ==== Dockerfile and docker-compose Filetype | + | ====== PlayGround ====== |
- | **Dockerfile** | + | |
- | **docker-compose.yml** is a file format to build and run multiple Docker containers; using [[https:// | + | |
- | [[http:// | ||
- | |||
- | This page describe how to add basic Dockerfile syntax highlighting on Geany. | ||
- | In addition, it adds docker-compose syntax highlighting. | ||
- | |||
- | ===== Step 1) ===== | ||
- | |||
- | Add the following lines to // | ||
- | <file properties> | ||
- | [Extensions] | ||
- | Dockerfile=Dockerfile; | ||
- | YML=*.yaml; | ||
- | [Groups] | ||
- | Script=Dockerfile; | ||
- | Misc=YML; | ||
- | </ | ||
- | |||
- | |||
- | ===== Step 2) ===== | ||
- | |||
- | Save the configuration file below in your Geany filetype definition files config directory, e.g. // | ||
- | |||
- | <file properties filetypes.Dockerfile.conf> | ||
- | # For complete documentation of this file, please see Geany' | ||
- | # | ||
- | # Geany Color Syntax support for Dockerfiles | ||
- | # | ||
- | # version 0.2 | ||
- | # | ||
- | # 0.1 - original version | ||
- | # 0.2 - base on Sh instead - fixes problems with //, #, /* | ||
- | |||
- | [styling=C] | ||
- | |||
- | [keywords] | ||
- | primary= ADD ARG CMD COPY ENTRYPOINT ENV EXPOSE FROM HEALTHCHECK LABEL ONBUILD RUN SHELL STOPSIGNAL USER VOLUME WORKDIR build container_name context command default depends_on dns dockerfile entrypoint environment env_file expose external extra_hosts external_links file hostname image labels links name network ports service services volumes web devices | ||
- | |||
- | [lexer_properties=C] | ||
- | |||
- | [settings] | ||
- | lexer_filetype=Sh | ||
- | tag_parser=C | ||
- | extension= | ||
- | # single comments, like # in this file | ||
- | comment_single=# | ||
- | |||
- | # set to false if a comment character/ | ||
- | # indentation of the line, e.g. setting to true causes the following on pressing CTRL+d | ||
- | # | ||
- | # setting to false would generate this | ||
- | # | ||
- | # This setting works only for single line comments | ||
- | comment_use_indent=true | ||
- | # context action command (please see Geany' | ||
- | context_action_cmd=xdg-open " | ||
- | |||
- | </ | ||
- | |||
- | |||
- | ===== Step 3) ===== | ||
- | |||
- | Save the configuration file below in your Geany filetype definition files config directory, e.g. // | ||
- | |||
- | <file properties filetypes.YML.conf> | ||
- | # For complete documentation of this file, please see Geany' | ||
- | [styling] | ||
- | # Edit these in the colorscheme .conf file instead | ||
- | default=default | ||
- | comment=comment | ||
- | identifier=identifier | ||
- | keyword=keyword_1 | ||
- | number=number_1 | ||
- | reference=function | ||
- | document=preprocessor | ||
- | text=string_1 | ||
- | error=error | ||
- | operator=operator | ||
- | |||
- | [keywords] | ||
- | # all items must be in one line | ||
- | keywords= true false yes no | ||
- | |||
- | |||
- | [settings] | ||
- | lexer_filetype=YAML | ||
- | # default extension used when saving files | ||
- | extension=yaml | ||
- | |||
- | # MIME type | ||
- | mime_type=application/ | ||
- | |||
- | # the following characters are these which a " | ||
- | # | ||
- | |||
- | # single comments, like # in this file | ||
- | comment_single=# | ||
- | # multiline comments | ||
- | # | ||
- | # | ||
- | |||
- | # set to false if a comment character/ | ||
- | # indentation of the line, e.g. setting to true causes the following on pressing CTRL+d | ||
- | # | ||
- | # setting to false would generate this | ||
- | # | ||
- | # This setting works only for single line comments | ||
- | comment_use_indent=true | ||
- | |||
- | # context action command (please see Geany' | ||
- | context_action_cmd= | ||
- | |||
- | [indentation] | ||
- | #width=4 | ||
- | # 0 is spaces, 1 is tabs, 2 is tab & spaces | ||
- | #type=1 | ||
- | |||
- | </ | ||
- | |||
- | |||
- | ===== Step 4) ===== | ||
- | |||
- | Enable docker-compose syntax highlighting, | ||
- | |||
- | |||
- | Comment out row starting with YAML in global " | ||
- | '' | ||
- | to : # | ||
- | |||
- | |||
- | {{tag> |