From b3ac4d86b63cc21ee7a872ca099f06188e6e54a0 Mon Sep 17 00:00:00 2001 From: Francesco Magliocca Date: Sat, 2 Sep 2017 12:14:19 +0200 Subject: [PATCH] Add current history id to env variables --- src/main.cc | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/main.cc b/src/main.cc index 81ad37bc..79a55965 100644 --- a/src/main.cc +++ b/src/main.cc @@ -93,6 +93,10 @@ void register_env_vars() "timestamp", false, [](StringView name, const Context& context) -> String { return to_string(context.buffer().timestamp()); } + }, { + "curr_history_id", false, + [](StringView name, const Context& context) -> String + { return to_string(context.buffer().current_history_id()); } }, { "selection", false, [](StringView name, const Context& context)