Skip to content

Commit

Permalink
Move RocksDB to git submodule
Browse files Browse the repository at this point in the history
  • Loading branch information
filoozom authored and vweevers committed Apr 10, 2021
1 parent f0115f5 commit 1b6ea11
Show file tree
Hide file tree
Showing 8 changed files with 407 additions and 16 deletions.
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[submodule "deps/rocksdb/rocksdb"]
path = deps/rocksdb/rocksdb
url = https://github.com/facebook/rocksdb.git
28 changes: 14 additions & 14 deletions .npmignore
Original file line number Diff line number Diff line change
@@ -1,20 +1,20 @@
deps/**/*.md
deps/**/.git

deps/leveldb/leveldb-rocksdb/arcanist_util/
deps/leveldb/leveldb-rocksdb/build_tools/
deps/leveldb/leveldb-rocksdb/coverage/
deps/leveldb/leveldb-rocksdb/docs/
deps/leveldb/leveldb-rocksdb/examples/
deps/leveldb/leveldb-rocksdb/hdfs/setup.sh
deps/leveldb/leveldb-rocksdb/java/
deps/leveldb/leveldb-rocksdb/third-party/gtest-*/
deps/leveldb/leveldb-rocksdb/tools/*.sh
deps/leveldb/leveldb-rocksdb/tools/*.py
deps/leveldb/leveldb-rocksdb/tools/*.dmp
deps/leveldb/leveldb-rocksdb/tools/rdb/
deps/leveldb/leveldb-rocksdb/README.md
deps/leveldb/leveldb-rocksdb/HISTORY.md
deps/rocksdb/rocksdb/arcanist_util/
deps/rocksdb/rocksdb/build_tools/
deps/rocksdb/rocksdb/coverage/
deps/rocksdb/rocksdb/docs/
deps/rocksdb/rocksdb/examples/
deps/rocksdb/rocksdb/hdfs/setup.sh
deps/rocksdb/rocksdb/java/
deps/rocksdb/rocksdb/third-party/gtest-*/
deps/rocksdb/rocksdb/tools/*.sh
deps/rocksdb/rocksdb/tools/*.py
deps/rocksdb/rocksdb/tools/*.dmp
deps/rocksdb/rocksdb/tools/rdb/
deps/rocksdb/rocksdb/README.md
deps/rocksdb/rocksdb/HISTORY.md

deps/snappy/snappy*/testdata/
deps/snappy/snappy*/*.txt
Expand Down
18 changes: 18 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,24 @@ Please refer to [`leveldown`](https://github.com/Level/leveldown#api) for API do
See the [Contribution Guide](https://github.com/Level/community/blob/master/CONTRIBUTING.md) for more details.

### Git Submodules

This project uses Git Submodules. This means that you should clone it recursively if you're planning on working on it:

```bash
$ git clone --recurse-submodules https://github.com/Level/leveldown.git
```

Alternatively, you can initalize submodules inside the cloned folder:

```bash
$ git submodule update --init --recursive
```

### Windows

A large portion of the Windows support comes from code by [Krzysztof Kowalczyk](http://blog.kowalczyk.info/) [@kjk](https://twitter.com/kjk), see his Windows LevelDB port [here](http://code.google.com/r/kkowalczyk-leveldb/). If you're using LevelUP on Windows, you should give him your thanks!

### Publishing

1. Increment the version: `npm version ..`
Expand Down
3 changes: 2 additions & 1 deletion appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@ platform:
install:
- SET PATH=C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\bin;%PATH%
- ps: Install-Product node $env:nodejs_version $env:platform
- SET PATH=%APPDATA%\npm;%APPVEYOR_BUILD_FOLDER%\node_modules\.bin;%PATH%
- set PATH=%APPDATA%\npm;%APPVEYOR_BUILD_FOLDER%\node_modules\.bin;%PATH%
- git submodule update --init --recursive
- npm i

test_script:
Expand Down
2 changes: 1 addition & 1 deletion binding.gyp
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@
}]
]
, "dependencies": [
"<(module_root_dir)/deps/leveldb/leveldb.gyp:leveldb"
"<(module_root_dir)/deps/rocksdb/rocksdb.gyp:rocksdb"
]
, "include_dirs" : [
"<!(node -e \"require('napi-macros')\")"
Expand Down
4 changes: 4 additions & 0 deletions deps/rocksdb/build_version.cc
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#include "rocksdb/util/build_version.h"
const char* rocksdb_build_git_sha = "rocksdb_build_git_sha:None";
const char* rocksdb_build_git_date = "rocksdb_build_git_date:None";
const char* rocksdb_build_compile_date = "None";
1 change: 1 addition & 0 deletions deps/rocksdb/rocksdb
Submodule rocksdb added at 4e0065

0 comments on commit 1b6ea11

Please sign in to comment.