1. 11 12月, 2021 1 次提交
    • A
      Add separate function for VS Code arguments (#4599) · 9e583fa5
      Asher 提交于
      The problem before was that the pop() caused the open in existing
      instance functionality to break because the arguments no longer
      contained the file.
      
      We could simply remove the pop() but since `workspace` and `folder` are
      not CLI arguments I think it makes sense to handle them in a separate
      function which can be called at the point where they are needed.  This
      also lets us de-duplicate some logic since we create these arguments in
      two spots and lets us skip this logic when we do not need it.
      
      The pop() is still avoided because manipulating a passed-in object
      in-place seems like a risky move.  If we really need to do this we
      should copy the positional argument array instead.
      9e583fa5
  2. 10 12月, 2021 1 次提交
  3. 09 12月, 2021 1 次提交
    • A
      Fix relative paths (#4594) · 4b4ec378
      Asher 提交于
      * Add tests for relativeRoot
      
      * Remove path.posix.join
      
      Since this is for file system paths it feels incorrect to use it on
      URL paths as they are different in many ways.
      
      * Rewrite cookie path logic
      
      Before we relied on the client to resolve the base given to it by the
      backend against the path.
      
      Instead have the client pass that information along so we can resolve it
      on the backend.  This means the client has to do less work.
      
      * Do not remove out directory before watch
      
      This is re-used for incremental compilation.
      
      Also remove del since that was the only use (and we can use fs.rmdir in
      the future if we need something like this).
      
      * Remove unused function resolveBase
      4b4ec378
  4. 08 12月, 2021 3 次提交
    • A
      Fix spawning code-server within code-server (#4590) · 9d9f3a41
      Asher 提交于
      * Remove extra VS Code CLI spawn
      
      We already spawn VS Code's CLI when necessary in the lines below.
      Having the CLI spawn unconditionally when in a VS Code environment makes
      it impossible to run code-server within code-server (for example to
      develop it).
      
      * Update VS Code
      
      This sanitizes our environment variables so code-server does not always
      think it is a child spawn.
      
      Fixes https://github.com/cdr/code-server/issues/4519.
      9d9f3a41
    • A
      Remove excessive reloading before VS Code is ready (#4589) · c3eb9b80
      Asher 提交于
      The watch script was reloading the web server after every extension
      compilation which is not necessary plus VS Code will not even be ready
      at that point anyway.
      
      Instead restart when the main compilation is finished.  The string to
      match with includes a "with" because otherwise it would match "Finished
      compilation extensions" which is not the main compilation task where we
      actually need to restart the web server.
      
      I also replaced this.log with console.log because the former does not
      include a newline and it appears we want newlines with all
      these (otherwise the next log starts on the same line which looks odd).
      
      I removed the cache clean as well because the cache is meant to stay
      there to speed up builds.
      c3eb9b80
    • J
  5. 07 12月, 2021 2 次提交
  6. 02 12月, 2021 1 次提交
    • T
      Proxy path fixes (#4548) · 62b3a6fd
      Teffen 提交于
      * Fix issue where HTTP error status codes are not read.
      
      * Fix issues surrounding sessions when accessed from a proxy.
      
      - Updated vscode args to match latest upstream.
      - Fixed issues surrounding trailing slashes affecting base paths.
      - Updated cookie names to better match upstream's usage, debuggability.
      
      * Bump vendor.
      
      * Update tests.
      
      * Fix issue where tests lack cookie key.
      Co-authored-by: NAsher <ash@coder.com>
      62b3a6fd
  7. 30 11月, 2021 2 次提交
  8. 23 11月, 2021 2 次提交
  9. 20 11月, 2021 4 次提交
  10. 18 11月, 2021 1 次提交
  11. 17 11月, 2021 2 次提交
    • A
      Fix watcher not restarting code-server on VS Code compilation (#4520) · cd26f84b
      Asher 提交于
      The "Starting watch-client" string no longer appears in the latest build
      output.  We could look for "Finished compilation with" to avoid
      restarting when other tasks restart (since they also include the name
      i.e. "Finished compilation extensions with 0 errors") but I figure we
      might as well restart code-server when any compilation task completes in
      case other tasks include changes that need to be reloaded.
      cd26f84b
    • J
      fix NOTE.txt (#4515) · ccb9d948
      Jinu 提交于
      ccb9d948
  12. 16 11月, 2021 2 次提交
  13. 15 11月, 2021 1 次提交
  14. 13 11月, 2021 2 次提交
  15. 11 11月, 2021 1 次提交
    • A
      Update changelog (#4492) · d052cc24
      Asher 提交于
      I added the missing versions and some changelog entries for the latest
      version.  I also added some extra details to the entries that should
      help users understand what changed and what they need to do about
      it.  The overall format is based on keepachangelog.com.
      
      In that same spirit I removed entries that do not affect
      users (documentation and development changes).
      
      I removed the names because it seems unlikely users will be interested,
      that information can be found in the PR, and code is really the work of
      multiple developers (even if only one is writing code and the other is
      reviewing) which is not something that is reflected in this document.
      d052cc24
  16. 10 11月, 2021 4 次提交
    • T
      Open VSX switch, Part II (#4319) · e4a797dc
      Teffen 提交于
      * docs: update FAQ with extension gallery info (#2672)
      
      * Update app to reflect Open VSX switch.
      
      - Remove extension related github configs.
      - Update tests to reflect new upstream behavior.
      Co-authored-by: NAkash Satheesan <akash@coder.com>
      e4a797dc
    • T
      Use upstream server (#4414) · 1b60ef41
      Teffen 提交于
      * Flesh out fixes to align with upstream.
      
      * Update route handlers to better reflect fallback behavior.
      
      * Add platform to vscode-reh-web task
      
      Our strategy has been to build once and then recompile native modules
      for individual platforms.  It looks like VS Code builds from scratch for
      each platform.
      
      But we can target any platform, grab the pre-packaged folder, then
      continue with own packaging.
      
      In the future we may want to rework to match upstream.
      
      * Fix issue where workspace args are not parsed.
      
      * Fix issues surrounding opening files within code-server's terminal.
      
      * Readd parent wrapper for hot reload.
      
      * Allow more errors.
      
      * Fix issues surrounding Coder link.
      
      * Add dir creation and fix cli
      
      It seems VS Code explodes when certain directories do not exist so
      import the reh agent instead of the server component since it creates
      the directories (require patching thus the VS Code update).
      
      Also the CLI (for installing extensions) did not seem to be working so
      point that to the same place since it also exports a function for
      running that part of the CLI.
      
      * Remove hardcoded VSCODE_DEV=1
      
      This causes VS Code to use the development HTML file.  Move this to the
      watch command instead.
      
      I deleted the other stuff before it as well since in the latest main.js
      they do not have this code so I figure we should be safe to omit it.
      
      * Fix mismatching commit between client and server
      
      * Mostly restore command-line parity
      
      Restore most everything and remove the added server arguments.  This
      will let us add and remove options after later so we can contain the
      number of breaking changes.
      
      To accomplish this a hard separation is added between the CLI arguments
      and the server arguments.
      
      The separation between user-provided arguments and arguments with
      defaults is also made more clear.
      
      The extra directory flags have been left out as they were buggy and
      should be implemented upstream although I think there are better
      solutions anyway.  locale and install-source are unsupported with the
      web remote and are left removed.  It is unclear whether they were used
      before anyway.
      
      Some restored flags still need to have their behavior re-implemented.
      
      * Fix static endpoint not emitting 404s
      
      This fixes the last failing unit test.
      
      Fix a missing dependency, add some generic reverse proxy support for the
      protocol, and add back a missing nfpm fix.
      
      * Import missing logError
      
      * Fix 403 errors
      
      * Add code-server version to about dialog
      
      * Use user settings to disable welcome page
      
      The workspace setting seems to be recognized but if so it is having no
      effect.
      
      * Update VS Code cache step with new build directories
      Co-authored-by: NAsher <ash@coder.com>
      1b60ef41
    • M
      Escape HTML from messages in error page (#4430) · 31d5823d
      Mauricio Garavaglia 提交于
      Co-authored-by: NAsher <ash@coder.com>
      Co-authored-by: NJoe Previte <jjprevite@gmail.com>
      31d5823d
    • L
      Add a gist of the difference between code-server and Coder (#4419) · 605c3c63
      LG 提交于
      * Add a gist of the difference
      
      * Update the gist
      
      * Update README.md
      
      As told by @tmikaeld here: https://github.com/cdr/code-server/discussions/3102#discussioncomment-1565789
      
      * Update docs/README.md
      Co-authored-by: NJoe Previte <jjprevite@gmail.com>
      
      * `yarn fmt` results
      Co-authored-by: NJoe Previte <jjprevite@gmail.com>
      Co-authored-by: NAsher <ash@coder.com>
      605c3c63
  17. 06 11月, 2021 2 次提交
  18. 05 11月, 2021 1 次提交
    • A
      Use frozen lockfile for test dependencies in CI (#4442) · 03651e5e
      Asher 提交于
      * Use frozen lockfile for test dependencies in CI
      
      This might be causing more Playwright issues.
      
      * Bump Playwright
      
      Mostly just to trigger a reinstall of dependencies since it is cached
      and still failing.
      
      Once updated it errors saying install needs to run so add that too.
      03651e5e
  19. 04 11月, 2021 4 次提交
  20. 02 11月, 2021 3 次提交