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

Teach fetch() to work with binary files #104

Closed
wincent opened this issue Jun 23, 2021 · 0 comments
Closed

Teach fetch() to work with binary files #104

wincent opened this issue Jun 23, 2021 · 0 comments
Labels

Comments

@wincent
Copy link
Owner

wincent commented Jun 23, 2021

Quoting c07a1ed:

fix(vim): fetch with curl instead of fetch()

Because I discovered a shameful bug in fetch(); instead of downloading the binary data, it is passing through UTF-8 string encoding at various points, totally breaking it...

For example, byte sizes:

  • es.utf-8.spl downloaded by wget: 601018
  • es.utf-8.spl downloaded by nvim: 601019 (spellfile.vim appends a newline).
  • es.utf-8.spl downloaded by fetch(): 721706 (ugh)

I'll fix the bug/limitation later, but for now just working around it.

@wincent wincent added the fig label Jul 10, 2021
wincent added a commit that referenced this issue Aug 31, 2021
Motivation; get this fix:

    L3MON4D3/LuaSnip#142

But it turns out that there have been a _lot_ of changes since I last
updated; if anything breaks, I will follow up:

* aspects/nvim/files/.config/nvim/pack/bundle/opt/LuaSnip 72323c1...9a8cf5f (261):
  > Merge pull request #143 from leiserfg/multi-ft
  > Format with stylua
  > fix: account for compound filetypes (closes #142).
  > Update README.md
  > Format with stylua
  > Fix parser, for real now.
  > Format with stylua
  > Fix slight regression with variables in lsp-parsed snippets.
  > Fixup(d2aa43c): BREAKING, parsing has become more strict.
  > Format with stylua
  > Provide option to set better `assemble`-function for nested snippets.
  > Format with stylua
  > Merge branch 'master' of github.com:L3MON4D3/LuaSnip
  > lsp: correctly parse brackets (closes #141) and split iNode-text.
  > fix(parser): remove escape-chars everywhere.
  > Merge pull request #140 from carlitux/patch-2
  > Set pos to nil for better docstring if queried manually.
  > Format with stylua
  > Improve get_docstring().
  > Typo.
  > Format with stylua
  > Account for selecting empty lines (only) (closes #139).
  > Use `rawget` to get position.
  > Merge pull request #138 from leiserfg/handle_emtpy_snippets
  > Parser: ${n:sometext} can also be repetitions of previous insertNodes.
  > Try expanding autosnippets if pum is visible, too.
  > Format with stylua
  > Use tokenizer to create helper-snippet for regex-triggers.
  > Implement tokenizer for patterns.
  > Format with stylua
  > pcall `get_text`, {""} on error. Don't error on `str_utfindex`.
  > Try to prevent jump_from from erroring due to deleted snippets.
  > Auto generate docs
  > Format with stylua
  > Merge branch 'insert_node_event_callbacks'
  > Add <Plug>-mapping for previous choice (Closes #131).
  > Format with stylua
  > Provide setting for delete-check autocommands.
  > Recommend `InsertEnter` for `region_check_events`
  > Make bytecol_to_utfcol behave correctly (used to return three values).
  > Auto generate docs
  > Format with stylua
  > Small changes+improvements for the enter/leave events:
  > Auto generate docs
  > Rename AUTOCOMMANDS to EVENTS.
  > Auto generate docs
  > Format with stylua
  > No need to input_leave the generated snippet in dynamicNode.
  > Trigger autocommands on entering/leaving nodes.
  > Add function to check if the current snippet was deleted+<Plug>-mapping.
  > Merge pull request #126 from leiserfg/generic-package-name
  > Auto generate docs
  > Format with stylua
  > Document indent_snippet_node and some usages for it.
  > Remove prefix_snippet_node, it's really just a specification of ISN.
  > Re-implement changing choice backwards.
  > Prevent region check for autotriggered snippets too.
  > Each choice gets a pointer to the next.
  > Rename choiceNode.inner to choiceNode.active_choice, more expressive.
  > Clear snippets' own marks on exit.
  > Rename vars that store choiceNodes to reflect that.
  > Format with stylua
  > Disable region check while jumping.
  > Make sure node isn't nil before indexing.
  > Check for specific node+also check following snippets.
  > Leave exit node when next snippet is expanded, only compare lines for region.
  > Mention setting in README.
  > Add config for specifying when to do region check, defaults to never.
  > Fix minor bugs with exit_out_of_region_snippet.
  > Fix small issues with exitNode.
  > Fix bug caused by new jump_from/into-behaviour.
  > Add function to leave active snippet if its' region is left.
  > Make no_move actually funcitional.
  > Add snippet.snippet, contains 'outer' (ie. the user-triggered) snippet.
  > Have jump_into/jump_leave return the new active node.
  > Merge pull request #124 from leiserfg/clean_lazy
  > Auto generate docs
  > Fix lazy-loading.
  > Add more details for loading vscode-packaged snippets.
  > Format with stylua
  > Fix/improve update_dependents-behaviour.
  > Clean up a bit.
  > Reset active upon exit()ing, only pop active choice if this was active.
  > Simplify choiceNodes' init-process.
  > Merge pull request #121 from L3MON4D3/static_text_for_snippets
  > Ignore and correctly format lines on which stylua fails.
  > Format with stylua
  > Fix regression: *move_on_mark_*-functions were removed, typo(?) in util.mark.
  > Format with stylua
  > Remove print's.
  > Changes nothing functionally, but clearer.
  > After parsing, the positions of insertNodes are not 'dense', fix it.
  > Inserting a missing `i(0)` is handled by snippet-constructor.
  > Auto generate docs
  > Format with stylua
  > Document expected layout of directories loaded via vscode-loader.
  > Format with stylua
  > Separate expanding tabs in text and indenting; make both more generic.
  > Fix expand_tab-implementation.
  > Always initialize static_text for insert and textNode.
  > Format with stylua
  > Fix unlink_current, correctly set active node.
  > Set Luasnip_active_choice correctly after exit()ing choiceNode.
  > Format with stylua
  > Merge pull request #114 from leiserfg/extra-vars
  > Format with stylua
  > Differentiate between insert and exitNodes(`i(0)`).
  > Call insertNodes' input_leave function for i(0).
  > Auto generate docs
  > Format with stylua
  > Document new behaviour of i(0).
  > Format with stylua
  > Do insertNodes' input_enter for i(0).
  > Fix TM_LINE_INDEX/NUMBER, it should be a string.
  > Format with stylua
  > Explicitly open folds after moving, doesn't seem to happen automatically.
  > Auto generate docs
  > Format with stylua
  > Mention passive extending active and highlight groups in doc.
  > Fix overriding-behaviour.
  > Fix clear_invalid, don't have it override active with passive.
  > Use user-defined Luasnip*Node{Active,Passive} as highlight when defined.
  > Merge default into user-defined table.
  > Format with stylua
  > Replace link to matrix room with icon.
  > Format with stylua
  > Clarify arguments to util.put.
  > Use byte-position of mark to nvim_buf_set_text().
  > Expose function to get byte-position of mark.
  > Format with stylua
  > Default ext_opts-table to {}.
  > Auto generate docs
  > Format with stylua
  > Add example for ext_opts, fix jdoc-snippet.
  > Rename prio_increase to ext_prio_increase.
  > Add documentation for ext_opts.
  > Correctly pass ext_opts with higher prios for inner snippets.
  > Config: include priority+functions to modify.
  > Add appropriate exit()-functions to dynamic and choice.
  > Use copy of passed table.
  > Fix dynNode:set_rgrav, after changing textNode, grav is default-false.
  > Fill missing values in ext_opts.
  > Don't unnecessarily update extmark.
  > Change ext_opts on entering/leaving.
  > Correctly set type and opts for snippet.
  > Rename change_rgravs to update_rgravs.
  > DO change gravities for textNodes, prevents some bug+more uniform.
  > Enter node in both paths.
  > Delete marks on exit.
  > Use two functions to set gravs or other opts.
  > Set snippets' mark from outside also.
  > Format with stylua
  > Mention nvim-cmp and cmp_luasnip in README.
  > Format with stylua
  > Merge pull request #106 from amenonsen/patch-3
  > Format with stylua
  > Merge pull request #105 from amenonsen/patch2
  > Format with stylua
  > Yeeeeeaaaaah no, not really anymore
  > Format with stylua
  > Mention autosnippets in README.
  > Format with stylua
  > Merge branch 'autotrigger'
  > Format with stylua
  > Fix: Adding a i(0) if none was specified.
  > Don't set correctly and then overwrite with old values :/
  > As the mark-id isn't copied anymore, it can be set later in put_initial()
  > Implement clear-function, fix bug with raw_pos.
  > Print gravities in snippet:dump().
  > Store ext_opts in snippet, pass to children; Change marks for dyn/choice
  > Add ext_opts to config.
  > Use raw, not utf-adjusted position for initializing extmarks.
  > Don't set positions in opts.
  > Default-init marks with nil.
  > Fix set_mark_rgrav-function, use default-version everywhere.
  > Actually use new marks in snippets.
  > Most likely, there won't be any updates to pos, and if, then to both.
  > Marks are objects; Simplify extmark_rgrav-setting.
  > Add table for node-names, shift indices to match name.
  > Refactor types to use enum.
  > Auto generate docs
  > Mention mappings in DOC, refer to README.
  > Auto generate docs
  > Merge pull request #104 from amenonsen/patch-1
  > Mention new config-option in README.
  > Auto generate docs
  > Document SELECT-behaviour and lsp-parsing.
  > Provide example mappings for lua and vimscript.
  > Link to lsp-snippet spec.
  > Format with stylua
  > Only remove indent for TM_SELECTED_TEXT.
  > Enable new vars in env.
  > Correctly populate selection.
  > Create all types of indent in store_selection().
  > Modify store_selection to get all lines at once.
  > Allow node.pos to be nil, mimic vscodes' behaviour for $TM_SELECTED_TEXT.
  > Should be an insertNode.
  > Add new snippetNodes prefixSnippetNode and indentSnippetNode
  > Refactor population of args for function/dynamicNodes.
  > Improve autowrapping for snippets, fix it for snippetNodes.
  > Merge pull request #102 from leiserfg/find_vimrc
  > Auto generate docs
  > Specify what the text looks like when executing condition-function.
  > Auto generate docs
  > Maybe also document condition-function.
  > Format with stylua
  > Change snippet:match(...) for regex-triggers, parentheses can mess up patterns.
  > Reuse mark-id if possible.
  > Refactor snippet:indent() slightly.
  > Clean up unneeded args.
  > Indent + populate snippetNodes' env in put_initial().
  > Auto generate docs
  > Format with stylua
  > Explicitly mention text-passing behaviour in docs.
  > BREAKING CHANGE: Pass dedented text to function/dynamicNodes, indent returned text for functionNodes.
  > Merge pull request #94 from leiserfg/fix-of-by-one
  > Merge pull request #93 from leiserfg/use-named-register
  > Format with stylua
  > Reset Visual after use.
  > Return {} instead of "" on empty visual.
  > Prepare for storing prio,hl_group,... in node.mark.
  > Format with stylua
  > Correctly check for empty table ({} != {} in lua);
  > Rewrite extmarks to work more consistently.
  > Update parsed nodes.
  > Fix node-gravities for exitNodes'.
  > Remove prints', fix enter_node.
  > Use only one node to mark beginning and end of node.
  > Merge pull request #92 from leiserfg/select
  > If lambda returns nil, use default of "" to prevent errors.
  > Format with stylua
  > Add dynamic lambdas+examples.
  > Format with stylua
  > Add nonempty-node. Inserts text if arg-node is not empty.
  > Add some examples for `match()`.
  > Adjust default-value for `match()`
  > Merge pull request #86 from leiserfg/match_with_lambda
  > BREAKING CHANGE: Move pseudo-nodes from ls.util.functions to ls.extras.
  > Quickly shuffle around signature of `match()`.
  > Merge pull request #84 from leiserfg/match_with_lambda
  > Auto generate docs
  > Merge pull request #83 from praveendhawan/patch-1
  > Auto generate docs
  > Format with stylua
  > BREAKING CHANGE: Default `wordTrig` to true, not false.
  > Add expand and expandable function+vim-versions (close #79).
  > Luasnip_current_nodes may (somehow) be nil, check before indexing.
  > Format with stylua
  > Add partial function+example (closes #72).
  > Auto generate docs
  > Replace table with list, md2vim doesn't like tables.
  > Auto generate docs
  > Fix table in Doc.
  > Merge pull request #69 from leiserfg/md-doc
  > Alias set_config to setup.
  > Merge pull request #29 from tjdevries/update_config_correctly
  > Initialize function+dynamicNodes when cildren of choiceNode.
  > Format with stylua
  > Add Examples for recently added nodes.
  > Repeat doesn't need lambdas.
  > Merge pull request #67 from leiserfg/lambda-util
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant