Code Monkey home page Code Monkey logo

tym's People

Contributors

bladecoates avatar capezotte avatar endaaman avatar eriklundstedt avatar itakeshi avatar js-everts avatar noscript avatar r3lgar avatar thalting avatar thebearodactyl avatar tomet avatar wesleyjrz avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

tym's Issues

Possibility to read output?

Is there a way to read the terminal output in a Lua event hook? I'd like to pass some send_key based on output shown in the terminal.

Is that possible?

Dynamic title

Almost all application changes the window title. It would be great to have at least as optional option.

Change window title?

Hello,

not sure if this is covered somewhere and I'm missing it. How can I change the tym window title after it's been invoked? I know how to change it at startup time but how can I do it from within the terminal itself?

Send key API

For examle, you can write like following to make '<Ctrl><Shift>h act as <Ctrl><Shift>Left

tym.set_keymap('<Ctrl><Shift>h', function()
  tym.send_key('<Ctrl><Shift>Left')
end)

Command line option

$ tym -h

or

$ tym --help

to show help and

$ tym --version

to show version.

acceralator or accelerator?

Hi,

I see you are using the word "acceralator" in both documentation and code.

Is this a misspelling of "accelerator"? I didn't want to make a pull request as I'm not sure if that's a misspelling or not.

Features of version 2

Things to have on tym version 2.0 and need some discussions

  • Better configuration
  • Easy theming #6

Automatic copy of selection?

Hello,

Is it somehow possible to perform automatic copy to clipboard when I select text on the terminal via my mouse?

Is this a terminal feature or totally unrelated? If it's the former, then this might be a very good addition to this software.

Invalid color string for 'color_*'…

tym from git/master.

STDERR:

 % tym
** Message: 17:05:37.136: Invalid color string for 'color_0': #131517
** Message: 17:05:37.136: Invalid color string for 'color_1': #b14c4e
** Message: 17:05:37.136: Invalid color string for 'color_2': #13a24c
** Message: 17:05:37.136: Invalid color string for 'color_3': #b19336
** Message: 17:05:37.136: Invalid color string for 'color_4': #3868bd
** Message: 17:05:37.136: Invalid color string for 'color_5': #8c1db4
** Message: 17:05:37.136: Invalid color string for 'color_6': #3293b4
** Message: 17:05:37.136: Invalid color string for 'color_7': #b9bbbd
** Message: 17:05:37.136: Invalid color string for 'color_8': #000000
** Message: 17:05:37.136: Invalid color string for 'color_9': #f25555
** Message: 17:05:37.136: Invalid color string for 'color_10': #00d952
** Message: 17:05:37.136: Invalid color string for 'color_11': #f2c130
** Message: 17:05:37.136: Invalid color string for 'color_12': #3880ff
** Message: 17:05:37.136: Invalid color string for 'color_13': #b90cf2
** Message: 17:05:37.136: Invalid color string for 'color_14': #30c1f2
** Message: 17:05:37.136: Invalid color string for 'color_15': #ffffff

theme.lua:

local bg = "#373c41"

return {
	color_foreground = "#b9bbbd",
	color_bold = "#ffffff",
	color_cursor = "#ffffff",
	color_cursor_foreground = "#373c41",
	color_highlight = "#37465e",
	color_highlight_foreground = "#b9bbbd",
	color_background = bg,
	color_0 = "#131517",
	color_8 = "#000000",
	color_1 = "#b14c4e",
	color_9 = "#f25555",
	color_2 = "#13a24c",
	color_10 = "#00d952",
	color_3 = "#b19336",
	color_11 = "#f2c130",
	color_4 = "#3868bd",
	color_12 = "#3880ff",
	color_5 = "#8c1db4",
	color_13 = "#b90cf2",
	color_6 = "#3293b4",
	color_14 = "#30c1f2",
	color_7 = "#b9bbbd",
	color_15 = "#ffffff",
}

What's wrong?

Improve URL regex

As in #44 (comment), parenthesis handling in URL regex should be improved.
If we have markdown link like [link](https://example.com), currently the regex matches https://example.com), but clearly it should be https://example.com.

Specify config file to load

Spec

Use -u like Vim.

$ tym -u '/path/to/config.lua'

If NONE provided, start with default config.

$ tym -u NONE

If file provided does not exist, print warning log and start with default config.

Add setTimeout API

DRAFT1

local counter = 0
tym.set_timeout(function()
  counter = counter + 1
  if couter < 4 then
    tym.notify('periodic')
    return 2000
  else
    tym.notify('done')
  end
end, 1000)
(1000ms wait)
↓
notify 'periodic'
↓
(2000ms wait)
↓
notify 'periodic'
↓
(2000 wait)
↓
notify 'periodic'
↓
(2000 wait)
↓
notify 'done'

Window urgency on audible bell

When we get an audible bell (echo "\a") in non-focused window, it doesn't marked as urgent in window manager, so we don't know what window needs our attention. It helpful with e.g. TUI messengers (weechat, irssi, poezio, profanity, mcabber).

Add config option to disable bell

I want to disable audible bell through config, like:

tym.set_config({
    audible_bell = false,
})

Also, it should be independent from "urgent on bell" functionality #21 (i.e. I want to disable bell sound but the window should become urgent if a bell character is issued)

Initial geometry

make initial geometry configurable.

config.lua spec:

config.width = 80
config.height = 22

tym.send_key('<Ctrl>m') not working?

Can someone provide any ideas why this is not working
tym.send_key('< Ctrl >m')
while
tym.send_key('KP_Enter')
works fine?

Is there something that prohibits the CTRL-M? Works fine if I manually send it, etc. I'm confused since I think it used to work in some of my initial tests.

Any feedback welcome!

Hide mouse cursor

(on keypress or on timeout?)

It is necessary in those cases when you read or write text. If user use focus follows mouse, it is very useful.

Padding

First off thanks for writing this, it's brilliant!

It's made my life so much easier keeping configs in sync with Awesome and Luakit. Managing configs has been a dream!

I was wondering how hard it would be to implement padding around all 4 edges of the terminal. I may submit a pull request myself for this but I'm not very experienced with C programming (plenty of experience in other languages though.) If you point me in the right direction I might be able to hack it together in the next few days and submit a PR.

Thanks again!

Tim

theme.lua colors

Perhaps in the documentation we should offer sample xterm 256 colors?

From https://jonasjacek.github.io/colors/

local bg = '#000000'
return {
  color_background = bg,
  color_foreground = fg,
  color_0  = '#000000',
  color_1  = '#800000',
  color_2  = '#008000',
  color_3  = '#808000',
  color_4  = '#000080',
  color_5  = '#800080',
  color_6  = '#008080',
  color_7  = '#c0c0c0',
  color_8  = '#808080',
  color_9  = '#ff0000',
  color_10  = '#00ff00',
  color_11  = '#ffff00',
  color_12  = '#0000ff',
  color_13  = '#ff00ff',
  color_14  = '#00ffff',
  color_15  = '#ffffff',
}

The master HEAD has changes compared to previous versions and the default colours have changed. Might be useful to provide the above as a default sample in the README.md

This link might be useful as well for visual customization of the theme: https://terminal.sexy/

Slow startup

Hi,
I noticed, that tym startups are slow (and maybe getting gradually slower?)
Here is comparison with urxvt:

# time urxvt -e "bash -c exit"                                                                                                                                                                                                      2019-08-18T11:20:42 CEST
0.03user 0.01system 0:00.04elapsed 95%CPU (0avgtext+0avgdata 13424maxresident)k
0inputs+0outputs (0major+1055minor)pagefaults 0swaps

# time tym -e "bash -c exit"                                                                                                                                                                                                        2019-08-18T11:20:47 CEST
0.18user 0.05system 0:00.25elapsed 91%CPU (0avgtext+0avgdata 40592maxresident)k
1824inputs+0outputs (5major+4956minor)pagefaults 0swaps

200 ms might be ok for some users, but I spawn terminals in tiling wm (i3) pretty often. Slow startup causes, that tym misses several keystrokes when start typing immediately after launching tym (with kb shortcut).

Using Arch Linux, tym version 2.2.1.

EDIT:

under heavy CPU load:

# time tym -e "bash -c exit"                                                                                                                                                                                                        2019-08-18T12:04:34 CEST
0.36user 0.05system 0:00.50elapsed 84%CPU (0avgtext+0avgdata 40948maxresident)k
0inputs+0outputs (0major+4970minor)pagefaults 0swaps

# time urxvt -e "bash -c exit"                                                                                                                                                                                              506ms  2019-08-18T12:04:37 CEST
0.04user 0.01system 0:00.06elapsed 88%CPU (0avgtext+0avgdata 13448maxresident)k
0inputs+0outputs (0major+1009minor)pagefaults 0swaps

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.