diff options
| author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2025-11-07 13:31:53 +0000 |
|---|---|---|
| committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2025-11-07 13:31:53 +0000 |
| commit | 8c22ff0d8b70d9b12f0487ef696a7e915b9e3173 (patch) | |
| tree | efdc32587159d0050a69009bdf2330a531727d95 /bitbake/contrib/vim/plugin | |
| parent | d412d2747595c1cc4a5e3ca975e3adc31b2f7891 (diff) | |
| download | poky-8c22ff0d8b70d9b12f0487ef696a7e915b9e3173.tar.gz | |
The poky repository master branch is no longer being updated.
You can either:
a) switch to individual clones of bitbake, openembedded-core, meta-yocto and yocto-docs
b) use the new bitbake-setup
You can find information about either approach in our documentation:
https://docs.yoctoproject.org/
Note that "poky" the distro setting is still available in meta-yocto as
before and we continue to use and maintain that.
Long live Poky!
Some further information on the background of this change can be found
in: https://lists.openembedded.org/g/openembedded-architecture/message/2179
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/contrib/vim/plugin')
| -rw-r--r-- | bitbake/contrib/vim/plugin/newbb.vim | 88 | ||||
| -rw-r--r-- | bitbake/contrib/vim/plugin/newbbappend.vim | 46 |
2 files changed, 0 insertions, 134 deletions
diff --git a/bitbake/contrib/vim/plugin/newbb.vim b/bitbake/contrib/vim/plugin/newbb.vim deleted file mode 100644 index 3a42027361..0000000000 --- a/bitbake/contrib/vim/plugin/newbb.vim +++ /dev/null | |||
| @@ -1,88 +0,0 @@ | |||
| 1 | " Vim plugin file | ||
| 2 | " Purpose: Create a template for new bb files | ||
| 3 | " Author: Ricardo Salveti <rsalveti@gmail.com> | ||
| 4 | " Copyright: Copyright (C) 2008 Ricardo Salveti <rsalveti@gmail.com> | ||
| 5 | " | ||
| 6 | " This file is licensed under the MIT license, see COPYING.MIT in | ||
| 7 | " this source distribution for the terms. | ||
| 8 | " | ||
| 9 | " Based on the gentoo-syntax package | ||
| 10 | " | ||
| 11 | " Will try to use git to find the user name and email | ||
| 12 | |||
| 13 | if &compatible || v:version < 600 || exists("b:loaded_bitbake_plugin") | ||
| 14 | finish | ||
| 15 | endif | ||
| 16 | |||
| 17 | fun! <SID>GetUserName() | ||
| 18 | let l:user_name = system("git config --get user.name") | ||
| 19 | if v:shell_error | ||
| 20 | return "Unknown User" | ||
| 21 | else | ||
| 22 | return substitute(l:user_name, "\n", "", "") | ||
| 23 | endfun | ||
| 24 | |||
| 25 | fun! <SID>GetUserEmail() | ||
| 26 | let l:user_email = system("git config --get user.email") | ||
| 27 | if v:shell_error | ||
| 28 | return "unknown@user.org" | ||
| 29 | else | ||
| 30 | return substitute(l:user_email, "\n", "", "") | ||
| 31 | endfun | ||
| 32 | |||
| 33 | fun! BBHeader() | ||
| 34 | let l:current_year = strftime("%Y") | ||
| 35 | let l:user_name = <SID>GetUserName() | ||
| 36 | let l:user_email = <SID>GetUserEmail() | ||
| 37 | 0 put ='# Copyright (C) ' . l:current_year . | ||
| 38 | \ ' ' . l:user_name . ' <' . l:user_email . '>' | ||
| 39 | put ='# Released under the MIT license (see COPYING.MIT for the terms)' | ||
| 40 | $ | ||
| 41 | endfun | ||
| 42 | |||
| 43 | fun! NewBBTemplate() | ||
| 44 | if line2byte(line('$') + 1) != -1 | ||
| 45 | return | ||
| 46 | endif | ||
| 47 | |||
| 48 | let l:paste = &paste | ||
| 49 | set nopaste | ||
| 50 | |||
| 51 | " Get the header | ||
| 52 | call BBHeader() | ||
| 53 | |||
| 54 | " New the bb template | ||
| 55 | put ='SUMMARY = \"\"' | ||
| 56 | put ='HOMEPAGE = \"\"' | ||
| 57 | put ='LICENSE = \"\"' | ||
| 58 | put ='SECTION = \"\"' | ||
| 59 | put ='DEPENDS = \"\"' | ||
| 60 | put ='' | ||
| 61 | put ='SRC_URI = \"\"' | ||
| 62 | |||
| 63 | " Go to the first place to edit | ||
| 64 | 0 | ||
| 65 | /^SUMMARY =/ | ||
| 66 | exec "normal 2f\"" | ||
| 67 | |||
| 68 | if paste == 1 | ||
| 69 | set paste | ||
| 70 | endif | ||
| 71 | endfun | ||
| 72 | |||
| 73 | if !exists("g:bb_create_on_empty") | ||
| 74 | let g:bb_create_on_empty = 1 | ||
| 75 | endif | ||
| 76 | |||
| 77 | " disable in case of vimdiff | ||
| 78 | if v:progname =~ "vimdiff" | ||
| 79 | let g:bb_create_on_empty = 0 | ||
| 80 | endif | ||
| 81 | |||
| 82 | augroup NewBB | ||
| 83 | au BufNewFile,BufReadPost *.bb | ||
| 84 | \ if g:bb_create_on_empty | | ||
| 85 | \ call NewBBTemplate() | | ||
| 86 | \ endif | ||
| 87 | augroup END | ||
| 88 | |||
diff --git a/bitbake/contrib/vim/plugin/newbbappend.vim b/bitbake/contrib/vim/plugin/newbbappend.vim deleted file mode 100644 index 3f65f79cdc..0000000000 --- a/bitbake/contrib/vim/plugin/newbbappend.vim +++ /dev/null | |||
| @@ -1,46 +0,0 @@ | |||
| 1 | " Vim plugin file | ||
| 2 | " Purpose: Create a template for new bbappend file | ||
| 3 | " Author: Joshua Watt <JPEWhacker@gmail.com> | ||
| 4 | " Copyright: Copyright (C) 2017 Joshua Watt <JPEWhacker@gmail.com> | ||
| 5 | " | ||
| 6 | " This file is licensed under the MIT license, see COPYING.MIT in | ||
| 7 | " this source distribution for the terms. | ||
| 8 | " | ||
| 9 | |||
| 10 | if &compatible || v:version < 600 || exists("b:loaded_bitbake_plugin") | ||
| 11 | finish | ||
| 12 | endif | ||
| 13 | |||
| 14 | fun! NewBBAppendTemplate() | ||
| 15 | if line2byte(line('$') + 1) != -1 | ||
| 16 | return | ||
| 17 | endif | ||
| 18 | |||
| 19 | let l:paste = &paste | ||
| 20 | set nopaste | ||
| 21 | |||
| 22 | " New bbappend template | ||
| 23 | 0 put ='FILESEXTRAPATHS:prepend := \"${THISDIR}/${PN}:\"' | ||
| 24 | 2 | ||
| 25 | |||
| 26 | if paste == 1 | ||
| 27 | set paste | ||
| 28 | endif | ||
| 29 | endfun | ||
| 30 | |||
| 31 | if !exists("g:bb_create_on_empty") | ||
| 32 | let g:bb_create_on_empty = 1 | ||
| 33 | endif | ||
| 34 | |||
| 35 | " disable in case of vimdiff | ||
| 36 | if v:progname =~ "vimdiff" | ||
| 37 | let g:bb_create_on_empty = 0 | ||
| 38 | endif | ||
| 39 | |||
| 40 | augroup NewBBAppend | ||
| 41 | au BufNewFile,BufReadPost *.bbappend | ||
| 42 | \ if g:bb_create_on_empty | | ||
| 43 | \ call NewBBAppendTemplate() | | ||
| 44 | \ endif | ||
| 45 | augroup END | ||
| 46 | |||
