Tim's Tips and Tricks

From eLinux.org
Revision as of 08:52, 23 October 2012 by Tim Bird (Talk | contribs) (personal productivity)

Jump to: navigation, search


Ideas for individual tips

Git tips

  • git describe <commit>
  • git describe --contains <commit>
  • git log <file> # narrow scope of log
    • git log <dir>
    • git lg [<dir_or_file>] # nice summary
      • alias.lg=log --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr %an)%Creset' --abbrev-commit --date=relative
  • git annotate <file> | grep <regex of interest> = who did this?
    • git show <commit_of_interest> = why is it here?
  • git bisect
  • how to do a git alias
  • git proxy (finally!!)

patch management

  • quilt - patches as first class objects
    • git for development work, then convert to quilt patches
    • git rebase --interactive
  • precommit - quilt pop -a, basediff, quilt push -a, scripts/fix-filemodes.sh
  • diffinfo - my own tool for managing patches
    • splitting a patch: splitpatch - tool to break patches apart

board handling

  • consistent board setup (including remote access)
    • connections: serial, network, power (web-based control) [images]
      • power port controller [image]
    • Usually use tftp boot kernel, with NFS rootfs
      • but can do other setups: feed kernel through serial line, put kernel on SD card using known-good kernel, etc.

  • ttc - command line tool for board control
    • abstracts differences between boards
    • allows for board sharing (ttc reserve)
    • everything is scritable, and remotable
    • object-oriented: inheritance to quickly modify attributes of a board "class"
    • items abstracted:
      • kernel source, toolchain, architecture, defconfig, kernel image name, tool paths
      • kernel build, install
      • board console access, reboot, run arbitrary commands, reset
      • filesystem access (copy from/to)

personal productivity

  • my workflow:
    • different day for each topic area
    • today script
  • multiple todo's, NOTES all over the place (several in each work directory)
    • must do a context save in each directory, before moving on
    • git branch is essential - commit changes (even if flaky) before moving on
  • my favoriate mailing lists:
    • sorry, but linux-embedded seems to be dead
    • lkml, linux-arm, yocto-devel
    • celinux-dev
  • attend conferences, talk to smart people
  • conferences I attend:
    • ELC, ELCE, linuxcon US, Linuxcon Japan, Linuxcon Europe (by serendipity)
    • what about plumbers?? other regional events??