Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add pragmas? #143

Open
JoshCheek opened this issue Oct 30, 2018 · 3 comments
Open

Add pragmas? #143

JoshCheek opened this issue Oct 30, 2018 · 3 comments

Comments

@JoshCheek
Copy link
Owner

Okay, the more I think about it, the more I want this. It would be like metacommands to SiB.

  • Then move snippets into here instead of requiring each editor to implement them.
  • Allow settings to be overridden so that you don't have to mess with configuration.
  • Allow snippets to be added by placing files in something like ~/.config/seeing_is_believing/snippets (other stuff that could go in that dir: server PID for faster running) although, I'd have to figure out what the equivalent is for Windows.

Examples of possible pragmas:

# SiB help
this would expand to a list of the pragmas

# SiB expand active_record
# SiB snippet active_record
these would expand to templated text

# SiB set alignment_strategy file
change a setting, possible on a per-chunk basis

# SiB argv --alignment-strategy file
alternative to the above, this would add / override line arguments
@JoshCheek
Copy link
Owner Author

JoshCheek commented Nov 3, 2018

  • Should also be able to override whether it uses xmpfilter style or not (eg then --clean would be useful, b/c it's dumb to need separate keybindings for clean with and without xmpfilter style)
  • Should be able to configure whether it runs over the top of the file it's in or in an unsaved file. Primarily because I basically never save the files I'm working on, but most other people seem to, but I think the saved experience isn't as good. (though if it immediately replaced the overwritten file, it would probably be a lot better, I think there's an issue for that)
  • Should have a pragma to tell it what dir you want it to run the file from (eg like the --local-cwd flag) I know things like that are as simple as Dir.chdir __dir__, but that's not obvious to everyone and it's not configurable.

@JoshCheek
Copy link
Owner Author

Hey, @ckib16 and @marlomajor, if either of y'all are interested in doing this with me, LMK ^_^ I'm not going to do it right now, but I'm pretty sure the next time I get a good break (probably sometime in the next few months) I'm going to do it.

If you're interested in joining me for part of it, we can screenshare. If you're comfortable with it, we can pair. If not, we can still screenshare and I can talk through whatever I'm thinking or why I'm making different decisions. Up to y'all. As soon as I realized I do want to do this, I figured it'd be a reasonable opportunity to invite someone along ^_^

@marlomajor
Copy link
Contributor

Next time we pair lets do it on this. I'm open to working on this with you @JoshCheek. Will ping you on twitter.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants