aboutsummaryrefslogtreecommitdiffstats
path: root/README.org
blob: af26905f4d77600de2666a2d0e9a20f351b8fd3a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
* Installing

  To use this repository execute the following commands in Emacs:

  #+begin_src emacs-lisp
    (add-to-list 'package-archives '("oni" . "https://ryuslash.org/elpa/"))
    (package-refresh-contents)
    (package-install 'oni-package)
  #+end_src

* Adding new configurations

  When you add a new configuration file, also add at least a test that it
  actually gets loaded:

  : tests/integration/oni-example-mode.bats

  #+begin_src bats
    #!/usr/bin/env bats

    @test "Opening a .example file loads oni-example-mode" {
        run emacs -batch -l package -f package-initialize \
            -visit test.example \
            -eval "(prin1 (featurep 'oni-example-mode))"

        echo "$output"

        [[ "$output" == "t" ]]
    }
  #+end_src

  And add the integration test in =.gitlab.yaml=:

  #+begin_src yaml
    integration-test-oni-example-mode:
      stage: integration-test
      image: registry.gitlab.com/ryuslash/emacs-config
      dependencies:
        - package
      script: make integration-test-oni-example-mode TEST_ARCHIVE=$(realpath bin/)
  #+end_src