hare

hare
demote

Move a definition one level down

Example:

{
    "params": {
        "start_pos": {
            "line": 42.0,
            "col": 23.0
        },
        "file": {
            "file": "a file name"
        }
    },
    "cmd": "hare:demote"
}
dupdef

Duplicate a definition

Example:

{
    "params": {
        "name": {
            "text": "the new name"
        },
        "start_pos": {
            "line": 42.0,
            "col": 23.0
        },
        "file": {
            "file": "a file name"
        }
    },
    "cmd": "hare:dupdef"
}
iftocase

Converts an if statement to a case statement

Example:

{
    "params": {
        "end_pos": {
            "line": 42.0,
            "col": 23.0
        },
        "start_pos": {
            "line": 42.0,
            "col": 23.0
        },
        "file": {
            "file": "a file name"
        }
    },
    "cmd": "hare:iftocase"
}
liftonelevel

Move a definition one level up from where it is now

Example:

{
    "params": {
        "start_pos": {
            "line": 42.0,
            "col": 23.0
        },
        "file": {
            "file": "a file name"
        }
    },
    "cmd": "hare:liftonelevel"
}
lifttotoplevel

Move a definition to the top level from where it is now

Example:

{
    "params": {
        "start_pos": {
            "line": 42.0,
            "col": 23.0
        },
        "file": {
            "file": "a file name"
        }
    },
    "cmd": "hare:lifttotoplevel"
}
rename

rename a variable or type

Example:

{
    "params": {
        "name": {
            "text": "the new name"
        },
        "start_pos": {
            "line": 42.0,
            "col": 23.0
        },
        "file": {
            "file": "a file name"
        }
    },
    "cmd": "hare:rename"
}