๐ŸŽฉ You're Invited:Meet the Socket team at Black Hat in Las Vegas, August 3-6.RSVP โ†’
Sign In

@ast-grep/lang-ruby

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@ast-grep/lang-ruby - npm Package Compare versions

Comparing version
0.0.3
to
0.0.4
+24
-2
index.js
const path = require('node:path')
const libPath = path.join(__dirname, 'parser.so')
const fs = require('node:fs')
const { resolvePrebuild } = require('@ast-grep/setup-lang')
function getLibPath() {
const prebuild = resolvePrebuild(__dirname)
if (prebuild) {
return prebuild
}
const native = path.join(__dirname, 'parser.so')
if (fs.existsSync(native)) {
return native
}
throw new Error('No parser found. Please ensure the parser is built or a prebuild is available.')
}
let libPath
module.exports = {
libraryPath: libPath,
get libraryPath() {
if (!libPath) {
libPath = getLibPath()
}
return libPath
},
extensions: ['rb', 'rbw', 'gemspec'],

@@ -7,0 +29,0 @@ languageSymbol: 'tree_sitter_ruby',

+5
-5
{
"name": "@ast-grep/lang-ruby",
"version": "0.0.3",
"version": "0.0.4",
"description": "",

@@ -21,6 +21,6 @@ "main": "index.js",

"dependencies": {
"@ast-grep/setup-lang": "0.0.3"
"@ast-grep/setup-lang": "0.0.4"
},
"peerDependencies": {
"tree-sitter-cli": "0.25.6"
"tree-sitter-cli": "0.25.8"
},

@@ -33,4 +33,4 @@ "peerDependenciesMeta": {

"devDependencies": {
"@ast-grep/nursery": "0.0.5",
"tree-sitter-cli": "0.25.6",
"@ast-grep/nursery": "0.0.7",
"tree-sitter-cli": "0.25.8",
"tree-sitter-ruby": "0.23.1"

@@ -37,0 +37,0 @@ },

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet