This commit is contained in:
sankalp committed 2024-08-13 02:42:59 +05:45
1 parent cff80541c9
commit f8b9becdb8
98 files changed
-15609

No files matched your search

-164
View File
@@ -1,164 +0,0 @@
return {
diagnostics = {
Error = '',
Hint = '󰠠 ',
Information = '',
Question = '',
Warning = '',
},
documents = {
File = '',
FileEmpty = '',
Files = '',
Folder = '',
FolderEmpty = '',
OpenFolder = '',
OpenFolderEmpty = '',
SymLink = '',
SymlinkFolder = '',
Import = '',
},
git = {
Add = '',
AddAlt = '',
Branch = '',
Diff = '',
DiffAlt = '',
Ignore = '◌ ',
Mod = '',
Octoface = '',
Remove = '',
RemoveAlt = '',
Rename = '',
Repo = '',
Tag = '',
Untrack = '',
},
kind = {
Class = '',
Color = '',
Constant = '',
Constructor = '󰈏 ',
Enum = '',
EnumMember = '',
Event = '',
Field = '',
File = '',
Folder = '',
Function = '󰊕 ',
Interface = '',
Keyword = '',
Method = '',
Module = '',
Operator = '',
Property = '',
Reference = '',
Snippet = '',
Struct = '',
Text = '',
TypeParameter = '',
Unit = '',
Value = '',
Variable = '',
},
type = {
Array = '',
Boolean = '⏻ ',
Number = '',
Object = '',
String = '',
},
ui = {
Arrow = '',
ArrowClosed = '',
ArrowLeft = '',
ArrowOpen = '',
ArrowRight = '',
Bluetooth = '',
Bookmark = '',
Bug = '',
Calendar = '',
Camera = '',
Check = '',
ChevronRight = '',
Circle = '',
CircleSmall = '● ',
CircleSmallEmpty = '○ ',
Clipboard = '',
Close = '',
Code = '',
Collection = '',
Color = '',
Command = '',
Comment = '',
Copilot = '',
CopilotError = '',
Corner = '└ ',
Dashboard = '',
Database = '',
Download = '',
Edge = '│ ',
Electric = '',
Eye = '',
Fire = '',
Firefox = '',
Flag = '',
Game = '',
Gear = '',
GitHub = '',
Heart = '',
History = '',
Home = '',
Incoming = '',
Jump = '',
Keyboard = '',
Ligthbulb = '󰌵 ',
List = '',
Lock = '',
Minus = '‒ ',
Music = '󰝚 ',
Neovim = '',
NewFile = '',
None = ' ',
Note = '',
Outgoing = '',
Package = '',
Paint = '',
Pause = '',
Pencil = '',
Person = '',
Pin = '',
Play = '',
Plug = '',
Plus = '',
Power = '',
PowerlineArrowLeft = '',
PowerlineArrowRight = '',
PowerlineLeftRound = '',
PowerlineRightRound = '',
Project = '',
Question = '',
Reload = '',
Rocket = '',
Save = '󰆓 ',
Search = '',
Separator = '▊ ',
SeparatorLight = '▍',
SeparatorDashed = '┆',
SignIn = '',
SignOut = '',
Sleep = '󰒲 ',
Star = '',
Table = '',
Telescope = '',
Terminal = '',
Test = '',
Time = '',
Topline = '‾',
Trash = '',
User = '',
Vim = '',
Wifi = '',
Windows = '',
},
}
-66
View File
@@ -1,66 +0,0 @@
local util = {}
util.get_user_config = function(key, default)
local status_ok, user = pcall(require, 'user')
if not status_ok then
return default
end
local user_config = user[key]
if user_config == nil then
return default
end
return user_config
end
util.get_root_dir = function()
local bufname = vim.fn.expand('%:p')
if vim.fn.filereadable(bufname) == 0 then
return
end
local parent = vim.fn.fnamemodify(bufname, ':h')
local git_root = vim.fn.systemlist('git -C ' .. parent .. ' rev-parse --show-toplevel')
if #git_root > 0 and git_root[1] ~= '' then
return git_root[1]
else
return parent
end
end
util.get_file_type_cmd = function(extension)
local root = util.get_root_dir()
if extension == 'arb' and root then
local gemfile_exists = vim.fn.filereadable(root .. '/Gemfile') == 1
local pubspec_exists = vim.fn.filereadable(root .. '/pubspec.yaml') == 1
if gemfile_exists then
return 'setfiletype ruby'
end
if pubspec_exists then
return 'setfiletype json'
end
end
return ''
end
util.is_present = function(bin)
return vim.fn.executable(bin) == 1
end
util.telescope_select = function(options, options_desc, select_prompt)
require('telescope.pickers')
.new({}, {
prompt_title = select_prompt,
results_title = options_desc,
finder = require('telescope.finders').new_table({
results = options,
entry_maker = require('telescope.make_entry').gen_from_file(),
}),
sorter = require('telescope.sorters').get_fzy_sorter(),
previewer = require('telescope.previewers').vim_buffer_cat.new({}),
})
:find()
end
return util