#include <bits/stdc++.h>
const int N = 1 << 20;
int t[2 * N + 1], n, m, lo, mid, p[N], R[N];
void upd(int i, int val) {
  for (; i <= 2 * N; i += i & -i) t[i] += val;
}
int read(int i) {
  int s = 0;
  for (; i; i -= i & -i) s += t[i];
  return s;
}
int kth(int k) {
  int ans = 0, s = 0;
  for (int i = 21; i >= 0; --i)
    if (s + t[ans + (1 << i)] < k) {
      ans += 1 << i;
      s += t[ans];
    }
  return ans + 1;
}
int main() {
  scanf("%d%d", &n, &m);
  lo = mid = m + 99;
  for (int i = (mid + 1); i <= (mid + n); ++i) upd(i, +1);
  for (int i = (1); i <= (m); ++i) {
    int x, y;
    scanf("%d%d", &x, &y);
    if (!p[x]) {
      p[x] = kth(y);
      if (p[x] <= mid) {
        puts("-1");
        return 0;
      }
      R[p[x] - mid] = x;
    }
    if (read(p[x]) != y) {
      puts("-1");
      return 0;
    }
    upd(p[x], -1);
    upd(p[x] = lo--, 1);
  }
  int r = 1;
  for (int i = (1); i <= (n); ++i)
    if (!p[i]) {
      while (R[r]) ++r;
      R[r] = i;
    }
  for (int i = (1); i <= (n); ++i) printf("%d ", R[i]);
  puts("");
}
