Coder Social home page Coder Social logo

depbjs's Introduction

Protobufjs Decompiler

A Simple Decompiler for Protobufjs.

Install

npm install -g depbjs

Usage

depbjs -i target.js -o target.proto

Example

pbjs -t commonjs tests/test.proto -o tests/test.js
depbjs -i tests/test.js -o tests/output.proto

test.proto

// test.proto
package testPackage;
syntax = "proto3";
message SubMsg{
    int32 testSubmsg=1;
};
message TestMessage {
  string test_field = 1;
  int32 i32 = 3;
  int64 i64 = 2;
  string str = 4;
  float f32 = 5;
  SubMsg msg=7;
  uint32 u32x = 6;
}

enum TestEnum{
  Key=1;
  E2=20;
  XX=3;
}

output.proto

// 
// This file is decompiled by depbjs v0.0.1.
// source: ./tests/test.js
// 

package testPackage;

message SubMsg {
    int32 testSubmsg = 1;
};

message TestMessage {
    string testField = 1;
    int32 i32 = 3;
    int64 i64 = 2;
    string str = 4;
    float f32 = 5;
    SubMsg msg = 7;
    uint32 u32x = 6;
};

enum TestEnum {
    Key = 1;
    E2 = 20;
    XX = 3;
};

License

MIT License.

depbjs's People

Contributors

system233 avatar

Watchers

 avatar

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.