Skip to content

Can't change commenttype for comment plugin #29

Open

Description

@nnsite

Hi,
I can't seem to change the comment type for the comment plugin.
Here's my settings.json:

{
    "colorscheme": "simple",
    "cursorline": false,
    "divchars": "true",
    "hlsearch": true,
    "softwrap": true,
    "wordwrap": true,
}
{
    "*.adb" {
        "commenttype": "-- %s"
    }
}

I tried with

{
    "colorscheme": "simple",
    "cursorline": false,
    "divchars": "true",
    "hlsearch": true,
    "softwrap": true,
    "wordwrap": true,
    "*.adb" {
        "commenttype": "-- %s"
    }
}

and it doesn't work either. Same "#".
I get "Error reading settings.json: invalid character '{' after top-level value" or "Error reading settings.json: invalid character '"' after top-level value".

Activity

  1. niten94 commented on Aug 6, 2024

    @niten94

    All options in settings.json are in the root JSON object starting at { at beginning of file and ending in }, so settings.json cannot be written like this:

    {
        "softwrap": true
    }
    {
        "wordwrap": true
    }

    There was an error with { being invalid character when reading settings.json because colon (:) has to be inserted between "*.adb" and {. Colon is inserted between key ("*.adb") and value ({ ... }) like this:

    {
        "colorscheme": "simple",
        "cursorline": false,
        "divchars": "true",
        "hlsearch": true,
        "softwrap": true,
        "wordwrap": true,
        "*.adb": {
            "commenttype": "-- %s"
        }
    }

    This repository only contains the code of the website but the code of micro is at https://github.com/zyedidia/micro, so please open issues related with micro there instead.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions