Coder Social home page Coder Social logo

bitburner-vscode's People

Contributors

hexnaught avatar hydroflame avatar pyrox0 avatar semantic-release-bot avatar slycedix avatar smolgumball 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  avatar  avatar  avatar  avatar  avatar

bitburner-vscode's Issues

"Push File To The Game" is not working anymore when using with BitBurner v2.2.2

While working fine when using with version 1.7 of BitBurner,
with the current version of BitBurner available on Steam (v2.2.2) the file upload does not any longer work as intended.
No files are uploaded anymore and the debug console in BitBurner shows the following error for each attempt to push a file from VSCode to BitBurner:

image

File Push does not work on Linux Mint 20.3

Problem:

I can not push any js file into the game. No js file is shown in the game terminal with the command ls. The push of file does not work with the context menu nor the command pallet in vs code.

What I did:

I included the auth token from the game into the property "bitburner.authToken" under the file "setttings.json" under the folder ".vscode"

👴Old repository location references

Several places in the codebase there are references to the old repo hexnaught/vscode-bitburner-connector

- Create a [Pull Request](https://github.com/hexnaught/vscode-bitburner-connector/compare) from your fork, to the `hexnaught/vscode-bitburner-connector` repository with `develop` as the base branch.

We can support custom keywords, these can be seen under the `@semantic-release/commit-analyzer` `releaseRules` within [`.releaserc`](https://github.com/hexnaught/vscode-bitburner-connector/blob/master/.releaserc).

"url": "https://github.com/hexnaught/vscode-bitburner-connector"

"url": "https://github.com/hexnaught/vscode-bitburner-connector/issues"

![Image showing API Server context menu in the bitburner game client](https://raw.githubusercontent.com/hexnaught/vscode-bitburner-connector/assets/images/bit-burner-menu-auth-token.png)

They should be updated to the new location bitburner-official/bitburner-vscode

Push File does not work in WSL

If I open VS Code “in WSL” (with Remote - WSL), the Context Menu > Bitburner: Push File To The Game function has no effect. The file does not appear in game. If I open it “in Windows,” it works as advertised.

This is true whether the files are in the Windows or WSL filesystem.
I'm on Win 10 21H2, WSL2 with Ubuntu.

Add Two-Way sync capabilities

Especially when switching from the in-game Editor to VsCode the first time, it would be much appreciated if there was a way to download the scripts from the game into the scriptRoot. Currently i did not find a satisfying way to do so other than copy-pasting each script manually.

This would require implementing GET endpoints on the game server and some way of polling changes (altough i guess a manual action would be sufficient for a start).

Feature Request: Show RAM usage of script and/or functions inside VS-Code

It would help optimizing scripts if RAM usage of imports, function calls or generally total ram usage of a script were shown in VS-Code.

A plugin from this reddit-post https://www.reddit.com/r/Bitburner/comments/bh48y2/visual_studio_code_ram_calculator_extra/ was attempting to implement this, but appearantly, that extension is outdated and not compatible anymore with current version of the game.

I've tried the user-extension and it just shows this:
grafik

Maybe that gives an idea of what is requested.

To summerize:

  • Show RAM usage of current script in Status-Bar of VS-Code
  • Show RAM usage of custom functions (i.e. total RAM usage of a function)
  • Show RAM usage of imported scripts

It would be neat if the RAM usage would be shown in the Editor.

Customizable options would be great too. The above link to the existing (but broken) extension was actually heading in the right direction.

code definintion support

Hey thanks for the addon, and i understand you have only just started work on this integration, but is there maybe a rough feature plan for it?

was just wondering if code definition support is on the table?
i have never tired to import d.ts files so i'm not sure if this is possible but could you leverage the typescript definitions and ship as part of the addon?

Add an extension Icon

Currently we don't have one!

Current Game Icon(s)

image

Changes needed

  • Add an icon to assets/icon.png
  • Add the following line to the package.json file (below the description key)
    • "icon": "assets/icon.png",

Doesn't work with vscode workspaces containing multiple folders

To reproduce:

  • Create a workspace.
  • In workspace settings, turn on filewatcher, set up your auth token, turn on notifications.
  • Add one folder to the workspace, let's call this the "bitburn" folder.
  • Create a folder inside the "bitburn folder" called the "bbscripts" folder.
  • Set your "bitburner script root" in the extension to: "./bbscripts/"
  • Observe that your scripts in the "bbscripts" folder upload successfully on save.
  • In vscode go to "file, add folder to workspace"
  • Add your eslint-plugin-bitburning folder (a project I'm working on ;) ) to your workspace
  • Exit vscode
  • Open vscode
  • Observe that changes to scripts in the "bbscripts" folder are no longer synched

I understand that it won't be supported to synch multiple folders in. But that's not what I want. Hoping for a way to specify that only the "bitburn" workspace folder is synched with the plugin, while still being able to have the "eslint-plugin-bitburning" folder open.

I attempted to workaround this by using folder level settings, but folder level settings didn't seem to work at all, it wouldn't even load the filewatcher for example.

Discord references:

https://discord.com/channels/415207508303544321/923428435618058311/931380461354254346

https://discord.com/channels/415207508303544321/923428435618058311/931379041171296256

Autocomplete NS

Is there a way to add the NS type to vscode so that autocompletion works like it does in the game? The ideal would be if this were done automatically by the extension.

notFound error occurs every time I attempt an action

Any time I attempt to run a command through the command palette, whether it's setting the auth token or pushing a file, I get a similar error.
image

'ext.bitburner.connector.addAuthToken' not found

Any ideas on how to troubleshoot this?

File pushing of transitive dependencies doesn't properly cause rebuilds

Firstly, thanks for the plugin! It's nice to use an external editor.

Now that an external editor makes it easy, I've been organising my files a bit better which caused me to run into some difficulties:

My actual scripts are here but the basic problem is this:

Files:

util/logger.js
scheduler/scheduler.js
overmind.js

overmind.js:

import Scheduler from "scheduler/scheduler.js"

scheduler.js:

import Logger from "util/logger.js";

logger.js does more or less the obvious.

When I make a change to logger.js this gets uploaded to the game. But the entry point for my scripts is overmind.js and as far as I can tell, the JS never gets recompiled or transpiled or whatever happens under the hood. As such any changes I make don't happen until I push (I think?) logger.js, -then- scheduler.js and lastly overmind.js, in that order.

I have quite a bit of trouble keeping track of what changes have and haven't actually made it to the game.

I'm not a Javascript expert by any stretch but one thing I'd click on in a heartbeat is an option to bust all the cached transpiled code every time I push up a file. I wouldn't personally care that this might slow things down some in exchange for always executing the code I think I am.

I could just be missing something simpler, would appreciate thoughts!

Upload of txt files

Hello,

i've just started using the extension and it's working so far for scripts.
The upload of *.txt files is broken though.

This is in fact a bit confusing, as the README.md does not mention txt files - but it's in the code.

I get the toast (as activated in settings), that the file was uploaded - but it does not appear in Bitburner.
There is no error message in Bitburners debugger.

In vscode the plugin reports some errors that seem to be unrelated:

Cannot read property 'dispose' of undefined
Cannot read property 'dispose' of undefined
Cannot read property 'dispose' of undefined
Cannot read property 'dispose' of undefined

Game version (Steam): Bitburner v1.3.0 (5ebb96a0)
vscode: 1.63.2
Plugin: 1.3.3

Regards!

Server enabled, but connection refused

Very new to bitburner and the extension, but I can't get it to work at all. I've enabled the server in the Bitburner client. I've copied the auth token and supplied it to the extension. When I try to push, nothing happens, but in VSCode devtools I see:

log.ts:313   ERR connect ECONNREFUSED 127.0.0.1:9990: Error: connect ECONNREFUSED 127.0.0.1:9990
	at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1146:16)

Connect to game server not on localhost?

Hi, I have a small setup for this game where I want to use my laptop with vscode and run the game on my computer. I looked at all of the settings for the extension and I don't see one for ip or port. I also looked at the extension.js file, In there they have a url config changing to from localhost to my pc's ip address also did not work. Is there something I can do in the extension or do I have to look into redirecting the connection?

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.