Git Product home page Git Product logo

Comments (2)

shey-kail avatar shey-kail commented on June 18, 2024 1

hello, do you solve this. I got the same problem. I need your help😭

from iron.nvim.

VictorLemosR avatar VictorLemosR commented on June 18, 2024

For future reference, he had 'repl_open_cmd' variable twice and only the first one matters. So delete the second one and change the first one accordingly. For a windows split, for example: repl_open_cmd = view.split("35%").

Here is my iron config in case it helps:

local iron = require("iron.core")
local view = require("iron.view")
local remaps_plugins = require("victor.hotkeys_plugins")
KEYS = remaps_plugins.iron

iron.setup {
    config = {
        -- Whether a repl should be discarded or not
        scratch_repl = true,
        -- Your repl definitions come here
        repl_definition = {
            sh = {
                -- Can be a table or a function that
                -- returns a table (see below)
                command = {"zsh"}
            }
        },
        -- How the repl window will be displayed
        -- See below for more information
    --    repl_open_cmd = require('iron.view').bottom(40),
        repl_open_cmd = "vertical botright 70 split"
    },
    -- Iron doesn't set keymaps by default anymore.
    -- You can set them here or manually add keymaps to the functions in iron.core
    keymaps = {
        send_motion = KEYS.send_motion,
        visual_send = KEYS.visual_send,
        send_file = KEYS.send_file,
        send_line = KEYS.send_line,
        send_until_cursor = KEYS.send_until_cursor,
--        send_mark = KEYS.send_mark,
--        mark_motion = KEYS.mark_motion,
--        mark_visual = KEYS.mark_visual,
--        remove_mark = KEYS.remove_mark,
        cr = KEYS.cr,
        interrupt = KEYS.interrupt,
        exit = KEYS.exit,
        clear = KEYS.clear,
    },
    -- If the highlight is on, you can change how it looks
    -- For the available options, check nvim_set_hl
    highlight = {
        italic = true
    },
    ignore_blank_lines = true, -- ignore blank lines when sending visual select lines
    -- One can always use the default commands from vim directly
}
-- iron also has a list of commands, see :h iron-commands for all available commands
vim.keymap.set('n', KEYS.open_iron_repl, '<cmd>IronRepl<cr>')
vim.keymap.set('n', KEYS.restart_iron_repl, '<cmd>IronRestart<cr>')
-- vim.keymap.set('n', '<space>rf', '<cmd>IronFocus<cr>')
-- vim.keymap.set('n', '<space>rh', '<cmd>IronHide<cr>')

from iron.nvim.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.