<span style="font-size: small">Latest version of this resume: [[https://www.codewiz.org/resume | www.codewiz.org/resume]]</small>
-=== Career Objectives ===
+=== Objectives ===
My primary interests are system programming, drivers, firmware, sensors, robotics, hard real-time systems,
compilers, machine learning, distributed systems, low-latency networking, computer graphics, education technology.
=== Summary ===
- * Senior Firmware Engineer, [[https://www.spacex.com/ | SpaceX]]
- * Senior Software Engineer, [[https://www.google.com/ | Google]]
- * Co-founder, Board Member, [[https://www.sugarlabs.org/ | Sugar Labs Foundation]]
+ * Senior Firmware Engineer, Starship Avionics, [[https://www.spacex.com/ | SpaceX]]
+ * Senior Software Engineer, Android Networking, [[https://careers.google.com/locations/tokyo/ | Google Japan]]
+ * Senior Software Engineer, Search Infrastructure, [[https://careers.google.com/locations/cambridge/ | Google]]
+ * Co-founder, [[https://www.sugarlabs.org/ | Sugar Labs Foundation]] (education non-profit)
* OS Developer, [[http://www.paraguayeduca.org/ | Paraguay Educa]], [[OneLaptopPerChild | One Laptop Per Child]]
- * CTO & Co-Founder, [[https://www.develer.com/en/ | Develer]], embedded systems and software engineering firm
+ * CTO & Co-Founder, [[https://www.develer.com/en/ | Develer]] (embedded systems / Linux engineering firm)
* Open-source contributor ([[https://gcc.gnu.org/ | GCC]], [[https://www.kernel.org/ | Linux kernel]] and various others)
=== Skills ===
- * **Programming Languages**: Modern C++, Rust, C, Java, Go
- * **Assembly**: x86, m68k, 6502, Z80
- * **Microcontrollers and DSPs**: NXP i.MX RT (ARM), Coldfire, m68705, TMS320
+ * **Programming Languages**: C++20, Rust, C, Java, Go
* **Dynamic/Scripting Languages**: Python, Java****Script, Type****Script, Bash, Perl, PHP
+ * **Assembly**: x86, ARM, m68k, 6502, Z80
+ * **Microcontrollers and DSPs**: NXP i.MX RT (ARM), Coldfire, M68705, TMS320
* **Other Languages**: HTML, CSS, GLSL, SQL, LaTeX
* **Natural Languages**: Italian (native), English (excellent), Spanish (fluent), Japanese (studying for JLPT N3)
- * **Operating Systems**: Linux (Arch, Red Hat, Fedora, Ubuntu, Debian, uClinux), Android, macOS, Solaris, NetBSD, AmigaOS, Windows
- * **Development Tools**: GCC (contributor), Clang, Visual Studio Code, GNU make, autoconf, ninja
+ * **Operating Systems**: Linux (Red Hat, Fedora, Arch, Ubuntu, Debian, uClinux), Android, macOS, Solaris, NetBSD, AmigaOS, Windows
+ * **Development Tools**: GCC (contributor), Clang, Visual Studio Code, GNU make, ninja
* **Embedded Compilers**: Codewarrior, IAR, Code Composer Studio, BSO Tasking, SAS/C
* **Frameworks and APIs**: POSIX, Web****Assembly, Qt, OpenGL, Win32, Protobufs
* **Programming Styles**: functional, OOP, template metaprogramming, async/await, event-driven, realtime, multithreading
* **Version Control**: Git (self-hosted, [[https://gitlab.com/berniecodewiz | GitLab]] and [[https://github.com/codewiz | GitHub]]), Perforce, Subversion
- * **Network Protocols**: QUIC, HTTP, TLS, IPv6, TCP, UDP, DNS, DNSSEC, BGP
- * **Sysadmin**: KVM, Docker, Puppet, Google Cloud, systemd, Nagios, Munin
- * **Server Software**: Apache, Nginx, BIND, Postfix, MySQL, PostgreSQL, Mediawiki, Asterisk
+ * **Network Protocols**: HTTP, QUIC, TLS, IPv6, TCP, UDP, DNS, DNSSEC, DHCP, TFTP, BGP
+ * **Sysadmin**: KVM, Docker, Puppet, Google Cloud, systemd, Nagios, Grafana
=== Work Experience ===
-==== Senior Software Engineer, Google (Sep 2011 ~ Sep 2021) ===
+==== Senior Firmware Engineer, SpaceX (Sep 2021 ~ present) ====
+ * Sensor Development: Design and develop firmware for navigation and propulsion systems
+ * Starship Avionics: Maintainer of firmware codebase
+ * Test engineering: Develop Linux-based testbeds and CI pipelines for sensors
+
+==== Senior Software Engineer, Google (Sep 2011 ~ Sep 2021) ====
* Android Core Networking: Lead developer of the [[https://source.android.com/devices/architecture/modular-system/dns-resolver | DNS resolver]], including monitoring and experiments system
* Google Search Infrastructure: Develop features for high-throughput, high-availability, distributed web serving for billions of files
* [[https://amp.dev/ | Accelerated Mobile Pages]]: Tech lead of global CDN for news sites integrated with Google Search
* Build, test and release OS updates for 4600 laptops deployed in rural schools
* Organize computer programming and "hacking" workshops for students
-==== Volunteer Developer at One Laptop Per Child (May 2007 ~ Apr 2008) ====
+==== Volunteer at One Laptop Per Child (May 2007 ~ Apr 2008) ====
* In-house maintainer of the X11 windowing system and graphics drivers
* Input drivers, keyboard layouts and i18n
* Platform development, packaging, release engineering
* Built team of highly skilled Linux and firmware engineers
* Wrote firmware for embedded systems and DSPs (over a dozen different architectures)
* Created project hosting and remote collaboration infrastructure
- * Business development and customer relationships in multiple industries
+ * Business development and customer relationships
==== Freelance (2000 ~ 2009) ====
* **Telecom Italia Labs**: Design and implement compiler & interpreter of an object-oriented configuration language for a network simulator
==== Co-founder and CTO, Sirius SRL ====
* Firmware and power control for laser hair removal
- * Created company's Internet presence and collaboration infrastructure
+ * Created company's IT infrastructure and Internet presence
==== Firmware engineer, SEAC R&D laboratories ====
* Control software for clinical analyzer robot with 18 stepper motors
<div style="width: 640px; margin:0 auto">{{pictures/linux/x230-flashing.jpg | maxwidth=640}}</div>
-Coreboot, the free PC BIOS that powers all Google Chromebooks, was recently ported to the Thinkpad X230
-by the long time GRUB hacker Vladimir 'φ-coder' Serbinenko. And so this week-end, while Libre Planet was
-taking place at the nearby MIT Stata Center, I decided to give it a shot.
+Coreboot, the opensource PC firmware that powers all Chromebooks, was recently ported to the Thinkpad X230
+by long-time GRUB hacker Vladimir 'φ-coder' Serbinenko. And so I decided to give it a shot ahead of
+Libre Planet, which is taking place this weekend at MIT.
Building a custom Coreboot image for the X230 was straightforward:
<a href="https://mstdn.io/@codewiz" rel="me">Blog</a> | [[https://github.com/codewiz | GitHub]] | [[https://gitlab.com/berniecodewiz | GitLab]] | [[https://www.linkedin.com/in/codewiz | LinkedIn]] \\
-Senior Software Engineer, <a class="url org" href="https://careers.google.com/locations/tokyo/">Google Japan</a> \\
+Senior Firmware Engineer, <a class="url org" href="https://spacex.com">SpaceX</a> \\
Infrastructure Team Coordinator, <a class="url org" href="https://www.sugarlabs.org/">Sugar Labs Foundation</a>
GPG: [[https://codewiz.org/pub/bernie_pgp_pubkey.asc | 0BE2781CFC7F1BA4]]
-[[ContactInformation|Full Contact Information]]
+[[ContactInformation|Full contact info]]
=== Personal Projects ===
* [[https://www.sugarlabs.org/ | Sugar Labs]] — A non-profit developing the Sugar (spin off of [[OneLaptopPerChild | One Laptop Per Child]])
=== Philosophy and religion ===
* [[GreatQuotes]]
- * Church of the Flying Spaghetti Monster: http://www.venganza.org/
-
-=== Politics and ethics ===
-
- * [[MicrosoftTactics]] against Linux and Open Source
- * The Technique of the Straw Man: http://www-personal.umich.edu/~lilyth/strawman.html
=== Vision ===
+==== Hawthorne Optometry (2022-12-01) ====
+
+Intermediate/near PAL:
+
+|| **eye** || **sph** || **cyl** || **axis** || **add** ||
+|| R || +1.25 || -0.75 || 025 || +1.00 ||
+|| L || +0.50 || -1.00 || 174 || +1.00 ||
+
+Full PAL:
+
+|| **eye** || **sph** || **cyl** || **axis** || **add** ||
+|| R || +0.75 || -0.75 || 025 || +1.75 ||
+|| L || 0.00 || -1.00 || 174 || +1.75 ||
+
+
==== Vision Samitivej Hospital (2021-03-15) ====
|| **eye** || **sph** || **cyl** || **axis** ||
<div style="text-align: center">
{{SystemShockLogoAlpha.png}}\\
-##CONNECT 4194304/TCP80##\\
+##CONNECT 209.51.188.53:23/IPv4##\\
##Press LMB twice to edit this page##\\
##Guest login enabled (hit RETURN at the password prompt)##
</div>
-== Availability ==
+== Online Services ==
-=== Telnet access ===
+=== BBS File Archives ===
-For your nostalgic needs, sometimes System Shock BBS can still be reached: [[telnet://shock.codewiz.org:6502]].
-Only one telnet user at a time for now, sorry. New users should sendsend email to the [[SysOp]] to speedup
-account validation.
+No ratio, leech as much as you want!
-Oh, and do not even //attempt// to use Echomail, as we don't poll our hub any longer.
-If you don't like this new policy, go on and file a formal complaint to our FidoNet NEC ;-)
+ * https://codewiz.org/pub/systemshock/
-TODO: multiple ##telser.device## lines coming sooN!!!111oneone
+You might also want to browse the [[https://codewiz.org/pub/systemshock/filelists/SystemShock.All|full file list]],
+or the [[https://codewiz.org/pub/systemshock/filelists/SystemShock.AllShort|short list]].
-FIXME: any suggestions for a good BBS-ANSI terminal with telnet support for Linux? [[ZModem]] support would be very useful.
+=== Web presence ===
-=== File archives ===
+The [[https://codewiz.org/oldsites/systemshock|Original System Shock Website]] is back online!
-No ratio, leech as you please! But it is not funny without seeing the descriptions in the File Areas.
- * http://pub.codewiz.org/systemshock/
- * ftp://pub.codewiz.org/pub/codewiz/systemshock/
+=== Telnet access ===
-You might want to browse the [[http://pub.codewiz.org/systemshock/filelists/SystemShock.All|full file list]]
-or the [[http://pub.codewiz.org/systemshock/filelists/SystemShock.AllShort|short list]].
+Only on special occasions, System Shock BBS can be reached at [[telnet://shock.codewiz.org:6502]].
+Only one telser user at a time for now, sorry. New users should email the [[SysOp]] to speedup
+account validation.
-=== Web presence ===
+Oh, don't bother sending Echomail - we no longer poll our Fido Hub.
+If you don't like our new Policy, go on and file a Formal Complaint to the FidoNet NEC ;-)
-The [[http://codewiz.org/oldsites/systemshock|original System Shock website]] is back online!
+FIXME: any suggestions for a good BBS-ANSI terminal with telnet support for Linux? [[ZModem]] support would be very useful.
== Events ==
* 2009 Mar 29: [[SystemShockBBSSummit]]
-== Points ==
+== List of Points ==
|| ||**Point**||** Summit **||
|| [[User/Bernie|bernie]] ||1 || V ||
|| ladyblue ||xy || new entry ||
|| vic ||22 || ringamb ||
|| aleph ||¿ || V ||
-
-{{http://www.paternostro.org/~ugo/images/Pianeta_Amiga/lores17.jpg|System Shock BBS @ PianetaAmiga}}
\ No newline at end of file
-== Bernie Innocenti's speaker bio ==
+== Speaker bio ==
-Bernie Innocenti is a Linux developer and firmware engineer, supporting member
-of the Free Software Foundation and founder of Develer, a tech consulting
-business based in Italy. In 2007, Bernie joined the One Laptop Per Child project as a
-volunteer developer and later co-founded Sugar Labs, a non-profit building a
-free and open constructionist computing environment for young learners.
-Since then, Bernie has been working at OLPC deployments in Paraguay, Nepal,
-Uruguay and Mozambique.
+Bernie Innocenti is a Linux and firmware developer and founder of Develer,
+an engineering consulting business in Italy. He volunteered for
+One Laptop Per Child project and then co-founded Sugar Labs,
+a non-profit building a constructionist computing environment for
+young learners.
\ No newline at end of file
* Ditch repo sandbox, use the versioning backend directly
* Stage changes by user until committed explicitly (i.e.: wiki changesets)
- * Add simple InterWiki support
* Find orphaned pages (can be done by combining PageIndex with FindPage)
- * Directory listing
* Groups/ directory with group lists implemented as wiki pages with unordered lists
* Glob for includes: {****{foo/*.c}****}
* Variable substitution in includes (aka templates)
* Syntax highlighting for code blocks
-=== Nice to have ===
-
- * A functionality to have custom merge strategy in git to merge different wiki/GeekiGeeki in a single one
-
- * See also the original PikiToDo
== Update procedure ==
If you cloned the repository as suggested by the [[geeki/install]] procedure,
-updating and downgrading becomes quite straightforward:
+upgrading and downgrading is straightforward:
{{{
cd wiki
+++ /dev/null
-== nwiz, the code editor for a more civilized era ==
-
-=== What's this? ===
-
-** My goal is to use [[https://neovim.io/ | Neovim]] as a modern coding environment for C, C++, Rust, Python and other languages. **
-
-<div style="float: right">{{nvim-completion.png | maxwidth=600}}</div>
-
-Neovim has no shortage of powerful plugins for programmers, but it's a fast moving ecosystem.
-Picking the right combination of plugins and configuring them as an integrated development
-environment is still far from trivial. I also reviewed a number of GUIs and "super plugins"
-which aim to be a complete IDE, but all of them had maturity and usability issues.
-
-I curated a list of well-maintained plugins that take advantage of Neovim's built-in IDE components:
-
- * Language Server Protocol, for semantic completion
- * Treesitter, for semantic syntax highlighting
- * Virtual text, for inline diagnostics
- * Floating windows, for inline help and function parameter assistance
-
-The plugin ecosystem is still maturing, but over time the amount of Lua scripting required
-to piece together a fully functional IDE seems to be going down. Ideally, you wouldn't have
-to learn Lua to edit your Neovim config.
-
-** I want a programmer's editor without becoming the editor's programmer! **
-
-
-=== Features ===
-
- * Quickly open files with fuzzy search
- * Semantic completion
- * Configures language servers for C/C++, Rust, Python
- * Adding more languages made easy by lspconfig
- * Inline diagnostics and hints
-
-
-=== Requirements ===
-
-TODO: Minimum neovim version?
-
-TODO: Recommend a good terminal with undercurls, mouse support...
-
-TODO: Nerd fonts installation
-
-
-=== Installation ===
-
-To get started, download nwiz.lua to Neovim's plugin dir so it will be autoloaded at startup:
-
-{{{
- curl https://codewiz.org/pub/dotfiles/nwiz.lua -o ~/.config/nvim/plugin/nwiz.lua
-}}}
-
-Everything is in a single file for ease of installation and to remind me to keep it short and simple.
-
-I'm also sharing my generic .vimrc, which doesn't use Lua and works with both Neovim and Vim 9:
-
-{{{
- curl https://codewiz.org/pub/dotfiles/vimrc
-}}}
-
-Rather than overwrite your existing ##~./vimrc##, you might want to review and take some of my settings
-for syntax highlighting and smart indentation.
-
-
-=== Packer ====
-
-On first run, Packer (the plugin manager) will bootstrap itself and install all plugins.
-There's a good chance this will fail the first time due to the asynchronous nature of PackerSync
-(patches welcome!)
-
-Any time you edit the list of plugins, run ##:PackerSync## to install, uninstall & update them. Easy!
-
-=== Language Servers ===
-
-Neovim 0.7 comes with a built-in LSP client. The official [[https://github.com/neovim/nvim-lspconfig | nvim-lspconfig]]
-plugin abstracts the details of spawning the correct Language Server for a multitude of filetypes.
-
-Download and installation of language servers can be managed automatically by
-[[https://github.com/williamboman/nvim-lsp-installer | nvim-lsp-installer]], but I find that it's
-simpler (and much safer!) to install the already packaged ones from Linux distro. This also ensures
-that they stay aligned with the system toolchain.
-
- * Rust: rust-analyzer
- * C++: clangd
- * Python: python-lsp-server (which uses mypy, pylint, autopep8...)
-
-=== Treesitter syntax parsers ===
-
-Install the ones you like from this list: https://github.com/nvim-treesitter/nvim-treesitter#supported-languages
-
-For instance, I installed these:
-
-{{{
-:TSInstall cpp rust lua python bash vim
-}}}
-
-You can refresh your parsers at any time with ##:TSUpdate##
-
-=== Semantic completion ===
-
-Just press TAB!
-
-TODO: docs for [[https://github.com/hrsh7th/nvim-cmp#readme | cmp-nvim]]
-
-
-=== Finding and opening files ===
-
-{{nvim-telescope.png | maxwidth=400}}
-
-
-TODO: docs for [[https://github.com/nvim-telescope/telescope.nvim | telescope.nvim]]
-
-=== Realtime diagnostics and hints ===
-
-TODO: document
+++ /dev/null
---
--- “This is the editor of a Real Coder.
--- Not as clumsy as a full blown IDE.
--- An elegant editor for a more civilized age.”
--- ― Bernie Innocenti, https://codewiz.org
---
-
--- Set this to replace GitHub default URLs
--- local github_url = 'https://github.com/'
-local github_url = 'git@github.com:'
-
--- Bootstrap Packer if not already installed
-local fn = vim.fn
-local install_path = fn.stdpath('data')..'/site/pack/packer/start/packer.nvim'
-if fn.empty(fn.glob(install_path)) > 0 then
- local packer_url = github_url .. "wbthomason/packer.nvim"
- print("Bootstrapping packer from ", packer_url)
- packer_bootstrap = fn.system({'git', 'clone', '--depth', '1', packer_url, install_path})
-end
-
-require('packer').startup({function(use)
- use 'wbthomason/packer.nvim'
- use { 'nvim-treesitter/nvim-treesitter',
- run = function() require('nvim-treesitter.install').update({ with_sync = true }) end, }
- use { 'nvim-telescope/telescope.nvim', requires = { {'nvim-lua/plenary.nvim'} } }
- use { 'nvim-lualine/lualine.nvim', requires = { 'kyazdani42/nvim-web-devicons', opt = true } }
- use { 'kyazdani42/nvim-tree.lua', requires = { 'kyazdani42/nvim-web-devicons', }, tag = 'nightly' }
- use 'dstein64/nvim-scrollview'
-
- use 'neovim/nvim-lspconfig'
- use 'hrsh7th/cmp-nvim-lsp'
- use 'hrsh7th/cmp-buffer'
- use 'hrsh7th/cmp-path'
- use 'hrsh7th/cmp-cmdline'
- use 'hrsh7th/nvim-cmp'
- use 'hrsh7th/cmp-vsnip'
- use 'hrsh7th/vim-vsnip'
- -- use 'hrsh7th/cmp-nvim-lsp-signature-help'
- use "ray-x/lsp_signature.nvim"
-
- if packer_bootstrap then
- -- FIXME: this runs asynchronously, causing the rest of the
- -- lua script to fail on first run
- require('packer').sync()
- end
-end,
-config = {
- git = { default_url_format = github_url .. '%s.git' }
-}})
-
--- nvim-treesitter --
-
-if github_url ~= nil then
- -- Replace GitHub url for all treesitter plugins
- for _, config in pairs(require("nvim-treesitter.parsers").get_parser_configs()) do
- config.install_info.url = config.install_info.url:gsub("https://github.com/", github_url)
- end
-end
-
-require("nvim-treesitter.install").prefer_git = true
-require("nvim-treesitter.configs").setup {
- highlight = {
- enable = true,
- },
-}
-
-local opts = { noremap=true, silent=true }
-local map = vim.api.nvim_set_keymap
-
-require("telescope").setup()
-map('n', '<C-p>', '<cmd>Telescope git_files<cr>', opts)
-map('n', 'ff', '<cmd>Telescope find_files<cr>', opts)
-map('n', 'fg', '<cmd>Telescope live_grep<cr>', opts)
-map('n', 'fb', '<cmd>Telescope buffers<cr>', opts)
-map('n', 'fh', '<cmd>Telescope help_tags<cr>', opts)
-
-require("nvim-tree").setup()
-map('n', 'o', ':NvimTreeFocus<CR>', opts)
-map('n', '<S-o>', ':NvimTreeClose<CR>', opts)
-map('n', '<C-o>', ':NvimTreeFindFile<CR>', opts)
-
-require('lualine').setup {
- options = {
- theme = 'codedark',
- section_separators = { left = '', right = '' },
- component_separators = { left = '', right = '' },
- -- section_separators = '', component_separators = '',
- show_filename_only = false,
- globalstatus = false,
- },
- sections = {
- lualine_a = {
- { 'mode', fmt = function(str) return str:sub(1,1) end }
- },
- lualine_b = {
- { 'branch', fmt = function(branch) return branch == 'master' and '' or branch end },
- },
- lualine_c = {
- { 'filename', path = 1, },
- },
- lualine_x = {
- { 'filetype', icon_only = true, },
- },
- lualine_y = {},
- },
-}
-
--- nvim-cmp --
-
-local kind_icons = {
- Text = "",
- Method = "",
- Function = "",
- Constructor = "",
- Field = "",
- Variable = "",
- Class = "ﴯ",
- Interface = "",
- Module = "",
- Property = "ﰠ",
- Unit = "",
- Value = "",
- Enum = "",
- Keyword = "",
- Snippet = "",
- Color = "",
- File = "",
- Reference = "",
- Folder = "",
- EnumMember = "",
- Constant = "",
- Struct = "",
- Event = "",
- Operator = "",
- TypeParameter = ""
-}
-
-local has_words_before = function()
- local line, col = unpack(vim.api.nvim_win_get_cursor(0))
- return col ~= 0 and vim.api.nvim_buf_get_lines(0, line - 1, line, true)[1]:sub(col, col):match("%s") == nil
-end
-
-local feedkey = function(key, mode)
- vim.api.nvim_feedkeys(vim.api.nvim_replace_termcodes(key, true, true, true), mode, true)
-end
-
-local cmp = require'cmp'
-cmp.setup({
- -- view = { entries = "native" },
- formatting = {
- fields = {
- "kind",
- "abbr",
- "menu",
- },
- format = function(entry, vim_item)
- vim_item.kind = kind_icons[vim_item.kind]
- local max_width = 25
- if vim_item.menu ~= nil and string.len(vim_item.menu) > max_width then
- vim_item.menu = string.sub(vim_item.menu, 1, max_width - 1) .. "…"
- end
- return vim_item
- end,
- },
- snippet = {
- -- REQUIRED - you must specify a snippet engine
- expand = function(args)
- vim.fn["vsnip#anonymous"](args.body) -- For `vsnip` users.
- end,
- },
- mapping = cmp.mapping.preset.insert({
- ['<C-b>'] = cmp.mapping(cmp.mapping.scroll_docs(-4), { 'i', 'c' }),
- ['<C-f>'] = cmp.mapping(cmp.mapping.scroll_docs(4), { 'i', 'c' }),
- ['<C-Space>'] = cmp.mapping(cmp.mapping.complete(), { 'i', 'c' }),
- ['<C-y>'] = cmp.config.disable, -- Specify `cmp.config.disable` if you want to remove the default `<C-y>` mapping.
- ['<C-e>'] = cmp.mapping({
- i = cmp.mapping.abort(),
- c = cmp.mapping.close(),
- }),
- ['<CR>'] = cmp.mapping.confirm({ select = true }),
-
- ["<Tab>"] = cmp.mapping(function(fallback)
- if cmp.visible() then
- cmp.select_next_item()
- elseif vim.fn["vsnip#available"](1) == 1 then
- feedkey("<Plug>(vsnip-expand-or-jump)", "")
- elseif has_words_before() then
- cmp.complete()
- else
- fallback() -- Sends a already mapped key. In this case, it's probably `<Tab>`.
- end
- end, { "i", "s" }),
-
- ["<S-Tab>"] = cmp.mapping(function()
- if cmp.visible() then
- cmp.select_prev_item()
- elseif vim.fn["vsnip#jumpable"](-1) == 1 then
- feedkey("<Plug>(vsnip-jump-prev)", "")
- end
- end, { "i", "s" }),
- }),
- sources = cmp.config.sources({
- { name = 'nvim_lsp' },
- -- { name = 'nvim_lsp_signature_help', },
- }, {
- { name = 'vsnip' },
- -- { name = 'buffer' },
- })
-})
-
--- cmp.setup.cmdline('/', {
--- mapping = cmp.mapping.preset.cmdline(),
--- completion = {
--- keyword_length = 2,
--- },
--- sources = {
--- { name = 'buffer' }
--- }
---})
-
-cmp.setup.cmdline(':', {
- mapping = cmp.mapping.preset.cmdline(),
- completion = {
- keyword_length = 2,
- },
- sources = cmp.config.sources({
- { name = 'path' }
- }, {
- { name = 'cmdline' }
- })
-})
-
-
-local capabilities = vim.lsp.protocol.make_client_capabilities()
-capabilities = require('cmp_nvim_lsp').update_capabilities(capabilities)
-
--- Disable snippets support for rust-analyzer because it spams the completion
-capabilities.textDocument.completion.completionItem.snippetSupport = false
--- print(vim.inspect(capabilities))
-
--- lsp-config --
-
--- vim.lsp.set_log_level("debug")
-vim.diagnostic.config({
- underline = true,
- virtual_text = false,
- update_in_insert = false,
- float = {
- focusable = false,
- style = 'minimal',
- border = 'rounded',
- source = 'always',
- header = '',
- prefix = '',
- }
-})
-
-local on_attach = function(client, bufnr)
- local function buf_set_keymap(...) vim.api.nvim_buf_set_keymap(bufnr, ...) end
- local function buf_set_option(...) vim.api.nvim_buf_set_option(bufnr, ...) end
-
- buf_set_option("formatexpr", "v:lua.vim.lsp.formatexpr()")
- buf_set_option("omnifunc", "v:lua.vim.lsp.omnifunc")
- buf_set_option("tagfunc", "v:lua.vim.lsp.tagfunc")
-
- vim.opt.completeopt = {"menu", "menuone", "noinsert"}
-
- require "lsp_signature".on_attach({
- hi_parameter = "IncSearch"
- })
-
- local opts = { noremap=true, silent=true }
- -- See `:help vim.lsp.*` for documentation on any of the below functions
- buf_set_keymap('n', 'gD', '<Cmd>lua vim.lsp.buf.declaration()<CR>', opts)
- buf_set_keymap('n', '<C-]>', '<Cmd>lua vim.lsp.buf.declaration()<CR>', opts)
- buf_set_keymap('n', 'gd', '<Cmd>lua vim.lsp.buf.definition()<CR>', opts)
- buf_set_keymap('n', 'K', '<Cmd>lua vim.lsp.buf.hover()<CR>', opts)
- buf_set_keymap('n', 'gi', '<cmd>lua vim.lsp.buf.implementation()<CR>', opts)
- buf_set_keymap('n', '<C-k>', '<cmd>lua vim.lsp.buf.signature_help()<CR>', opts)
- buf_set_keymap('n', '<space>wa', '<cmd>lua vim.lsp.buf.add_workspace_folder()<CR>', opts)
- buf_set_keymap('n', '<space>wr', '<cmd>lua vim.lsp.buf.remove_workspace_folder()<CR>', opts)
- buf_set_keymap('n', '<space>wl', '<cmd>lua print(vim.inspect(vim.lsp.buf.list_workspace_folders()))<CR>', opts)
- buf_set_keymap('n', '<space>D', '<cmd>lua vim.lsp.buf.type_definition()<CR>', opts)
- buf_set_keymap('n', '<space>rn', '<cmd>lua vim.lsp.buf.rename()<CR>', opts)
- buf_set_keymap('n', '<space>ca', '<cmd>lua vim.lsp.buf.code_action()<CR>', opts)
- buf_set_keymap('n', 'gr', '<cmd>lua vim.lsp.buf.references()<CR>', opts)
-
- buf_set_keymap('n', '<space>e', '<cmd>lua vim.diagnostic.open_float()<CR>', opts)
- buf_set_keymap('n', '<space>q', '<cmd>lua vim.diagnostic.setloclist()<CR>', opts)
- buf_set_keymap('n', '[d', '<cmd>lua vim.diagnostic.goto_prev()<CR>', opts)
- buf_set_keymap('n', ']d', '<cmd>lua vim.diagnostic.goto_next()<CR>', opts)
-
- buf_set_keymap('n', "=", "<cmd>lua vim.lsp.buf.formatting()<CR>", opts)
- buf_set_keymap('v', "=", "<cmd>lua vim.lsp.buf.formatting()<CR>", opts)
- buf_set_keymap('n', "gq", "<cmd>lua vim.lsp.buf.formatting()<CR>", opts)
- buf_set_keymap('v', "gq", "<cmd>lua vim.lsp.buf.formatting()<CR>", opts)
-end
-
-local lspconfig = require'lspconfig';
-lspconfig.rust_analyzer.setup{
- on_attach = on_attach,
- capabilities = capabilities,
-}
-lspconfig.tsserver.setup{
- on_attach = on_attach,
- capabilities = capabilities,
-}
-lspconfig.clangd.setup{
- on_attach = on_attach,
- capabilities = capabilities,
- -- cmd = { vim.loop.os_homedir() .. "clangd", "--background-index" },
- cmd = { "clangd", "--background-index" },
- root_dir = lspconfig.util.root_pattern("compile_commands.json", "compile_flags.txt"),
-}
-lspconfig.pylsp.setup{
- on_attach = on_attach,
- capabilities = capabilities,
- settings = {
- pylsp = {
- configurationSources = {"pylint"},
- plugins = {
- autopep8 = { enabled = true },
- mypy = { enabled = true },
- pylint = { enabled = true },
- flake8 = { enabled = false },
- pycodestyle = { enabled = false },
- pyflakes = { enabled = false },
- }
- }
- }
-}
-
--- Alt-key window navication and more
-map('t', '<A-h>', '<C-\\><C-n>h', opts)
-map('t', '<A-j>', '<C-\\><C-n>j', opts)
-map('t', '<A-k>', '<C-\\><C-n>k', opts)
-map('t', '<A-l>', '<C-\\><C-n>l', opts)
-map('i', '<A-h>', '<C-\\><C-n>h', opts)
-map('i', '<A-j>', '<C-\\><C-n>j', opts)
-map('i', '<A-k>', '<C-\\><C-n>k', opts)
-map('i', '<A-l>', '<C-\\><C-n>l', opts)
-map('n', '<A-h>', '<C-w>h', opts)
-map('n', '<A-j>', '<C-w>j', opts)
-map('n', '<A-k>', '<C-w>k', opts)
-map('n', '<A-l>', '<C-w>l', opts)
-
-/*
- * Author: Gerardo Poggiali <g.poggiali@develer.com>
- * Author: Bernie Innocenti <bernie@codewiz.org>
- */
+/* Author: Bernie Innocenti <bernie@codewiz.org> */
body {
- font-family: sans-serif;
- background-color: #F0F0F8;
- color: #000000;
- margin-top: 0px;
- margin-left: 0px;
- margin-right: 0px;
+ font-family: sans-serif;
+ background-color: #F0F0F8;
+ color: #000000;
+ margin-top: 0px;
+ margin-left: 0px;
+ margin-right: 0px;
}
html {
- cursor: url('/wiki/sys/pointer.cur'), auto;
+ cursor: url('/wiki/sys/amiga-pointer-2.0.cur'), auto;
}
a { color: #1010FF; }
a.heading { text-decoration: none; color: #aaaaaa; font-size: smaller; }
h1 {
- font-size: x-large;
- font-weight: bold;
- clear: both;
- color: #3377FF;
- border: #5599EE;
- background-color: #D0F0FF;
- clear: both;
-
- margin-bottom: 0.2em;
- margin-top: 2em;
- padding-right: 10px;
- padding-left: 10px;
+ font-size: x-large;
+ font-weight: bold;
+ clear: both;
+ color: #3377FF;
+ border: #5599EE;
+ background-color: #D0F0FF;
+ clear: both;
+ margin-bottom: 0.2em;
+ margin-top: 2em;
+ padding-right: 10px;
+ padding-left: 10px;
}
h2 {
- font-size: large;
- font-weight: bold;
- clear: both;
- color: #22AA33;
-
- margin-left: 5px;
- margin-right: 5px;
- margin-bottom: 0.1em;
- margin-top: 1.5em;
- padding-right: 10px;
- padding-left: 10px;
+ font-size: large;
+ font-weight: bold;
+ clear: both;
+ color: #22AA33;
+ margin-left: 5px;
+ margin-right: 5px;
+ margin-bottom: 0.1em;
+ margin-top: 1.5em;
+ padding-right: 10px;
+ padding-left: 10px;
}
h3 {
- font-size: large;
- font-weight: bold;
- color: #113366;
-
- margin-left: 10px;
- margin-right: 10px;
- padding-right: 5px;
- padding-left: 5px;
+ font-size: large;
+ font-weight: bold;
+ color: #113366;
+ margin-left: 10px;
+ margin-right: 10px;
+ padding-right: 5px;
+ padding-left: 5px;
}
h4 {
- font-size: medium;
- font-weight: bold;
- color: #222288;
-
- margin-left: 10px;
- margin-right: 10px;
- padding-right: 5px;
- padding-left: 5px;
+ font-size: medium;
+ font-weight: bold;
+ color: #222288;
+ margin-left: 10px;
+ margin-right: 10px;
+ padding-right: 5px;
+ padding-left: 5px;
}
h5 {
- font-size: medium;
- font-weight: normal;
- color: #4444AA;
-
- margin-left: 10px;
- margin-right: 10px;
- padding-right: 5px;
- padding-left: 5px;
+ font-size: medium;
+ font-weight: normal;
+ color: #4444AA;
+ margin-left: 10px;
+ margin-right: 10px;
+ padding-right: 5px;
+ padding-left: 5px;
}
/* Heading anchors */
.heading:link, .heading:visited {
- border: none;
- color: #d7d7d7;
- font-size: .8em;
- vertical-align: text-top;
+ border: none;
+ color: #d7d7d7;
+ font-size: .8em;
+ vertical-align: text-top;
}
* > .heading:link, * > .heading:visited {
- visibility: hidden;
+ visibility: hidden;
}
h1:hover .heading, h2:hover .heading, h3:hover .heading,
h4:hover .heading, h5:hover .heading, h6:hover .heading {
- visibility: visible;
+ visibility: visible;
}
strong.DONE {
- padding-left: 0.1em;
- background-color: #22ee22;
+ padding-left: 0.1em;
+ background-color: #22ee22;
}
strong.TODO {
- padding-left: 0.1em;
- background-color: #ffdd44;
+ padding-left: 0.1em;
+ background-color: #ffdd44;
}
strong.FIXME {
- padding-left: 0.1em;
- background-color: #ee2222;
+ padding-left: 0.1em;
+ background-color: #ee2222;
}
strong.error {
- color: red;
+ color: red;
}
div {
- margin-left: 10px;
- margin-right: 10px;
- /*text-align: justify;*/
+ margin-left: 10px;
+ margin-right: 10px;
+ /*text-align: justify;*/
}
div.wiki {
- margin-left: 0px;
- margin-right: 0px;
+ margin-left: 0px;
+ margin-right: 0px;
}
div.preview {
- border: 2px dashed #FF0000;
+ border: 2px dashed #FF0000;
}
div.index {
- border: 1px solid #EEEEEE;
+ border: 1px solid #EEEEEE;
}
div.nav {
- /*border-color: #88aacc;
- background-color: #aaccee;*/
- border-color: #888888;
- background-color: #cccccc;
- border-style: solid
- border-top-width: 0px;
- border-bottom-width: 2px;
- border-left-width: 0px;
- border-right-width: 0px;
- padding-top: 5px;
- padding-bottom: 5px;
- padding-left: 5px;
- padding-right: 5px;
- margin-top: 0px;
- margin-bottom: 10px;
- margin-left: 0px;
- margin-right: 0px;
+ border-color: #888888;
+ background-color: #cccccc;
+ border-style: solid;
+ border-top-width: 0px;
+ border-bottom-width: 1px;
+ border-left-width: 0px;
+ border-right-width: 0px;
+ padding-top: 5px;
+ padding-bottom: 5px;
+ padding-left: 5px;
+ padding-right: 5px;
+ margin-top: 0px;
+ margin-bottom: 10px;
+ margin-left: 0px;
+ margin-right: 0px;
}
.nav li {
- display: inline;
+ display: inline;
}
.nav ul
{
- list-style-type: none;
- margin: 0;
- padding: 0;
- padding-top: 6px;
- padding-bottom: 6px;
+ list-style-type: none;
+ margin: 0;
+ padding: 0;
+ padding-top: 6px;
+ padding-bottom: 6px;
}
-
.nav hr {
- display: none;
+ display: none;
}
#footer div {
- margin-top: 1em;
- margin-left: 0;
- margin-right: 0;
+ margin-top: 1em;
+ margin-left: 0;
+ margin-right: 0;
}
#footer hr {
- border: none;
- border-top: 1px solid #bbbbbb;
- margin: 0 0;
- clear: both;
+ border: none;
+ border-top: 1px solid #bbbbbb;
+ margin: 0 0;
+ clear: both;
}
#footer :link, #footer :visited {
- color: #666666;
+ color: #666666;
}
#footer p {
- color: #888888;
- font-size: x-small;
- margin-top: 0;
+ color: #888888;
+ font-size: x-small;
+ margin-top: 0;
}
#footer p.copyright {
- float: left;
- margin-left: 0em;
- padding: 0 1em;
+ float: left;
+ margin-left: 0em;
+ padding: 0 1em;
}
#footer .license {
- border-width: 0;
- vertical-align: top;
- margin-left: 0em;
- margin-right: 1em;
+ border-width: 0;
+ vertical-align: top;
+ margin-left: 0em;
+ margin-right: 1em;
}
#footer p.modified {
- float: right;
- text-align: right;
- margin-right: 1em;
+ float: right;
+ text-align: right;
+ margin-right: 1em;
}
p.dialog {
- border-color: black;
- background-color: white;
- padding-left: 5px;
- margin-left: 10px;
- margin-right: 10px;
- border-style: solid;
- border-top-width: 1px;
- border-right-width: 1px;
- border-bottom-width: 1px;
- border-left-width: 1px
+ border-color: black;
+ background-color: white;
+ padding-left: 5px;
+ margin-left: 10px;
+ margin-right: 10px;
+ border-style: solid;
+ border-top-width: 1px;
+ border-right-width: 1px;
+ border-bottom-width: 1px;
+ border-left-width: 1px
}
p {
- margin-left: 1em;
- margin-right: 1em;
- margin-bottom: 1em;
- /*text-align: justify;*/
+ margin-left: 1em;
+ margin-right: 1em;
+ margin-bottom: 1em;
+ /*text-align: justify;*/
}
table {
- /*width: 100%;*/
- border: 2px solid #ccc;
- border-collapse: collapse;
- margin-left: 1em;
- margin-right: 1em;
- margin-top: 0.5em;
- margin-bottom: 0.5em;
+ /*width: 100%;*/
+ border: 2px solid #ccc;
+ border-collapse: collapse;
+ margin-left: 1em;
+ margin-right: 1em;
+ margin-top: 0.5em;
+ margin-bottom: 0.5em;
}
table tbody thead {
- background: #f7f7f0
+ background: #f7f7f0;
}
/* FIXME: should be thead */
table tbody th {
- border: 1px solid #d7d7d7;
- border-bottom-color: #999;
- font-weight: bold;
- padding: 2px .5em;
- vertical-align: bottom;
+ border: 1px solid #d7d7d7;
+ border-bottom-color: #999;
+ font-weight: bold;
+ padding: 2px .5em;
+ vertical-align: bottom;
}
table tbody td {
- border: 1px dotted #ddd;
- padding: .3em .5em;
- vertical-align: top;
+ border: 1px dotted #ddd;
+ padding: .3em .5em;
+ vertical-align: top;
}
table tbody tr { border-top: 1px solid #ddd }
table tbody tr:hover { background: #eed !important }
table thead th :link:hover, table thead th :visited:hover table tbody td a:hover, table tbody th a:hover {
- background-color: transparent;
+ background-color: transparent;
}
pre {
- color: #222222;
- border-color: #E9E609;
- background: #FFFDD0;
-
- margin-left: 10px;
- margin-right: 10px;
- padding-left: 5px;
- padding-right: 5px;
- padding-top: 5px;
- padding-bottom: 5px;
- border-style: solid;
- border-top-width: 1px;
- border-right-width: 1px;
- border-bottom-width: 1px;
- border-left-width: 1px;
+ color: #222222;
+ border-color: #E9E609;
+ background: #FFFDD0;
+ margin-left: 10px;
+ margin-right: 10px;
+ padding-left: 5px;
+ padding-right: 5px;
+ padding-top: 5px;
+ padding-bottom: 5px;
+ border-style: solid;
+ border-top-width: 1px;
+ border-right-width: 1px;
+ border-bottom-width: 1px;
+ border-left-width: 1px;
}
pre.error {
- color: #FF0000;
- background: #000000;
- border-top-color: #FF0000;
- border-color: #FF0000;
- border-style: solid;
- border-width: 6px;
- margin: 0px;
+ color: #FF0000;
+ background: #000000;
+ border-top-color: #FF0000;
+ border-color: #FF0000;
+ border-style: solid;
+ border-width: 6px;
+ margin: 0px;
}
pre.success {
- color: #00FF00;
- background: #000000;
- border-color: #00FF00;
- border-style: solid;
- border-width: 6px;
- margin: 0px;
+ color: #00FF00;
+ background: #000000;
+ border-color: #00FF00;
+ border-style: solid;
+ border-width: 6px;
+ margin: 0px;
}
pre.notice {
- color: #FFCC00;
- background: #000000;
- border-color: #FFCC00;
- border-style: solid;
- border-width: 6px;
- margin: 0px;
+ color: #FFCC00;
+ background: #000000;
+ border-color: #FFCC00;
+ border-style: solid;
+ border-width: 6px;
+ margin: 0px;
}
.editor input[type='text'], .editor textarea {
- font-family: monospace;
- color: black;
- background-color: white;
- border: 1px solid #8cacbb;
+ font-family: monospace;
+ color: black;
+ background-color: white;
+ border: 1px solid #8cacbb;
}
.editor textarea.editor { width: 100%; }
.editor input.changelog { width: 50%; }
/* thumbnails */
div .thumb {
- float: left;
- width: 100%;
+ float: left;
+ width: 100%;
}
-
-div .thumbleft {
- float: left;
-}
-
-div .thumbright {
- float: right;
-}
-
+div .thumbleft { float: left; }
+div .thumbright { float: right; }
div .innerthumb {
- float: left;
- border: 1px solid #ccc;
- padding: 3px !important;
- margin: 10px;
- margin-bottom: .5em;
- background-color: #f9f9f9;
- text-align: center;
+ float: left;
+ border: 1px solid #ccc;
+ padding: 3px !important;
+ margin: 10px;
+ margin-bottom: .5em;
+ background-color: #f9f9f9;
+ text-align: center;
}
.thumb a img, .thumbright a img, .thumbleft a img {
- border: 1px solid #ccc;
- vertical-align:bottom;
+ border: 1px solid #ccc;
+ vertical-align:bottom;
}
.thumb .caption, .thumbright .caption, .thumbleft .caption {
- border: none;
- overflow: hidden;
- font-size: 60%;
- line-height: 1.4em;
- padding: .3em 0 .1em 0;
- text-align: center;
+ border: none;
+ overflow: hidden;
+ font-size: 60%;
+ line-height: 1.4em;
+ padding: .3em 0 .1em 0;
+ text-align: center;
}
/* Styles for search word highlighting */
@media screen {
- .searchword0 { background: #ff9 }
- .searchword1 { background: #cfc }
- .searchword2 { background: #cff }
- .searchword3 { background: #ccf }
- .searchword4 { background: #fcf }
+ .searchword0 { background: #ff9 }
+ .searchword1 { background: #cfc }
+ .searchword2 { background: #cff }
+ .searchword3 { background: #ccf }
+ .searchword4 { background: #fcf }
}
@media print {
- body {
- background: white;
- font-size: 12pt;
- }
- h1 { font-size: 14pt; }
- h2 { font-size: 13pt; }
- h3 { font-size: 12pt; border: none; }
- h4 { font-size: 12pt; border: none; }
- h5 { font-size: 12pt; border: none; }
- a { text-color: #225; text-decoration: underline; }
- .heading:link, .heading:visited { display: none; }
- #footer { display: none; }
- .nav { display: none; }
- .noprint { display: none; }
- div.wiki { font-size: smaller; }
+ body {
+ background: white;
+ font-size: 12pt;
+ }
+ h1 { font-size: 14pt; }
+ h2 { font-size: 13pt; }
+ h3 { font-size: 12pt; border: none; }
+ h4 { font-size: 12pt; border: none; }
+ h5 { font-size: 12pt; border: none; }
+ a { text-color: #225; text-decoration: underline; }
+ .heading:link, .heading:visited { display: none; }
+ #footer { display: none; }
+ .nav { display: none; }
+ .noprint { display: none; }
+ div.wiki { font-size: smaller; }
+}
+
+@media (prefers-color-scheme: dark) {
+ body {
+ background-color: #181818;
+ color: #ffffff;
+ }
+
+ a { color: #9bd1ff; }
+ a:visited { color: #9b669b; }
+ a.nonexistent { color: #f0d0d0; }
+ a.navlink { color: #d1d1ff; }
+ a.login { color: #bb6666; }
+
+ div.nav {
+ border-color: #606060;
+ background-color: #303030;
+ }
+
+ body {
+ background-color: #181818;
+ color: #FFFFFF;
+ }
+
+ a { color: #9Bd1ff; }
+ a:visited { color: #778899; }
+ a.nonexistent { color: #f0d0d0; }
+ a.navlink { color: #d1d1ff; }
+ a.login { color: #cc5555; }
+ a.heading { text-decoration: none; color: #666666; font-size: smaller; }
+
+ h1 {
+ color: #88bbff;
+ border: #77aadd;
+ background-color: #2a2a2a;
+ }
+ h2 { color: #44dd66; }
+ h3 { color: #88aacc; }
+ h4 { color: #8899bb; }
+ h5 { color: #6666cc; }
+
+ div.nav {
+ border-color: #606060;
+ background-color: #303030;
+ }
+ div.preview { border: 2px dashed #cc2222; }
+
+ pre {
+ color: #dddddd;
+ border-color: #999900;
+ background: #1a1a1a;
+ }
+
+ pre.error {
+ color: #FF5555;
+ background: #222222;
+ border-top-color: #ff5555;
+ border-color: #ff5555;
+ }
+
+ pre.success {
+ color: #55ff55;
+ background: #222222;
+ border-color: #55ff55;
+ }
+
+ pre.notice {
+ color: #ffdd55;
+ background: #222222;
+ border-color: #ffdd55;
+ }
+
+ .editor input[type='text'], .editor textarea {
+ color: #ffffff;
+ background-color: #2a2a2a;
+ border: 1px solid #8cacbb;
+ }
+
+ table { border: 2px solid #444; }
+ table tbody thead { background: #2f2f2f; }
+ table tbody th {
+ border: 1px solid #555;
+ border-bottom-color: #777;
+ }
+ table tbody td { border: 1px dotted #555; }
+ table tbody tr { border-top: 1px solid #555; }
+ table tbody tr.even { background-color: #303030; }
+ table tbody tr.odd { background-color: #393939; }
+ table tbody tr:hover { background: #444 !important; }
}
+++ /dev/null
-" Copyright 2004, 2005, 2008 Develer S.r.l. (http://www.develer.com/)
-" Copyright 2009-2022 Bernie Innocenti <bernie@codewiz.org>
-"
-" Author: Bernie Innocenti <bernie@codewiz.org>
-" Author: Simone Zinanni <s.zinanni@develer.com>
-" Author: Stefano Fedrigo <aleph@develer.com>
-" Author: Daniele Varrazzo <piro@develer.com>
-"
-" note: to reload this file after a change, use ':so %'
-
-set nocompatible " Use Vim defaults (much better!)
-set bs=indent,eol,start " allow backspacing over everything in insert mode
-set history=1000
-set ruler " show the cursor position all the time
-set laststatus=2 " Always show the status line at the bottom (neovim)
-set clipboard+=unnamed,unnamedplus
-
-augroup fedora
- autocmd!
- " In text files, always limit the width of text to 78 characters
- autocmd BufRead *.txt set tw=78
- " When editing a file, always jump to the last cursor position
- autocmd BufReadPost *
- \ if line("'\"") > 0 && line ("'\"") <= line("$") |
- \ exe "normal! g'\"" |
- \ endif
- " don't write swapfile on most commonly used directories for NFS mounts or USB sticks
- autocmd BufNewFile,BufReadPre /media/*,/run/media/*,/mnt/* set directory=~/tmp,/var/tmp,/tmp
- " start with spec file template
- autocmd BufNewFile *.spec 0r /usr/share/vim/vimfiles/template.spec
-augroup END
-
-" Switch syntax highlighting on, when the terminal has colors
-" Also switch on highlighting the last used search pattern.
-if &t_Co > 2 || has("gui_running")
- syntax on
- " bernie: hilighting long lines is very slow
- set synmaxcol=320
- set hlsearch
- set incsearch
- set background=dark
-
- " bernie: Show matching parenthesis when writing
- set showmatch
- " bernie: add bottom horizontal scroll bar
- set guioptions+=b
- " aleph: remove useless luser toolbar
- set guioptions-=T
-
- " highlighting for embedded LUA in nvim
- let g:vimsyn_embed='l'
-
- " bernie: highlight cursor line
- set cursorline
- set colorcolumn=+1
-
- " Limit modern terminal stuff to known-good terminals
- if has("gui_running") || $KONSOLE_VERSION != '' || $VTE_VERSION != '' || $XTERM_VERSION != '' || $WEZTERM_EXECUTABLE != ''
- if has('termguicolors')
- set termguicolors
- endif
- colorscheme darkblue
-
- highlight Normal ctermfg=248 ctermbg=NONE guibg=#000818 guifg=#eeeeee
- highlight Visual guibg=fg guifg=#4040d0 gui=reverse
-
- " Make the splits look pretty
- highlight VertSplit guibg=#001111 guifg=#224422
-
- " bernie: blinky cursor!
- " let &guicursor = &guicursor . ',a:blinkwait175-blinkoff10-blinkon20'
-
- " Enable spelling for comments in various languates
- " bernie: don't enable by default because has too many false positives
- "autocmd FileType c,cpp,java,python,rust,vim,text set spell
- endif
-
- " Make the wrap column and cursor line more discrete
- highlight CursorLine term=NONE cterm=NONE ctermbg=233 guibg=#001133
- highlight CursorColumn term=NONE cterm=NONE ctermbg=233 guibg=#000820
- highlight ColorColumn term=NONE cterm=NONE ctermbg=233 guibg=#200818
-
- " The autocomplete menu
- highlight Pmenu ctermfg=250 ctermbg=240 guifg=#ABB2BF guibg=#282C34
- highlight PmenuSel ctermfg=253 ctermbg=245 guifg=#353B45 guibg=#A3BE8C
- highlight PmenuSbar ctermbg=248 guibg=#353b45
- highlight PmenuThumb ctermbg=15 guibg=#81A1C1
-
- highlight! CmpItemAbbrDeprecated guibg=NONE gui=strikethrough guifg=#808080
- highlight! CmpItemAbbrMatch guibg=NONE guifg=#569CD6
- highlight! CmpItemAbbrMatchFuzzy guibg=NONE guifg=#569CD6
- highlight! CmpItemKindVariable guibg=NONE guifg=#9CDCFE
- highlight! CmpItemKindInterface guibg=NONE guifg=#9CDCFE
- highlight! CmpItemKindText guibg=NONE guifg=#9CDCFE
- highlight! CmpItemKindFunction guibg=NONE guifg=#C586C0
- highlight! CmpItemKindMethod guibg=NONE guifg=#C586C0
- highlight! CmpItemKindKeyword guibg=NONE guifg=#D4D4D4
- highlight! CmpItemKindProperty guibg=NONE guifg=#D4D4D4
- highlight! CmpItemKindUnit guibg=NONE guifg=#D4D4D4
-
- highlight DiagnosticVirtualTextHint guifg=#444444
- highlight DiagnosticVirtualTextWarn guifg=#884400
- highlight DiagnosticVirtualTextError guifg=#880000
- highlight DiagnosticUnderlineHint gui=NONE
- highlight DiagnosticUnderlineWarn cterm=undercurl ctermfg=Brown gui=undercurl guisp=#884400
- highlight DiagnosticUnderlineError cterm=undercurl ctermfg=Red gui=undercurl guisp=#880000
-
- sign define DiagnosticSignError text= linehl= texthl=DiagnosticSignError numhl=
- sign define DiagnosticSignWarn text= linehl= texthl=DiagnosticSignWarn numhl=
- sign define DiagnosticSignInfo text= linehl= texthl=DiagnosticSignInfo numhl=
- sign define DiagnosticSignHint text=? linehl= texthl=DiagnosticSignHint numhl=
- autocmd CursorHold,CursorHoldI * lua vim.diagnostic.open_float(nil, {scope = "line", focus = false})
-
- " Undercurl speling erors in terminal and gui
- " let &t_Cs = "\e[4:3m"
- " let &t_Ce = "\e[4:0m"
- highlight SpellBad term=NONE cterm=undercurl ctermfg=Red ctermbg=NONE guifg=NONE gui=undercurl guisp=Red
- highlight SpellCap term=NONE cterm=undercurl ctermfg=Yellow ctermbg=NONE guifg=NONE gui=undercurl guisp=Yellow
- highlight SpellRare term=NONE cterm=undercurl ctermfg=Blue ctermbg=NONE guifg=NONE gui=undercurl guisp=Blue
- highlight SpellLocal term=NONE cterm=undercurl ctermfg=Brown ctermbg=NONE guifg=NONE gui=undercurl guisp=Brown
-
- " Highlight extra whitespace in various languages
- autocmd FileType c,cpp,rust highlight ExtraWhitespace ctermbg=DarkRed guibg=DarkRed
-endif
-
-" bernie: insensitive search
-set ignorecase
-" aleph: if pattern contains uppercase chars, the search is case _sensitive_
-set smartcase
-
-" bernie: horizontal and vertical scrolling
-set nowrap
-set sidescroll=1
-set sidescrolloff=3
-set scrolloff=3
-set listchars+=extends:»,precedes:«,trail:-,nbsp:_,tab:\|_
-" set fillchars+=vert:\▏
-set wildmenu
-
-" piro: fix broken Page Up/Down
-" http://vimrc-dissection.blogspot.com/2009/02/fixing-pageup-and-pagedown.html
-map <silent> <PageUp> 1000<C-U>
-map <silent> <PageDown> 1000<C-D>
-imap <silent> <PageUp> <C-O>1000<C-U>
-imap <silent> <PageDown> <C-O>1000<C-D>
-set nostartofline
-
-" bernie: enter in directory browser open files in previous window
-" let g:netrw_browse_split=4
-
-" bernie: write on :n, :r, etc.
-set autowriteall
-
-" aleph: dont't break softlinks (edit destination file), but break hardlinks
-set backupcopy=yes,breakhardlink
-
-" bernie: mouse everywhere!
-if has("mouse")
- set mouse=a
- if !has('nvim')
- set ttymouse=xterm2
- endif
-endif
-
-" bernie: do not create swap files all over the place
-set directory-=.
-
-" bernie: enable persistent undo
-"if has('persistent_undo')
-" let &undodir=&directory
-" set undofile
-"endif
-
-" aleph: per non rompere le p*** a chi sta attorno ogni volta che si sbaglia tasto
-set visualbell
-" aleph: riduce al minimo la dimensione dei buffer non attivi
-set winminheight=0
-" aleph: dopo split e close gli altri buffer non si ridimensionano
-set noequalalways
-" show (partial) command in status line
-set showcmd
-
-" bernie: status line
-set statusline=%<%f%h%m%r%=%b\ 0x%B\ \ %l,%c%V\ %P
-
-" informs sh syntax that /bin/sh is actually bash
-let is_bash=1
-
-" bernie: enable loading filetype specific plugins and indendation modes
-filetype plugin indent on
-set smarttab
-set matchpairs+=<:>
-set shiftround
-set shiftwidth=0 " 0 means same as ts
-
-" bernie: set default indents for various languages
-autocmd FileType c,cpp set ts=4|set expandtab|let c_space_errors=1
-autocmd FileType java set ts=4|set expandtab|let java_space_errors=1|let java_highlight_functions=1
-autocmd FileType rust set ts=4|set expandtab
-autocmd FileType python set ts=4|set expandtab
-autocmd FileType go,lua set ts=2|set expandtab
-autocmd FileType html,css set ts=2|set expandtab
-autocmd FileType javascript,typescript set ts=2|set expandtab
-autocmd FileType vim set ts=2|set expandtab
-
-" bernie: auxiliary named config files
-au BufNewFile,BufRead named.conf.*,named-*.conf setf named
-
-" piro: treat arduino projects as C++ files.
-autocmd BufRead *.pde set filetype=cpp
-
-" bernie: bind '#' to 'grep word under cursor' -- see: http://vim.wikia.com/wiki/Find_in_files_within_Vim
-:map # :execute "vimgrep /" . expand("<cword>") . "/j **" <Bar> cw<CR>
-
-" bernie: search for highlighted text -- see: http://rayninfo.co.uk/vimtips.html
-:vmap // y/<C-R>"<CR>
-
-" piro: no, I don't want your fucking help!
-inoremap <F1> <ESC>
-nnoremap <F1> <ESC>
-vnoremap <F1> <ESC>
-
-" what's ; for anyway?
-noremap ; :
-
-" w!! if you forget to sudo before saving
-cmap w!! w !sudo tee % >/dev/null
-
-" Repeat last command and put cursor at start of change -- http://vim.wikia.com/wiki/VimTip1142
-map . .`[
-
-" Go back to previous file
-map <C-p> <esc>:bp<CR>
-
-" bernie: see http://www.vim.org/scripts/script.php?script_id=3896
-map <F2> :Bufferlist<CR>
-
-" bernie: ex mode is useless and annoying
-map Q <Nop>
-
-" bernie: http://vim.wikia.com/wiki/Edit_gpg_encrypted_files#Comments
-augroup encrypted
- au!
- " Disable swap files, and set binary file format before reading the file
- autocmd BufReadPre,FileReadPre *.gpg
- \ setlocal noswapfile bin
- " Decrypt the contents after reading the file, reset binary file format
- " and run any BufReadPost autocmds matching the file name without the .gpg
- " extension
- autocmd BufReadPost,FileReadPost *.gpg
- \ execute "'[,']!gpg --decrypt --default-recipient-self" |
- \ setlocal nobin |
- \ execute "doautocmd BufReadPost " . expand("%:r")
- " Set binary file format and encrypt the contents before writing the file
- autocmd BufWritePre,FileWritePre *.gpg
- \ setlocal bin |
- \ '[,']!gpg --encrypt --default-recipient-self
- " After writing the file, do an :undo to revert the encryption in the
- " buffer, and reset binary file format
- autocmd BufWritePost,FileWritePost *.gpg
- \ silent u |
- \ setlocal nobin
-augroup END
-
-set updatetime=1000
-set shortmess+=c
-
-if has('persistent_undo')
- let &undodir=&directory
- set undofile
-endif
-
-let g:plug_url_format = 'git@github.com:%s.git'
-call plug#begin('~/.vim/plugged')
- Plug 'wsdjeg/vim-fetch'
- "Plug 'editorconfig/editorconfig-vim'
- Plug 'junegunn/fzf'
- Plug 'junegunn/fzf.vim'
- Plug 'haya14busa/vim-asterisk'
- Plug 'tikhomirov/vim-glsl'
- Plug 'tpope/vim-fugitive'
-call plug#end()
-
-" == FZF ==
-nmap <C-P> :FZF<CR>
-
-
-" == vim-asterisk ==
-let g:asterisk#keeppos = 1
-map * <Plug>(asterisk-*)
-map # <Plug>(asterisk-#)
-map g* <Plug>(asterisk-g*)
-map g# <Plug>(asterisk-g#)
-map z* <Plug>(asterisk-z*)
-map gz* <Plug>(asterisk-gz*)
-map z# <Plug>(asterisk-z#)
-map gz# <Plug>(asterisk-gz#)
-
-
-" == rust.vim ==
-autocmd FileType rust noremap <C-I> gq
-autocmd FileType rust inoremap <C-K> <C-O>gq
-
-if has('nvim')
- set inccommand=nosplit
- set signcolumn=number
-endif " nvim
-
-" source user's local configuration file if available
-if filereadable($HOME . "/.vimrc.local")
- source ~/.vimrc.local
-endif
+++ /dev/null
-local wezterm = require 'wezterm';
-
-return {
- automatically_reload_config = true,
- enable_scroll_bar = true,
-
- -- color_scheme = "Batman",
- -- font = wezterm.font("Lucida Console", {}),
- -- font = wezterm.font("Noto Sans Mono", {}),
- font_size = 9.0,
- harfbuzz_features = {"calt=0", "clig=0", "liga=0"},
-
- audible_bell = "Disabled",
- visual_bell = {
- fade_in_duration_ms = 0,
- fade_out_duration_ms = 50,
- target = "BackgroundColor",
- -- target = "CursorColor",
- },
- colors = {
- cursor_bg = "yellow",
- cursor_fg = "black",
- visual_bell = "#661111",
- split = "#888888",
- },
- window_background_opacity = 1.0,
- window_background_gradient = {
- orientation = "Vertical",
- colors = {
- "#222244",
- "#111133",
- "#110808"
- },
- -- preset = "Warm",
- interpolation = "Linear",
- blend = "Rgb",
- noise = 64,
- -- segment_size = 50,
- -- segment_smoothness = 0.0,
- },
- inactive_pane_hsb = {
- saturation = 0.7,
- brightness = 1.0,
- },
-
- default_prog = {os.getenv("HOME") .. "/bin/zsh"},
- keys = {
- -- {key="r", mods="CMD|SHIFT", action="ReloadConfiguration"},
- {mods="CTRL|SHIFT", key="d", action=wezterm.action{SplitVertical={domain="CurrentPaneDomain"}}},
- {mods="CTRL|SHIFT", key="r", action=wezterm.action{SplitHorizontal={domain="CurrentPaneDomain"}}},
- {mods="CTRL|SHIFT", key="w", action=wezterm.action{CloseCurrentPane={confirm=true}}},
- {mods="CTRL|SHIFT", key="f", action="ToggleFullScreen"},
- },
-
- ssh_domains = {
- {
- name = "desk",
- remote_address = "binnocenti-z2.spacex.corp",
- remote_wezterm_path = "/home/binnocenti/bin/wezterm",
- username = "binnocenti",
- }
- },
- tls_clients = {
- {
- name = "desktls",
- remote_address = "binnocenti-z2.spacex.corp:8080",
- bootstrap_via_ssh = "binnocenti@binnocenti-z2.spacex.corp",
- }
- },
-}
\ No newline at end of file